SDL_Android/SmartDeviceLinkAndroidProxy - added the correct version of the proxy
authorJustin Dickow <jjdickow@gmail.com>
Thu, 20 Mar 2014 17:25:10 +0000 (13:25 -0400)
committerJustin Dickow <jjdickow@gmail.com>
Thu, 20 Mar 2014 17:25:10 +0000 (13:25 -0400)
Signed-off-by: Justin Dickow <jjdickow@gmail.com>
294 files changed:
SDL_Android/LivioSdlUtilities/.classpath
SDL_Android/LivioSdlUtilities/bin/AndroidManifest.xml
SDL_Android/LivioSdlUtilities/bin/R.txt
SDL_Android/LivioSdlUtilities/bin/res/crunch/drawable/arrow_left.png [new file with mode: 0644]
SDL_Android/LivioSdlUtilities/bin/res/crunch/drawable/arrow_right.png [new file with mode: 0644]
SDL_Android/LivioSdlUtilities/gen/com/livio/sdl/R.java
SDL_Android/LivioSdlUtilities/project.properties
SDL_Android/LivioTesterApp/bin/AndroidManifest.xml
SDL_Android/LivioTesterApp/bin/LivioSdlTester.apk [deleted file]
SDL_Android/LivioTesterApp/bin/R.txt
SDL_Android/LivioTesterApp/bin/classes.dex [deleted file]
SDL_Android/LivioTesterApp/bin/res/crunch/drawable-hdpi/ic_launcher.png [deleted file]
SDL_Android/LivioTesterApp/bin/res/crunch/drawable-ldpi/ic_launcher.png [deleted file]
SDL_Android/LivioTesterApp/bin/res/crunch/drawable-mdpi/ic_launcher.png [deleted file]
SDL_Android/LivioTesterApp/bin/res/crunch/drawable-xhdpi/ic_launcher.png [deleted file]
SDL_Android/LivioTesterApp/bin/res/crunch/drawable/add.png [deleted file]
SDL_Android/LivioTesterApp/bin/res/crunch/drawable/add_to_favorites.png [deleted file]
SDL_Android/LivioTesterApp/bin/res/crunch/drawable/anchor.png [deleted file]
SDL_Android/LivioTesterApp/bin/res/crunch/drawable/game_pad.png [deleted file]
SDL_Android/LivioTesterApp/bin/res/crunch/drawable/ic_close.png [deleted file]
SDL_Android/LivioTesterApp/bin/res/crunch/drawable/ic_launcher.png [deleted file]
SDL_Android/LivioTesterApp/bin/res/crunch/drawable/remove.png [deleted file]
SDL_Android/LivioTesterApp/bin/res/crunch/drawable/remove_from_favorites.png [deleted file]
SDL_Android/LivioTesterApp/bin/res/crunch/drawable/rocket.png [deleted file]
SDL_Android/LivioTesterApp/bin/res/crunch/drawable/select_an_image.png [deleted file]
SDL_Android/LivioTesterApp/bin/res/crunch/drawable/undo.png [deleted file]
SDL_Android/LivioTesterApp/bin/res/crunch/drawable/zoom_in.png [deleted file]
SDL_Android/LivioTesterApp/bin/res/crunch/drawable/zoom_out.png [deleted file]
SDL_Android/LivioTesterApp/bin/resources.ap_ [deleted file]
SDL_Android/LivioTesterApp/gen/com/livio/sdl/R.java
SDL_Android/LivioTesterApp/gen/com/livio/sdltester/R.java
SDL_Android/LivioTesterApp/project.properties
SDL_Android/SmartDeviceLinkProxyAndroid/.classpath [changed mode: 0644->0755]
SDL_Android/SmartDeviceLinkProxyAndroid/.project [changed mode: 0644->0755]
SDL_Android/SmartDeviceLinkProxyAndroid/.settings/org.eclipse.jdt.core.prefs [changed mode: 0644->0755]
SDL_Android/SmartDeviceLinkProxyAndroid/AndroidManifest.xml
SDL_Android/SmartDeviceLinkProxyAndroid/bin/AndroidManifest.xml [new file with mode: 0644]
SDL_Android/SmartDeviceLinkProxyAndroid/gen/com/smartdevicelink/BuildConfig.java [new file with mode: 0644]
SDL_Android/SmartDeviceLinkProxyAndroid/project.properties [changed mode: 0644->0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/exception/SmartDeviceLinkException.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/exception/SmartDeviceLinkExceptionCause.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/marshal/JsonRPCMarshaller.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/messageDispatcher/IDispatchingStrategy.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/messageDispatcher/IncomingProtocolMessageComparitor.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/messageDispatcher/InternalProxyMessageComparitor.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/messageDispatcher/OutgoingProtocolMessageComparitor.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/messageDispatcher/ProxyMessageDispatcher.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/protocol/AbstractProtocol.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/protocol/BinaryFrameHeader.java [changed mode: 0644->0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/protocol/IProtocol.java [deleted file]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/protocol/IProtocolListener.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/protocol/ProtocolFrameHeader.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/protocol/ProtocolFrameHeaderFactory.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/protocol/ProtocolMessage.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/protocol/SmartDeviceLinkProtocol.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/protocol/enums/FrameData.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/protocol/enums/FrameDataControlFrameType.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/protocol/enums/FrameType.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/protocol/enums/FunctionID.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/protocol/enums/MessageType.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/protocol/enums/SessionType.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/IProxyListener.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/RPCMessage.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/RPCNotification.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/RPCRequest.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/RPCRequestFactory.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/RPCResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/RPCStruct.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/SmartDeviceLinkProxy.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/SmartDeviceLinkProxyALM.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/SmartDeviceLinkProxyBase.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/SmartDeviceLinkProxyConfigurationResources.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/SmartDeviceLinkProxyFactory.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/TTSChunkFactory.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/Version.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/callbacks/InternalProxyMessage.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/callbacks/OnError.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/callbacks/OnProxyClosed.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/callbacks/OnProxyOpened.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/constants/Jingles.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/constants/Names.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/interfaces/IProxyListenerALM.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/interfaces/IProxyListenerBase.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/AddCommand.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/AddCommandResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/AddSubMenu.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/AddSubMenuResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/Alert.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/AlertManeuver.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/AlertManeuverResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/AlertResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/AudioPassThruCapabilities.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/BeltStatus.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/BodyInformation.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ButtonCapabilities.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ChangeRegistration.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ChangeRegistrationResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/Choice.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/CreateInteractionChoiceSet.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/CreateInteractionChoiceSetResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DIDResult.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DTC.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DeleteCommand.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DeleteCommandResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DeleteFile.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DeleteFileResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DeleteInteractionChoiceSet.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DeleteInteractionChoiceSetResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DeleteSubMenu.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DeleteSubMenuResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DeviceStatus.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DialNumber.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DialNumberResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DisplayCapabilities.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/EVInfo.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/EncodedSyncPData.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/EncodedSyncPDataResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/EndAudioPassThru.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/EndAudioPassThruResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/FuelEconomyInformation.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/GPSData.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/GenericResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/GetDTCs.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/GetDTCsResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/GetVehicleData.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/GetVehicleDataResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/HMIPermissions.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/HeadLampStatus.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/Image.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ListFiles.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ListFilesResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/MenuParams.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnAppInterfaceUnregistered.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnAudioPassThru.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnButtonEvent.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnButtonPress.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnCommand.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnDriverDistraction.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnEncodedSyncPData.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnHMIStatus.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnLanguageChange.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnPermissionsChange.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnSmartDeviceLinkChoiceChosen.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnSyncPData.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnTBTClientState.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnVehicleData.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ParameterPermissions.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PerformAudioPassThru.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PerformAudioPassThruResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PerformInteraction.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PerformInteractionResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PermissionGroupItem.java [deleted file]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PermissionItem.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PresetBankCapabilities.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PutFile.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PutFileResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ReadDID.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ReadDIDResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/RegisterAppInterface.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/RegisterAppInterfaceResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ResetGlobalProperties.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ResetGlobalPropertiesResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ScrollableMessage.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ScrollableMessageResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SetAppIcon.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SetAppIconResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SetDisplayLayout.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SetDisplayLayoutResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SetGlobalProperties.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SetGlobalPropertiesResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SetMediaClockTimer.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SetMediaClockTimerResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/Show.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ShowConstantTBT.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ShowConstantTBTResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ShowResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SingleTireStatus.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/Slider.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SliderResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SoftButton.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SoftButtonCapabilities.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/Speak.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SpeakResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/StartTime.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SubscribeButton.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SubscribeButtonResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SubscribeVehicleData.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SubscribeVehicleDataResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SyncMsgVersion.java [deleted file]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SyncPData.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SyncPDataResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/TTSChunk.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/TextField.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/TireStatus.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/Turn.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/UnregisterAppInterface.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/UnregisterAppInterfaceResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/UnsubscribeButton.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/UnsubscribeButtonResponse.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/UnsubscribeVehicleData.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/UnsubscribeVehicleDataResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/UpdateTurnList.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/UpdateTurnListResponse.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/VehicleDataResult.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/VehicleType.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/VrHelpItem.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/AmbientLightStatus.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/AppHMIType.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/AppInterfaceUnregisteredReason.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/AudioStreamingState.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/AudioType.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/BitsPerSample.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/ButtonEventMode.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/ButtonName.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/ButtonPressMode.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/CharacterSet.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/CompassDirection.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/ComponentVolumeStatus.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/DeviceLevelStatus.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/Dimension.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/DisplayType.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/DriverDistractionState.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/FileType.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/FunctionID.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/GearShiftAdviceStatus.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/GlobalProperty.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/HMILevel.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/HmiZoneCapabilities.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/IgnitionStableStatus.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/IgnitionStatus.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/ImageType.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/InteractionMode.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/Language.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/LightSwitchStatus.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/MaintenanceModeStatus.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/MediaClockFormat.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/MessageType.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/PRNDL.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/PermissionStatus.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/PrimaryAudioSource.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/Result.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/SamplingRate.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/SmartDeviceLinkConnectionState.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/SmartDeviceLinkDisconnectedReason.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/SmartDeviceLinkInterfaceAvailability.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/SoftButtonType.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/SpeechCapabilities.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/SystemAction.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/SystemContext.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/TBTState.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/TextAlignment.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/TextFieldName.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/TirePressureTellTale.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/TriggerSource.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/UpdateMode.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/VehicleDataActiveStatus.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/VehicleDataEventStatus.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/VehicleDataNotificationStatus.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/VehicleDataResultCode.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/VehicleDataStatus.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/VehicleDataType.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/VrCapabilities.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/WarningLightStatus.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/WiperStatus.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/smartdevicelinkMsgVersion.java [new file with mode: 0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/smartDeviceLinkConnection/IsmartDeviceLinkConnectionListener.java [moved from SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/syncConnection/ISmartDeviceLinkConnectionListener.java with 79% similarity]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/smartDeviceLinkConnection/smartDeviceLinkConnection.java [moved from SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/syncConnection/SmartDeviceLinkConnection.java with 81% similarity]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/trace/DiagLevel.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/trace/ISTListener.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/trace/Mime.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/trace/OpenRPCMessage.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/trace/SmartDeviceLinkTrace.java [moved from SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/trace/SyncTrace.java with 79% similarity]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/trace/TraceDeviceInfo.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/trace/enums/DetailLevel.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/trace/enums/InterfaceActivityDirection.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/trace/enums/Mod.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/transport/BTTransport.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/transport/BTTransportConfig.java [changed mode: 0644->0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/transport/BaseTransportConfig.java [changed mode: 0644->0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/transport/ISmartDeviceLinkTransport.java [deleted file]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/transport/ITransportListener.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/transport/SiphonServer.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/transport/SmartDeviceLinkTransport.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/transport/TCPTransport.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/transport/TCPTransportConfig.java [changed mode: 0644->0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/transport/TransportType.java [changed mode: 0644->0755]
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/util/Base64.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/util/BitConverter.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/util/ByteEnumer.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/util/DebugTool.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/util/IConsole.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/util/Mime.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/util/NativeLogTool.java
SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/util/StringEnumer.java

index 5176974..0461652 100644 (file)
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <classpath>
-       <classpathentry kind="con" path="com.android.ide.eclipse.adt.ANDROID_FRAMEWORK"/>
+       <classpathentry exported="true" kind="con" path="com.android.ide.eclipse.adt.ANDROID_FRAMEWORK"/>
        <classpathentry exported="true" kind="con" path="com.android.ide.eclipse.adt.LIBRARIES"/>
        <classpathentry exported="true" kind="con" path="com.android.ide.eclipse.adt.DEPENDENCIES"/>
        <classpathentry kind="src" path="src"/>
index 4668241..cc4968f 100644 (file)
@@ -2,7 +2,7 @@
     package="com.livio.sdl"
     android:versionCode="1"
     android:versionName="1.0" >
-
+    
     <uses-sdk
         android:minSdkVersion="9"
         android:targetSdkVersion="18" />
index 269cbdb..959f22c 100644 (file)
@@ -1,15 +1,20 @@
-int drawable ic_launcher 0x7f020000
-int id iv_rowImage 0x7f060004
-int id listView 0x7f060000
-int id textview 0x7f060006
-int id tv_messageDetail 0x7f060003
-int id tv_messageName 0x7f060001
-int id tv_rowText 0x7f060005
-int id tv_timestamp 0x7f060002
-int layout listview 0x7f030000
-int layout sdl_message_listview_row 0x7f030001
-int layout simple_listview_with_image 0x7f030002
-int layout textview 0x7f030003
+int drawable arrow_left 0x7f020000
+int drawable arrow_right 0x7f020001
+int drawable ic_launcher 0x7f020002
+int id ib_moveLeft 0x7f060001
+int id ib_moveRight 0x7f060002
+int id iv_rowImage 0x7f060007
+int id listView 0x7f060003
+int id textview 0x7f060000
+int id tv_messageDetail 0x7f060006
+int id tv_messageName 0x7f060004
+int id tv_rowText 0x7f060008
+int id tv_timestamp 0x7f060005
+int layout json_flipper_dialog 0x7f030000
+int layout listview 0x7f030001
+int layout sdl_message_listview_row 0x7f030002
+int layout simple_listview_with_image 0x7f030003
+int layout textview 0x7f030004
 int string add_command_command_name 0x7f040004
 int string add_command_image_type 0x7f040007
 int string add_command_parent_menu 0x7f040006
diff --git a/SDL_Android/LivioSdlUtilities/bin/res/crunch/drawable/arrow_left.png b/SDL_Android/LivioSdlUtilities/bin/res/crunch/drawable/arrow_left.png
new file mode 100644 (file)
index 0000000..b7d5b59
Binary files /dev/null and b/SDL_Android/LivioSdlUtilities/bin/res/crunch/drawable/arrow_left.png differ
diff --git a/SDL_Android/LivioSdlUtilities/bin/res/crunch/drawable/arrow_right.png b/SDL_Android/LivioSdlUtilities/bin/res/crunch/drawable/arrow_right.png
new file mode 100644 (file)
index 0000000..36cf6b8
Binary files /dev/null and b/SDL_Android/LivioSdlUtilities/bin/res/crunch/drawable/arrow_right.png differ
index d0fb61f..c882fa1 100644 (file)
@@ -11,22 +11,27 @@ public final class R {
     public static final class attr {
     }
     public static final class drawable {
-        public static int ic_launcher=0x7f020000;
+        public static int arrow_left=0x7f020000;
+        public static int arrow_right=0x7f020001;
+        public static int ic_launcher=0x7f020002;
     }
     public static final class id {
-        public static int iv_rowImage=0x7f060004;
-        public static int listView=0x7f060000;
-        public static int textview=0x7f060006;
-        public static int tv_messageDetail=0x7f060003;
-        public static int tv_messageName=0x7f060001;
-        public static int tv_rowText=0x7f060005;
-        public static int tv_timestamp=0x7f060002;
+        public static int ib_moveLeft=0x7f060001;
+        public static int ib_moveRight=0x7f060002;
+        public static int iv_rowImage=0x7f060007;
+        public static int listView=0x7f060003;
+        public static int textview=0x7f060000;
+        public static int tv_messageDetail=0x7f060006;
+        public static int tv_messageName=0x7f060004;
+        public static int tv_rowText=0x7f060008;
+        public static int tv_timestamp=0x7f060005;
     }
     public static final class layout {
-        public static int listview=0x7f030000;
-        public static int sdl_message_listview_row=0x7f030001;
-        public static int simple_listview_with_image=0x7f030002;
-        public static int textview=0x7f030003;
+        public static int json_flipper_dialog=0x7f030000;
+        public static int listview=0x7f030001;
+        public static int sdl_message_listview_row=0x7f030002;
+        public static int simple_listview_with_image=0x7f030003;
+        public static int textview=0x7f030004;
     }
     public static final class string {
         /**      Add Command 
index e0da0c8..4ba671a 100644 (file)
@@ -11,6 +11,6 @@
 #proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt
 
 # Project target.
-target=android-19
+target=Google Inc.:Google APIs:19
 android.library=true
-android.library.reference.1=../../../../Projects/git/SDL_Genivi/SDL_Android/SmartDeviceLinkProxyAndroid
+android.library.reference.1=../SmartDeviceLinkProxyAndroid
index 0aae1d7..2fb7ec1 100644 (file)
@@ -13,6 +13,9 @@
     <!-- Required to make the device stay awake while doing XML tests -->
     <uses-permission android:name="android.permission.WAKE_LOCK" />
     <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
+    <!-- Required to determine WiFi state and enable it if necessary -->
+    <uses-permission android:name="android.permission.CHANGE_WIFI_STATE" />
+    <uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
 
     <uses-sdk
         android:minSdkVersion="11"
diff --git a/SDL_Android/LivioTesterApp/bin/LivioSdlTester.apk b/SDL_Android/LivioTesterApp/bin/LivioSdlTester.apk
deleted file mode 100644 (file)
index c4c0472..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/LivioSdlTester.apk and /dev/null differ
index 0b36f95..0ba5640 100644 (file)
@@ -3,31 +3,32 @@ int dimen activity_vertical_margin 0x7f060001
 int drawable add 0x7f020000
 int drawable add_to_favorites 0x7f020001
 int drawable anchor 0x7f020002
-int drawable game_pad 0x7f020003
-int drawable ic_close 0x7f020004
-int drawable ic_launcher 0x7f020005
-int drawable remove 0x7f020006
-int drawable remove_from_favorites 0x7f020007
-int drawable rocket 0x7f020008
-int drawable select_an_image 0x7f020009
-int drawable undo 0x7f02000a
-int drawable zoom_in 0x7f02000b
-int drawable zoom_out 0x7f02000c
-int id btn_main_sendMessage 0x7f080019
+int drawable arrow_left 0x7f020003
+int drawable arrow_right 0x7f020004
+int drawable game_pad 0x7f020005
+int drawable ic_close 0x7f020006
+int drawable ic_launcher 0x7f020007
+int drawable remove 0x7f020008
+int drawable remove_from_favorites 0x7f020009
+int drawable rocket 0x7f02000a
+int drawable select_an_image 0x7f02000b
+int drawable undo 0x7f02000c
+int drawable zoom_in 0x7f02000d
+int drawable zoom_out 0x7f02000e
+int id btn_main_sendMessage 0x7f08001c
 int id but_addItem 0x7f080014
-int id but_performInteraction_selectChoiceSets 0x7f08001d
-int id but_scrollableMessage_clear 0x7f08002b
-int id but_showImage 0x7f080047
-int id cb_putFile_addAll 0x7f080024
-int id cb_putFile_isPersistent 0x7f080027
+int id but_performInteraction_selectChoiceSets 0x7f080020
+int id but_scrollableMessage_clear 0x7f08002e
+int id cb_putFile_addAll 0x7f080027
+int id cb_putFile_isPersistent 0x7f08002a
 int id check_alert_playTone 0x7f08000b
 int id check_enable_image 0x7f080004
-int id check_performInteraction_timeoutEnabled 0x7f080020
-int id check_show1 0x7f08003b
-int id check_show2 0x7f08003d
-int id check_show3 0x7f08003f
-int id check_show4 0x7f080041
-int id check_statusBar 0x7f080045
+int id check_performInteraction_timeoutEnabled 0x7f080023
+int id check_show1 0x7f08003e
+int id check_show2 0x7f080040
+int id check_show3 0x7f080042
+int id check_show4 0x7f080044
+int id check_statusBar 0x7f080048
 int id et_addCommand_commandName 0x7f080001
 int id et_addCommand_voiceRecKeyword 0x7f080002
 int id et_addSubMenu_subMenuName 0x7f080006
@@ -40,68 +41,73 @@ int id et_choice_name 0x7f080011
 int id et_choice_vr_text 0x7f080012
 int id et_getDtcs_ecuName 0x7f080016
 int id et_imageName 0x7f080005
-int id et_ipAddress 0x7f08002e
-int id et_ipPort 0x7f08002f
-int id et_mediaClockHours 0x7f080036
-int id et_mediaClockMins 0x7f080037
-int id et_mediaClockSecs 0x7f080038
-int id et_performInteraction_title 0x7f08001b
-int id et_performInteraction_voicePrompt 0x7f08001c
-int id et_putFile_imageName 0x7f080026
-int id et_readDids_didLocation 0x7f080029
-int id et_readDids_ecuName 0x7f080028
-int id et_scrollableMessage_text 0x7f08002a
-int id et_show1 0x7f08003a
-int id et_show2 0x7f08003c
-int id et_show3 0x7f08003e
-int id et_show4 0x7f080040
-int id et_slider_footer 0x7f08004b
-int id et_slider_title 0x7f08004a
-int id et_statusBar 0x7f080046
-int id et_textToSpeak 0x7f080052
-int id ib_putFile_selectAnImage 0x7f080025
-int id iv_rowImage 0x7f080048
-int id listView 0x7f080017
-int id list_main_commandList 0x7f08001a
-int id ll_clock 0x7f080035
+int id et_ipAddress 0x7f080031
+int id et_ipPort 0x7f080032
+int id et_mediaClockHours 0x7f080039
+int id et_mediaClockMins 0x7f08003a
+int id et_mediaClockSecs 0x7f08003b
+int id et_performInteraction_title 0x7f08001e
+int id et_performInteraction_voicePrompt 0x7f08001f
+int id et_putFile_imageName 0x7f080029
+int id et_readDids_didLocation 0x7f08002c
+int id et_readDids_ecuName 0x7f08002b
+int id et_scrollableMessage_text 0x7f08002d
+int id et_show1 0x7f08003d
+int id et_show2 0x7f08003f
+int id et_show3 0x7f080041
+int id et_show4 0x7f080043
+int id et_show_image 0x7f08004a
+int id et_slider_footer 0x7f08004e
+int id et_slider_title 0x7f08004d
+int id et_statusBar 0x7f080049
+int id et_textToSpeak 0x7f080055
+int id ib_moveLeft 0x7f080018
+int id ib_moveRight 0x7f080019
+int id ib_putFile_selectAnImage 0x7f080028
+int id iv_rowImage 0x7f08004b
+int id listView 0x7f08001a
+int id list_main_commandList 0x7f08001d
+int id ll_clock 0x7f080038
 int id lv_choices 0x7f080015
-int id menu_clear_list 0x7f080058
-int id menu_connect 0x7f080055
-int id menu_disconnect 0x7f080056
-int id menu_help 0x7f080059
-int id menu_reset 0x7f080057
+int id menu_clear_list 0x7f08005c
+int id menu_connect 0x7f080059
+int id menu_disconnect 0x7f08005a
+int id menu_help 0x7f08005d
+int id menu_help_close 0x7f080058
+int id menu_help_home 0x7f080057
+int id menu_reset 0x7f08005b
 int id seek_alert_toneDuration 0x7f08000e
-int id seek_performInteraction_timeoutDuration 0x7f080023
-int id seek_scrollableMessage_timeout 0x7f08002d
-int id seek_slider_numOfTicks 0x7f08004d
-int id seek_slider_startPosition 0x7f08004f
-int id seek_slider_timeout 0x7f080051
+int id seek_performInteraction_timeoutDuration 0x7f080026
+int id seek_scrollableMessage_timeout 0x7f080030
+int id seek_slider_numOfTicks 0x7f080050
+int id seek_slider_startPosition 0x7f080052
+int id seek_slider_timeout 0x7f080054
 int id spin_addCommand_submenus 0x7f080003
 int id spin_changeRegistration_hmiLanguage 0x7f080010
 int id spin_changeRegistration_language 0x7f08000f
-int id spin_mediaClock_updateMode 0x7f080033
-int id spin_performInteraction_interactionMode 0x7f08001f
-int id spin_speechCapabilities 0x7f080053
-int id spin_textAlignment 0x7f080043
-int id textview 0x7f080054
+int id spin_mediaClock_updateMode 0x7f080036
+int id spin_performInteraction_interactionMode 0x7f080022
+int id spin_speechCapabilities 0x7f080056
+int id spin_textAlignment 0x7f080046
+int id textview 0x7f080017
 int id tv_alert_toneDuration 0x7f08000d
 int id tv_alert_toneDurationHeader 0x7f08000c
-int id tv_connectionStatus 0x7f080018
-int id tv_mediaClock_clock 0x7f080034
-int id tv_messageDetail 0x7f080032
-int id tv_messageName 0x7f080030
-int id tv_metadataLines 0x7f080039
-int id tv_performInteraction_interactionMode 0x7f08001e
-int id tv_performInteraction_timeoutDuration 0x7f080022
-int id tv_performInteraction_timeoutTitle 0x7f080021
-int id tv_rowText 0x7f080049
-int id tv_scrollableMessage_timeout 0x7f08002c
-int id tv_slider_numOfTicks 0x7f08004c
-int id tv_slider_startPosition 0x7f08004e
-int id tv_slider_timeout 0x7f080050
-int id tv_statusBar 0x7f080044
-int id tv_textAlignment 0x7f080042
-int id tv_timestamp 0x7f080031
+int id tv_connectionStatus 0x7f08001b
+int id tv_mediaClock_clock 0x7f080037
+int id tv_messageDetail 0x7f080035
+int id tv_messageName 0x7f080033
+int id tv_metadataLines 0x7f08003c
+int id tv_performInteraction_interactionMode 0x7f080021
+int id tv_performInteraction_timeoutDuration 0x7f080025
+int id tv_performInteraction_timeoutTitle 0x7f080024
+int id tv_rowText 0x7f08004c
+int id tv_scrollableMessage_timeout 0x7f08002f
+int id tv_slider_numOfTicks 0x7f08004f
+int id tv_slider_startPosition 0x7f080051
+int id tv_slider_timeout 0x7f080053
+int id tv_statusBar 0x7f080047
+int id tv_textAlignment 0x7f080045
+int id tv_timestamp 0x7f080034
 int id wv_help 0x7f080000
 int layout activity_help 0x7f030000
 int layout add_command 0x7f030001
@@ -111,28 +117,30 @@ int layout change_registration 0x7f030004
 int layout choice_set_item 0x7f030005
 int layout create_choice_interaction_set 0x7f030006
 int layout get_dtcs 0x7f030007
-int layout listview 0x7f030008
-int layout main 0x7f030009
-int layout offline_mode 0x7f03000a
-int layout perform_interaction 0x7f03000b
-int layout put_file 0x7f03000c
-int layout read_dids 0x7f03000d
-int layout scrollable_message 0x7f03000e
-int layout sdl_connection 0x7f03000f
-int layout sdl_message_listview_row 0x7f030010
-int layout set_media_clock_timer 0x7f030011
-int layout show 0x7f030012
-int layout simple_listview_with_image 0x7f030013
-int layout slider 0x7f030014
-int layout speak 0x7f030015
-int layout textview 0x7f030016
-int menu menu_main 0x7f070000
-int string action_settings 0x7f040050
+int layout json_flipper_dialog 0x7f030008
+int layout listview 0x7f030009
+int layout main 0x7f03000a
+int layout offline_mode 0x7f03000b
+int layout perform_interaction 0x7f03000c
+int layout put_file 0x7f03000d
+int layout read_dids 0x7f03000e
+int layout scrollable_message 0x7f03000f
+int layout sdl_connection 0x7f030010
+int layout sdl_message_listview_row 0x7f030011
+int layout set_media_clock_timer 0x7f030012
+int layout show 0x7f030013
+int layout simple_listview_with_image 0x7f030014
+int layout slider 0x7f030015
+int layout speak 0x7f030016
+int layout textview 0x7f030017
+int menu menu_help 0x7f070000
+int menu menu_main 0x7f070001
+int string action_settings 0x7f040052
 int string add_command_command_name 0x7f040004
 int string add_command_image_type 0x7f040007
 int string add_command_parent_menu 0x7f040006
 int string add_command_vr_keyword 0x7f040005
-int string add_image 0x7f04004e
+int string add_image 0x7f040050
 int string alert_duration_ms 0x7f040023
 int string alert_duration_s 0x7f040022
 int string alert_line1 0x7f04001e
@@ -140,23 +148,23 @@ int string alert_line2 0x7f04001f
 int string alert_line3 0x7f040020
 int string alert_sound_enabled 0x7f040021
 int string app_name 0x7f040000
-int string button_subscriptions_already_subscribed 0x7f040043
-int string button_subscriptions_none_subscribed 0x7f040044
+int string button_subscriptions_already_subscribed 0x7f040045
+int string button_subscriptions_none_subscribed 0x7f040046
 int string choice_name 0x7f040018
 int string clock 0x7f04002d
 int string clock_hrs 0x7f04002e
 int string clock_mins 0x7f04002f
 int string clock_secs 0x7f040030
 int string colon 0x7f040031
-int string connection_status_format 0x7f04003e
+int string connection_status_format 0x7f040040
 int string did_location 0x7f04000c
 int string ecu_name 0x7f04000b
-int string function_bank_root_name 0x7f040042
-int string hello_world 0x7f040051
+int string function_bank_root_name 0x7f040044
+int string hello_world 0x7f040053
 int string hmi_language 0x7f04001c
-int string interaction_list_none_added 0x7f04004b
-int string ip_address 0x7f04003f
-int string ip_port 0x7f040040
+int string interaction_list_none_added 0x7f04004d
+int string ip_address 0x7f040041
+int string ip_port 0x7f040042
 int string item_number 0x7f040016
 int string item_number1 0x7f040017
 int string language 0x7f04001b
@@ -168,6 +176,8 @@ int string menu_clear_list 0x7f04003b
 int string menu_connect 0x7f040038
 int string menu_disconnect 0x7f040039
 int string menu_help 0x7f04003c
+int string menu_help_close 0x7f04003e
+int string menu_help_home 0x7f04003d
 int string menu_reset 0x7f04003a
 int string metadata_line1 0x7f040025
 int string metadata_line2 0x7f040026
@@ -180,21 +190,21 @@ int string no_selection 0x7f040035
 int string no_submenus_to_delete 0x7f040009
 int string not_an_sdl_command 0x7f040037
 int string not_implemented 0x7f040036
-int string offline_mode_text 0x7f040041
-int string perform_interaction_mode 0x7f040048
-int string perform_interaction_select_choice_set 0x7f040047
-int string perform_interaction_timeout 0x7f040049
-int string perform_interaction_timeout_enabled 0x7f04004a
-int string perform_interaction_title 0x7f040045
-int string perform_interaction_voice_prompt 0x7f040046
+int string offline_mode_text 0x7f040043
+int string perform_interaction_mode 0x7f04004a
+int string perform_interaction_select_choice_set 0x7f040049
+int string perform_interaction_timeout 0x7f04004b
+int string perform_interaction_timeout_enabled 0x7f04004c
+int string perform_interaction_title 0x7f040047
+int string perform_interaction_voice_prompt 0x7f040048
 int string positive_button 0x7f040002
-int string put_file_persistent_file 0x7f04004c
+int string put_file_persistent_file 0x7f04004e
 int string scrollable_message_clear 0x7f040014
 int string scrollable_message_hint 0x7f040013
 int string scrollable_message_text 0x7f040012
-int string sdl_command_dialog_title 0x7f04003d
+int string sdl_command_dialog_title 0x7f04003f
 int string sdl_disconnected 0x7f040001
-int string sdl_image_name 0x7f04004d
+int string sdl_image_name 0x7f04004f
 int string slider_footer 0x7f04000e
 int string slider_start_position 0x7f040010
 int string slider_ticks 0x7f04000f
@@ -204,7 +214,7 @@ int string submenu_name 0x7f04000a
 int string text_alignment 0x7f040029
 int string text_to_speak 0x7f04001d
 int string timeout 0x7f040011
-int string title_activity_help 0x7f04004f
+int string title_activity_help 0x7f040051
 int string units_milliseconds 0x7f040034
 int string units_seconds 0x7f040033
 int string use_artwork 0x7f04001a
diff --git a/SDL_Android/LivioTesterApp/bin/classes.dex b/SDL_Android/LivioTesterApp/bin/classes.dex
deleted file mode 100644 (file)
index 72f31bc..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/classes.dex and /dev/null differ
diff --git a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable-hdpi/ic_launcher.png b/SDL_Android/LivioTesterApp/bin/res/crunch/drawable-hdpi/ic_launcher.png
deleted file mode 100644 (file)
index a2cc99c..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable-hdpi/ic_launcher.png and /dev/null differ
diff --git a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable-ldpi/ic_launcher.png b/SDL_Android/LivioTesterApp/bin/res/crunch/drawable-ldpi/ic_launcher.png
deleted file mode 100644 (file)
index 26f1f76..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable-ldpi/ic_launcher.png and /dev/null differ
diff --git a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable-mdpi/ic_launcher.png b/SDL_Android/LivioTesterApp/bin/res/crunch/drawable-mdpi/ic_launcher.png
deleted file mode 100644 (file)
index 287daac..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable-mdpi/ic_launcher.png and /dev/null differ
diff --git a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable-xhdpi/ic_launcher.png b/SDL_Android/LivioTesterApp/bin/res/crunch/drawable-xhdpi/ic_launcher.png
deleted file mode 100644 (file)
index f5af7b0..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable-xhdpi/ic_launcher.png and /dev/null differ
diff --git a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/add.png b/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/add.png
deleted file mode 100644 (file)
index 5e5c401..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/add.png and /dev/null differ
diff --git a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/add_to_favorites.png b/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/add_to_favorites.png
deleted file mode 100644 (file)
index 512e63c..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/add_to_favorites.png and /dev/null differ
diff --git a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/anchor.png b/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/anchor.png
deleted file mode 100644 (file)
index 242e120..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/anchor.png and /dev/null differ
diff --git a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/game_pad.png b/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/game_pad.png
deleted file mode 100644 (file)
index 36430d2..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/game_pad.png and /dev/null differ
diff --git a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/ic_close.png b/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/ic_close.png
deleted file mode 100644 (file)
index f19eba6..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/ic_close.png and /dev/null differ
diff --git a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/ic_launcher.png b/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/ic_launcher.png
deleted file mode 100644 (file)
index 26f1f76..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/ic_launcher.png and /dev/null differ
diff --git a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/remove.png b/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/remove.png
deleted file mode 100644 (file)
index 0798027..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/remove.png and /dev/null differ
diff --git a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/remove_from_favorites.png b/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/remove_from_favorites.png
deleted file mode 100644 (file)
index 9f9afdd..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/remove_from_favorites.png and /dev/null differ
diff --git a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/rocket.png b/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/rocket.png
deleted file mode 100644 (file)
index 4cfb090..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/rocket.png and /dev/null differ
diff --git a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/select_an_image.png b/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/select_an_image.png
deleted file mode 100644 (file)
index 918b433..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/select_an_image.png and /dev/null differ
diff --git a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/undo.png b/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/undo.png
deleted file mode 100644 (file)
index c8b4cc0..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/undo.png and /dev/null differ
diff --git a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/zoom_in.png b/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/zoom_in.png
deleted file mode 100644 (file)
index fab7aa3..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/zoom_in.png and /dev/null differ
diff --git a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/zoom_out.png b/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/zoom_out.png
deleted file mode 100644 (file)
index a777d81..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/res/crunch/drawable/zoom_out.png and /dev/null differ
diff --git a/SDL_Android/LivioTesterApp/bin/resources.ap_ b/SDL_Android/LivioTesterApp/bin/resources.ap_
deleted file mode 100644 (file)
index 0d7de4e..0000000
Binary files a/SDL_Android/LivioTesterApp/bin/resources.ap_ and /dev/null differ
index 81d9019..8c96d73 100644 (file)
@@ -8,22 +8,27 @@ package com.livio.sdl;
 
 public final class R {
        public static final class drawable {
-               public static final int ic_launcher = 0x7f020005;
+               public static final int arrow_left = 0x7f020003;
+               public static final int arrow_right = 0x7f020004;
+               public static final int ic_launcher = 0x7f020007;
        }
        public static final class id {
-               public static final int iv_rowImage = 0x7f080048;
-               public static final int listView = 0x7f080017;
-               public static final int textview = 0x7f080054;
-               public static final int tv_messageDetail = 0x7f080032;
-               public static final int tv_messageName = 0x7f080030;
-               public static final int tv_rowText = 0x7f080049;
-               public static final int tv_timestamp = 0x7f080031;
+               public static final int ib_moveLeft = 0x7f080018;
+               public static final int ib_moveRight = 0x7f080019;
+               public static final int iv_rowImage = 0x7f08004b;
+               public static final int listView = 0x7f08001a;
+               public static final int textview = 0x7f080017;
+               public static final int tv_messageDetail = 0x7f080035;
+               public static final int tv_messageName = 0x7f080033;
+               public static final int tv_rowText = 0x7f08004c;
+               public static final int tv_timestamp = 0x7f080034;
        }
        public static final class layout {
-               public static final int listview = 0x7f030008;
-               public static final int sdl_message_listview_row = 0x7f030010;
-               public static final int simple_listview_with_image = 0x7f030013;
-               public static final int textview = 0x7f030016;
+               public static final int json_flipper_dialog = 0x7f030008;
+               public static final int listview = 0x7f030009;
+               public static final int sdl_message_listview_row = 0x7f030011;
+               public static final int simple_listview_with_image = 0x7f030014;
+               public static final int textview = 0x7f030017;
        }
        public static final class string {
                public static final int add_command_command_name = 0x7f040004;
index 3d24a11..005fb8c 100644 (file)
@@ -24,33 +24,34 @@ public final class R {
         public static final int add=0x7f020000;
         public static final int add_to_favorites=0x7f020001;
         public static final int anchor=0x7f020002;
-        public static final int game_pad=0x7f020003;
-        public static final int ic_close=0x7f020004;
-        public static final int ic_launcher=0x7f020005;
-        public static final int remove=0x7f020006;
-        public static final int remove_from_favorites=0x7f020007;
-        public static final int rocket=0x7f020008;
-        public static final int select_an_image=0x7f020009;
-        public static final int undo=0x7f02000a;
-        public static final int zoom_in=0x7f02000b;
-        public static final int zoom_out=0x7f02000c;
+        public static final int arrow_left=0x7f020003;
+        public static final int arrow_right=0x7f020004;
+        public static final int game_pad=0x7f020005;
+        public static final int ic_close=0x7f020006;
+        public static final int ic_launcher=0x7f020007;
+        public static final int remove=0x7f020008;
+        public static final int remove_from_favorites=0x7f020009;
+        public static final int rocket=0x7f02000a;
+        public static final int select_an_image=0x7f02000b;
+        public static final int undo=0x7f02000c;
+        public static final int zoom_in=0x7f02000d;
+        public static final int zoom_out=0x7f02000e;
     }
     public static final class id {
-        public static final int btn_main_sendMessage=0x7f080019;
+        public static final int btn_main_sendMessage=0x7f08001c;
         public static final int but_addItem=0x7f080014;
-        public static final int but_performInteraction_selectChoiceSets=0x7f08001d;
-        public static final int but_scrollableMessage_clear=0x7f08002b;
-        public static final int but_showImage=0x7f080047;
-        public static final int cb_putFile_addAll=0x7f080024;
-        public static final int cb_putFile_isPersistent=0x7f080027;
+        public static final int but_performInteraction_selectChoiceSets=0x7f080020;
+        public static final int but_scrollableMessage_clear=0x7f08002e;
+        public static final int cb_putFile_addAll=0x7f080027;
+        public static final int cb_putFile_isPersistent=0x7f08002a;
         public static final int check_alert_playTone=0x7f08000b;
         public static final int check_enable_image=0x7f080004;
-        public static final int check_performInteraction_timeoutEnabled=0x7f080020;
-        public static final int check_show1=0x7f08003b;
-        public static final int check_show2=0x7f08003d;
-        public static final int check_show3=0x7f08003f;
-        public static final int check_show4=0x7f080041;
-        public static final int check_statusBar=0x7f080045;
+        public static final int check_performInteraction_timeoutEnabled=0x7f080023;
+        public static final int check_show1=0x7f08003e;
+        public static final int check_show2=0x7f080040;
+        public static final int check_show3=0x7f080042;
+        public static final int check_show4=0x7f080044;
+        public static final int check_statusBar=0x7f080048;
         public static final int et_addCommand_commandName=0x7f080001;
         public static final int et_addCommand_voiceRecKeyword=0x7f080002;
         public static final int et_addSubMenu_subMenuName=0x7f080006;
@@ -63,68 +64,73 @@ public final class R {
         public static final int et_choice_vr_text=0x7f080012;
         public static final int et_getDtcs_ecuName=0x7f080016;
         public static final int et_imageName=0x7f080005;
-        public static final int et_ipAddress=0x7f08002e;
-        public static final int et_ipPort=0x7f08002f;
-        public static final int et_mediaClockHours=0x7f080036;
-        public static final int et_mediaClockMins=0x7f080037;
-        public static final int et_mediaClockSecs=0x7f080038;
-        public static final int et_performInteraction_title=0x7f08001b;
-        public static final int et_performInteraction_voicePrompt=0x7f08001c;
-        public static final int et_putFile_imageName=0x7f080026;
-        public static final int et_readDids_didLocation=0x7f080029;
-        public static final int et_readDids_ecuName=0x7f080028;
-        public static final int et_scrollableMessage_text=0x7f08002a;
-        public static final int et_show1=0x7f08003a;
-        public static final int et_show2=0x7f08003c;
-        public static final int et_show3=0x7f08003e;
-        public static final int et_show4=0x7f080040;
-        public static final int et_slider_footer=0x7f08004b;
-        public static final int et_slider_title=0x7f08004a;
-        public static final int et_statusBar=0x7f080046;
-        public static final int et_textToSpeak=0x7f080052;
-        public static final int ib_putFile_selectAnImage=0x7f080025;
-        public static final int iv_rowImage=0x7f080048;
-        public static final int listView=0x7f080017;
-        public static final int list_main_commandList=0x7f08001a;
-        public static final int ll_clock=0x7f080035;
+        public static final int et_ipAddress=0x7f080031;
+        public static final int et_ipPort=0x7f080032;
+        public static final int et_mediaClockHours=0x7f080039;
+        public static final int et_mediaClockMins=0x7f08003a;
+        public static final int et_mediaClockSecs=0x7f08003b;
+        public static final int et_performInteraction_title=0x7f08001e;
+        public static final int et_performInteraction_voicePrompt=0x7f08001f;
+        public static final int et_putFile_imageName=0x7f080029;
+        public static final int et_readDids_didLocation=0x7f08002c;
+        public static final int et_readDids_ecuName=0x7f08002b;
+        public static final int et_scrollableMessage_text=0x7f08002d;
+        public static final int et_show1=0x7f08003d;
+        public static final int et_show2=0x7f08003f;
+        public static final int et_show3=0x7f080041;
+        public static final int et_show4=0x7f080043;
+        public static final int et_show_image=0x7f08004a;
+        public static final int et_slider_footer=0x7f08004e;
+        public static final int et_slider_title=0x7f08004d;
+        public static final int et_statusBar=0x7f080049;
+        public static final int et_textToSpeak=0x7f080055;
+        public static final int ib_moveLeft=0x7f080018;
+        public static final int ib_moveRight=0x7f080019;
+        public static final int ib_putFile_selectAnImage=0x7f080028;
+        public static final int iv_rowImage=0x7f08004b;
+        public static final int listView=0x7f08001a;
+        public static final int list_main_commandList=0x7f08001d;
+        public static final int ll_clock=0x7f080038;
         public static final int lv_choices=0x7f080015;
-        public static final int menu_clear_list=0x7f080058;
-        public static final int menu_connect=0x7f080055;
-        public static final int menu_disconnect=0x7f080056;
-        public static final int menu_help=0x7f080059;
-        public static final int menu_reset=0x7f080057;
+        public static final int menu_clear_list=0x7f08005c;
+        public static final int menu_connect=0x7f080059;
+        public static final int menu_disconnect=0x7f08005a;
+        public static final int menu_help=0x7f08005d;
+        public static final int menu_help_close=0x7f080058;
+        public static final int menu_help_home=0x7f080057;
+        public static final int menu_reset=0x7f08005b;
         public static final int seek_alert_toneDuration=0x7f08000e;
-        public static final int seek_performInteraction_timeoutDuration=0x7f080023;
-        public static final int seek_scrollableMessage_timeout=0x7f08002d;
-        public static final int seek_slider_numOfTicks=0x7f08004d;
-        public static final int seek_slider_startPosition=0x7f08004f;
-        public static final int seek_slider_timeout=0x7f080051;
+        public static final int seek_performInteraction_timeoutDuration=0x7f080026;
+        public static final int seek_scrollableMessage_timeout=0x7f080030;
+        public static final int seek_slider_numOfTicks=0x7f080050;
+        public static final int seek_slider_startPosition=0x7f080052;
+        public static final int seek_slider_timeout=0x7f080054;
         public static final int spin_addCommand_submenus=0x7f080003;
         public static final int spin_changeRegistration_hmiLanguage=0x7f080010;
         public static final int spin_changeRegistration_language=0x7f08000f;
-        public static final int spin_mediaClock_updateMode=0x7f080033;
-        public static final int spin_performInteraction_interactionMode=0x7f08001f;
-        public static final int spin_speechCapabilities=0x7f080053;
-        public static final int spin_textAlignment=0x7f080043;
-        public static final int textview=0x7f080054;
+        public static final int spin_mediaClock_updateMode=0x7f080036;
+        public static final int spin_performInteraction_interactionMode=0x7f080022;
+        public static final int spin_speechCapabilities=0x7f080056;
+        public static final int spin_textAlignment=0x7f080046;
+        public static final int textview=0x7f080017;
         public static final int tv_alert_toneDuration=0x7f08000d;
         public static final int tv_alert_toneDurationHeader=0x7f08000c;
-        public static final int tv_connectionStatus=0x7f080018;
-        public static final int tv_mediaClock_clock=0x7f080034;
-        public static final int tv_messageDetail=0x7f080032;
-        public static final int tv_messageName=0x7f080030;
-        public static final int tv_metadataLines=0x7f080039;
-        public static final int tv_performInteraction_interactionMode=0x7f08001e;
-        public static final int tv_performInteraction_timeoutDuration=0x7f080022;
-        public static final int tv_performInteraction_timeoutTitle=0x7f080021;
-        public static final int tv_rowText=0x7f080049;
-        public static final int tv_scrollableMessage_timeout=0x7f08002c;
-        public static final int tv_slider_numOfTicks=0x7f08004c;
-        public static final int tv_slider_startPosition=0x7f08004e;
-        public static final int tv_slider_timeout=0x7f080050;
-        public static final int tv_statusBar=0x7f080044;
-        public static final int tv_textAlignment=0x7f080042;
-        public static final int tv_timestamp=0x7f080031;
+        public static final int tv_connectionStatus=0x7f08001b;
+        public static final int tv_mediaClock_clock=0x7f080037;
+        public static final int tv_messageDetail=0x7f080035;
+        public static final int tv_messageName=0x7f080033;
+        public static final int tv_metadataLines=0x7f08003c;
+        public static final int tv_performInteraction_interactionMode=0x7f080021;
+        public static final int tv_performInteraction_timeoutDuration=0x7f080025;
+        public static final int tv_performInteraction_timeoutTitle=0x7f080024;
+        public static final int tv_rowText=0x7f08004c;
+        public static final int tv_scrollableMessage_timeout=0x7f08002f;
+        public static final int tv_slider_numOfTicks=0x7f08004f;
+        public static final int tv_slider_startPosition=0x7f080051;
+        public static final int tv_slider_timeout=0x7f080053;
+        public static final int tv_statusBar=0x7f080047;
+        public static final int tv_textAlignment=0x7f080045;
+        public static final int tv_timestamp=0x7f080034;
         public static final int wv_help=0x7f080000;
     }
     public static final class layout {
@@ -136,34 +142,36 @@ public final class R {
         public static final int choice_set_item=0x7f030005;
         public static final int create_choice_interaction_set=0x7f030006;
         public static final int get_dtcs=0x7f030007;
-        public static final int listview=0x7f030008;
-        public static final int main=0x7f030009;
-        public static final int offline_mode=0x7f03000a;
-        public static final int perform_interaction=0x7f03000b;
-        public static final int put_file=0x7f03000c;
-        public static final int read_dids=0x7f03000d;
-        public static final int scrollable_message=0x7f03000e;
-        public static final int sdl_connection=0x7f03000f;
-        public static final int sdl_message_listview_row=0x7f030010;
-        public static final int set_media_clock_timer=0x7f030011;
-        public static final int show=0x7f030012;
-        public static final int simple_listview_with_image=0x7f030013;
-        public static final int slider=0x7f030014;
-        public static final int speak=0x7f030015;
-        public static final int textview=0x7f030016;
+        public static final int json_flipper_dialog=0x7f030008;
+        public static final int listview=0x7f030009;
+        public static final int main=0x7f03000a;
+        public static final int offline_mode=0x7f03000b;
+        public static final int perform_interaction=0x7f03000c;
+        public static final int put_file=0x7f03000d;
+        public static final int read_dids=0x7f03000e;
+        public static final int scrollable_message=0x7f03000f;
+        public static final int sdl_connection=0x7f030010;
+        public static final int sdl_message_listview_row=0x7f030011;
+        public static final int set_media_clock_timer=0x7f030012;
+        public static final int show=0x7f030013;
+        public static final int simple_listview_with_image=0x7f030014;
+        public static final int slider=0x7f030015;
+        public static final int speak=0x7f030016;
+        public static final int textview=0x7f030017;
     }
     public static final class menu {
-        public static final int menu_main=0x7f070000;
+        public static final int menu_help=0x7f070000;
+        public static final int menu_main=0x7f070001;
     }
     public static final class string {
-        public static final int action_settings=0x7f040050;
+        public static final int action_settings=0x7f040052;
         /**      Add Command 
          */
         public static final int add_command_command_name=0x7f040004;
         public static final int add_command_image_type=0x7f040007;
         public static final int add_command_parent_menu=0x7f040006;
         public static final int add_command_vr_keyword=0x7f040005;
-        public static final int add_image=0x7f04004e;
+        public static final int add_image=0x7f040050;
         public static final int alert_duration_ms=0x7f040023;
         public static final int alert_duration_s=0x7f040022;
         public static final int alert_line1=0x7f04001e;
@@ -176,8 +184,8 @@ public final class R {
         public static final int app_name=0x7f040000;
         /**  Button Subscriptions 
          */
-        public static final int button_subscriptions_already_subscribed=0x7f040043;
-        public static final int button_subscriptions_none_subscribed=0x7f040044;
+        public static final int button_subscriptions_already_subscribed=0x7f040045;
+        public static final int button_subscriptions_none_subscribed=0x7f040046;
         public static final int choice_name=0x7f040018;
         public static final int clock=0x7f04002d;
         public static final int clock_hrs=0x7f04002e;
@@ -186,19 +194,19 @@ public final class R {
         public static final int colon=0x7f040031;
         /**  SDL Connection 
          */
-        public static final int connection_status_format=0x7f04003e;
+        public static final int connection_status_format=0x7f040040;
         public static final int did_location=0x7f04000c;
         /**      Get DTCs and Read DIDs 
          */
         public static final int ecu_name=0x7f04000b;
         /**  Function Banks 
          */
-        public static final int function_bank_root_name=0x7f040042;
-        public static final int hello_world=0x7f040051;
+        public static final int function_bank_root_name=0x7f040044;
+        public static final int hello_world=0x7f040053;
         public static final int hmi_language=0x7f04001c;
-        public static final int interaction_list_none_added=0x7f04004b;
-        public static final int ip_address=0x7f04003f;
-        public static final int ip_port=0x7f040040;
+        public static final int interaction_list_none_added=0x7f04004d;
+        public static final int ip_address=0x7f040041;
+        public static final int ip_port=0x7f040042;
         public static final int item_number=0x7f040016;
         /**      Choice Set Item 
          */
@@ -218,6 +226,8 @@ public final class R {
         public static final int menu_connect=0x7f040038;
         public static final int menu_disconnect=0x7f040039;
         public static final int menu_help=0x7f04003c;
+        public static final int menu_help_close=0x7f04003e;
+        public static final int menu_help_home=0x7f04003d;
         public static final int menu_reset=0x7f04003a;
         public static final int metadata_line1=0x7f040025;
         public static final int metadata_line2=0x7f040026;
@@ -238,21 +248,21 @@ public final class R {
         public static final int not_implemented=0x7f040036;
         /**  Offline Mode 
          */
-        public static final int offline_mode_text=0x7f040041;
-        public static final int perform_interaction_mode=0x7f040048;
-        public static final int perform_interaction_select_choice_set=0x7f040047;
-        public static final int perform_interaction_timeout=0x7f040049;
-        public static final int perform_interaction_timeout_enabled=0x7f04004a;
+        public static final int offline_mode_text=0x7f040043;
+        public static final int perform_interaction_mode=0x7f04004a;
+        public static final int perform_interaction_select_choice_set=0x7f040049;
+        public static final int perform_interaction_timeout=0x7f04004b;
+        public static final int perform_interaction_timeout_enabled=0x7f04004c;
         /**  Perform Interaction 
          */
-        public static final int perform_interaction_title=0x7f040045;
-        public static final int perform_interaction_voice_prompt=0x7f040046;
+        public static final int perform_interaction_title=0x7f040047;
+        public static final int perform_interaction_voice_prompt=0x7f040048;
         /**      Dialog Strings 
          */
         public static final int positive_button=0x7f040002;
         /**  Put File 
          */
-        public static final int put_file_persistent_file=0x7f04004c;
+        public static final int put_file_persistent_file=0x7f04004e;
         public static final int scrollable_message_clear=0x7f040014;
         public static final int scrollable_message_hint=0x7f040013;
         /**      Scrollable Message 
@@ -260,9 +270,9 @@ public final class R {
         public static final int scrollable_message_text=0x7f040012;
         /**  Dialog Strings 
          */
-        public static final int sdl_command_dialog_title=0x7f04003d;
+        public static final int sdl_command_dialog_title=0x7f04003f;
         public static final int sdl_disconnected=0x7f040001;
-        public static final int sdl_image_name=0x7f04004d;
+        public static final int sdl_image_name=0x7f04004f;
         public static final int slider_footer=0x7f04000e;
         public static final int slider_start_position=0x7f040010;
         public static final int slider_ticks=0x7f04000f;
@@ -278,7 +288,7 @@ public final class R {
          */
         public static final int text_to_speak=0x7f04001d;
         public static final int timeout=0x7f040011;
-        public static final int title_activity_help=0x7f04004f;
+        public static final int title_activity_help=0x7f040051;
         public static final int units_milliseconds=0x7f040034;
         /**      Unit Suffixes 
          */
index e088af6..86bc14b 100644 (file)
@@ -13,4 +13,3 @@
 # Project target.
 target=android-18
 android.library.reference.1=../LivioSdlUtilities
-android.library.reference.2=../../appcompat_v7
old mode 100644 (file)
new mode 100755 (executable)
index a4763d1..0461652
@@ -1,8 +1,9 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <classpath>
+       <classpathentry exported="true" kind="con" path="com.android.ide.eclipse.adt.ANDROID_FRAMEWORK"/>
+       <classpathentry exported="true" kind="con" path="com.android.ide.eclipse.adt.LIBRARIES"/>
+       <classpathentry exported="true" kind="con" path="com.android.ide.eclipse.adt.DEPENDENCIES"/>
        <classpathentry kind="src" path="src"/>
        <classpathentry kind="src" path="gen"/>
-       <classpathentry kind="con" path="com.android.ide.eclipse.adt.ANDROID_FRAMEWORK"/>
-       <classpathentry kind="con" path="com.android.ide.eclipse.adt.LIBRARIES"/>
        <classpathentry kind="output" path="bin/classes"/>
 </classpath>
old mode 100644 (file)
new mode 100755 (executable)
index bf214d5..adf5969
@@ -1,33 +1,33 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-       <name>SmartDeviceLinkProxyAndroid</name>
-       <comment></comment>
-       <projects>
-       </projects>
-       <buildSpec>
-               <buildCommand>
-                       <name>com.android.ide.eclipse.adt.ResourceManagerBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>com.android.ide.eclipse.adt.PreCompilerBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.jdt.core.javabuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>com.android.ide.eclipse.adt.ApkBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-       </buildSpec>
-       <natures>
-               <nature>com.android.ide.eclipse.adt.AndroidNature</nature>
-               <nature>org.eclipse.jdt.core.javanature</nature>
-       </natures>
-</projectDescription>
+<?xml version="1.0" encoding="UTF-8"?>\r
+<projectDescription>\r
+       <name>SmartDeviceLinkProxyAndroid</name>\r
+       <comment></comment>\r
+       <projects>\r
+       </projects>\r
+       <buildSpec>\r
+               <buildCommand>\r
+                       <name>com.android.ide.eclipse.adt.ResourceManagerBuilder</name>\r
+                       <arguments>\r
+                       </arguments>\r
+               </buildCommand>\r
+               <buildCommand>\r
+                       <name>com.android.ide.eclipse.adt.PreCompilerBuilder</name>\r
+                       <arguments>\r
+                       </arguments>\r
+               </buildCommand>\r
+               <buildCommand>\r
+                       <name>org.eclipse.jdt.core.javabuilder</name>\r
+                       <arguments>\r
+                       </arguments>\r
+               </buildCommand>\r
+               <buildCommand>\r
+                       <name>com.android.ide.eclipse.adt.ApkBuilder</name>\r
+                       <arguments>\r
+                       </arguments>\r
+               </buildCommand>\r
+       </buildSpec>\r
+       <natures>\r
+               <nature>com.android.ide.eclipse.adt.AndroidNature</nature>\r
+               <nature>org.eclipse.jdt.core.javanature</nature>\r
+       </natures>\r
+</projectDescription>\r
old mode 100644 (file)
new mode 100755 (executable)
index 8000cd6..54e493c
@@ -1,11 +1,11 @@
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.6
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.source=1.6
+eclipse.preferences.version=1\r
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled\r
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6\r
+org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve\r
+org.eclipse.jdt.core.compiler.compliance=1.6\r
+org.eclipse.jdt.core.compiler.debug.lineNumber=generate\r
+org.eclipse.jdt.core.compiler.debug.localVariable=generate\r
+org.eclipse.jdt.core.compiler.debug.sourceFile=generate\r
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error\r
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error\r
+org.eclipse.jdt.core.compiler.source=1.6\r
index d23ab8d..429b64f 100755 (executable)
@@ -1,2 +1,2 @@
-<manifest package="com.smartdevicelink" xmlns:android="http://schemas.android.com/apk/res/android"><application android:debuggable="true"></application>
-</manifest>
\ No newline at end of file
+<manifest package="com.smartdevicelink" xmlns:android="http://schemas.android.com/apk/res/android"><application android:debuggable="true"></application>\r
+</manifest>\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/bin/AndroidManifest.xml b/SDL_Android/SmartDeviceLinkProxyAndroid/bin/AndroidManifest.xml
new file mode 100644 (file)
index 0000000..429b64f
--- /dev/null
@@ -0,0 +1,2 @@
+<manifest package="com.smartdevicelink" xmlns:android="http://schemas.android.com/apk/res/android"><application android:debuggable="true"></application>\r
+</manifest>\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/gen/com/smartdevicelink/BuildConfig.java b/SDL_Android/SmartDeviceLinkProxyAndroid/gen/com/smartdevicelink/BuildConfig.java
new file mode 100644 (file)
index 0000000..cdc900f
--- /dev/null
@@ -0,0 +1,6 @@
+/** Automatically generated file. DO NOT MODIFY */
+package com.smartdevicelink;
+
+public final class BuildConfig {
+    public final static boolean DEBUG = true;
+}
\ No newline at end of file
old mode 100644 (file)
new mode 100755 (executable)
index a2de03e..8e4bc5f
@@ -8,5 +8,5 @@
 # project structure.
 
 # Project target.
-target=android-8
+target=android-19
 android.library=true
index 863d427..d31e1f3 100755 (executable)
@@ -1,49 +1,47 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.exception;
-
-public class SmartDeviceLinkException extends Exception {
-       
-       private static final long serialVersionUID = 5922492291870772815L;
-       
-       protected Throwable detail = null;
-       private SmartDeviceLinkExceptionCause _SmartDeviceLinkExceptionCause = null;
-       
-       public SmartDeviceLinkException(String msg, SmartDeviceLinkExceptionCause exceptionCause) {
-               super(msg);
-               _SmartDeviceLinkExceptionCause = exceptionCause;
-       }
-       
-       public SmartDeviceLinkException(String msg, Throwable ex, SmartDeviceLinkExceptionCause exceptionCause) {
-               super(msg + " --- Check inner exception for diagnostic details");
-               detail = ex;
-               _SmartDeviceLinkExceptionCause = exceptionCause;
-       }
-       
-       public SmartDeviceLinkException(Throwable ex) {
-               super(ex.getMessage());
-               detail = ex;
-       }
-       
-       public SmartDeviceLinkExceptionCause getSmartDeviceLinkExceptionCause() {
-               return _SmartDeviceLinkExceptionCause;
-       }
-       
-       public Throwable getInnerException() {
-               return detail;
-       }
-       
-       public String toString() {
-               String ret = this.getClass().getName();
-               ret += ": " + this.getMessage();
-               if(this.getSmartDeviceLinkExceptionCause() != null){
-                       ret += "\nSmartDeviceLinkExceptionCause: " + this.getSmartDeviceLinkExceptionCause().name();
-               }
-               if (detail != null) {
-                       ret += "\nnested: " + detail.toString();
-                       detail.printStackTrace();
-               }
-               return ret;
-       }
-}
+package com.smartdevicelink.exception;\r
+\r
+\r
+public class SmartDeviceLinkException extends Exception {\r
+       \r
+       private static final long serialVersionUID = 5922492291870772815L;\r
+       \r
+       protected Throwable detail = null;\r
+       private SmartDeviceLinkExceptionCause _SmartDeviceLinkExceptionCause = null;\r
+       \r
+       public SmartDeviceLinkException(String msg, SmartDeviceLinkExceptionCause exceptionCause) {\r
+               super(msg);\r
+               _SmartDeviceLinkExceptionCause = exceptionCause;\r
+       }\r
+       \r
+       public SmartDeviceLinkException(String msg, Throwable ex, SmartDeviceLinkExceptionCause exceptionCause) {\r
+               super(msg + " --- Check inner exception for diagnostic details");\r
+               detail = ex;\r
+               _SmartDeviceLinkExceptionCause = exceptionCause;\r
+       }\r
+       \r
+       public SmartDeviceLinkException(Throwable ex) {\r
+               super(ex.getMessage());\r
+               detail = ex;\r
+       }\r
+       \r
+       public SmartDeviceLinkExceptionCause getSmartDeviceLinkExceptionCause() {\r
+               return _SmartDeviceLinkExceptionCause;\r
+       }\r
+       \r
+       public Throwable getInnerException() {\r
+               return detail;\r
+       }\r
+       \r
+       public String toString() {\r
+               String ret = this.getClass().getName();\r
+               ret += ": " + this.getMessage();\r
+               if(this.getSmartDeviceLinkExceptionCause() != null){\r
+                       ret += "\nSmartDeviceLinkExceptionCause: " + this.getSmartDeviceLinkExceptionCause().name();\r
+               }\r
+               if (detail != null) {\r
+                       ret += "\nnested: " + detail.toString();\r
+                       detail.printStackTrace();\r
+               }\r
+               return ret;\r
+       }\r
+}\r
index 34a8b89..d83926f 100755 (executable)
@@ -1,21 +1,18 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.exception;
-
-public enum SmartDeviceLinkExceptionCause {
-       BLUETOOTH_ADAPTER_NULL,
-       BLUETOOTH_DISABLED,
-       HEARTBEAT_PAST_DUE,
-       INCORRECT_LIFECYCLE_MODEL,
-       INVALID_ARGUMENT,
-       INVALID_RPC_PARAMETER,
-       PERMISSION_DENIED,
-       RESERVED_CORRELATION_ID,
-       SMARTDEVICELINK_CONNECTION_FAILED,
-       SMARTDEVICELINK_PROXY_CYCLED,
-       SMARTDEVICELINK_PROXY_DISPOSED,
-       SMARTDEVICELINK_PROXY_OBSOLETE,
-       SMARTDEVICELINK_REGISTRATION_ERROR,
-       SMARTDEVICELINK_UNAVAILALBE;    
-}
+package com.smartdevicelink.exception;\r
+\r
+public enum SmartDeviceLinkExceptionCause {\r
+       BLUETOOTH_ADAPTER_NULL,\r
+       BLUETOOTH_DISABLED,\r
+       INCORRECT_LIFECYCLE_MODEL,\r
+       INVALID_ARGUMENT,\r
+       INVALID_RPC_PARAMETER,\r
+       PERMISSION_DENIED,\r
+       RESERVED_CORRELATION_ID,\r
+       SMARTDEVICELINK_CONNECTION_FAILED,\r
+       SMARTDEVICELINK_PROXY_CYCLED,\r
+       SMARTDEVICELINK_PROXY_DISPOSED,\r
+       SMARTDEVICELINK_PROXY_OBSOLETE,\r
+       SMARTDEVICELINK_REGISTRATION_ERROR,\r
+       SMARTDEVICELINK_UNAVAILALBE,\r
+       INVALID_HEADER; \r
+}\r
index 42bf46d..dd2039d 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.marshal;
-
-import java.util.Hashtable;
-import java.util.Iterator;
-import java.util.Vector;
-
-import org.json.JSONArray;
-import org.json.JSONException;
-import org.json.JSONObject;
-
-import com.smartdevicelink.proxy.RPCMessage;
-import com.smartdevicelink.proxy.RPCStruct;
-import com.smartdevicelink.trace.*;
-import com.smartdevicelink.trace.enums.InterfaceActivityDirection;
-import com.smartdevicelink.util.DebugTool;
-
-/*
- * Responsible for marshalling and unmarshing between RPC Objects and byte streams that are sent
- * over transmission
- */
-
-public class JsonRPCMarshaller {
-       
-       private static final String SMARTDEVICELINK_LIB_PRIVATE_KEY = "42baba60-eb57-11df-98cf-0800200c9a66";
-       
-       public static byte[] marshall(RPCMessage msg, byte version) {
-               byte[] jsonBytes = null;
-               try {
-                       JSONObject jsonObject = msg.serializeJSON(version);
-                       jsonBytes = jsonObject.toString().getBytes();
-                       
-                       SyncTrace.logMarshallingEvent(InterfaceActivityDirection.Transmit, jsonBytes, SMARTDEVICELINK_LIB_PRIVATE_KEY);
-               } catch (JSONException e) {
-                       DebugTool.logError("Failed to encode messages to JSON.", e);
-               }
-               return jsonBytes;
-       }
-       
-       public static Hashtable<String, Object> unmarshall(byte[] message) {
-               SyncTrace.logMarshallingEvent(InterfaceActivityDirection.Receive, message, SMARTDEVICELINK_LIB_PRIVATE_KEY);
-               Hashtable<String, Object> ret = null;
-               try {
-                       String jsonString = new String(message);
-                       JSONObject jsonObject = new JSONObject(jsonString);
-                       ret = deserializeJSONObject(jsonObject);
-               } catch (JSONException e) {
-                       DebugTool.logError("Failed to parse JSON", e);
-               }
-               return ret;
-       }
-       
-       public static Hashtable<String, Object> deserializeJSONObject(JSONObject jsonObject) 
-                       throws JSONException {
-               Hashtable<String, Object> ret = new Hashtable<String, Object>();
-               Iterator it = jsonObject.keys();
-               String key = null;
-               while (it.hasNext()) {
-                       key = (String) it.next();
-                       Object value = jsonObject.get(key);
-                       if (value instanceof JSONObject) {
-                               ret.put(key, deserializeJSONObject((JSONObject)value));
-                       } else if (value instanceof JSONArray) {
-                               JSONArray arrayValue = (JSONArray) value;
-                               Vector<Object> putList = new Vector<Object>(arrayValue.length());
-                               for (int i = 0; i < arrayValue.length(); i++) {
-                                       Object anObject = arrayValue.get(i); 
-                                       if (anObject instanceof JSONObject) {
-                                               Hashtable<String, Object> deserializedObject = deserializeJSONObject((JSONObject)anObject);
-                                               putList.add(deserializedObject);
-                                       } else {
-                                               putList.add(anObject);
-                                       }
-                               }
-                               ret.put(key, putList);
-                       } else {
-                               ret.put(key, value);
-                       }
-               }
-               return ret;
-       }
-       
-       private static JSONArray serializeVector(Vector vector) throws JSONException{
-               JSONArray toPut = new JSONArray();
-               Iterator<Object> valueIterator = (vector).iterator();
-               while(valueIterator.hasNext()){
-                       Object anObject = valueIterator.next();
-                       if (anObject instanceof RPCStruct) {
-                               RPCStruct toSerialize = (RPCStruct) anObject;
-                               toPut.put(toSerialize.serializeJSON());
-                       } else if(anObject instanceof Hashtable){
-                               Hashtable toSerialize = (Hashtable)anObject;
-                               toPut.put(serializeHashtable(toSerialize));
-                       } else {
-                               toPut.put(anObject);
-                       }
-               }
-               return toPut;
-       }
-
-       public static JSONObject serializeHashtable(Hashtable<String, Object> hash) throws JSONException{
-               JSONObject obj = new JSONObject();
-               Iterator<String> hashKeyIterator = hash.keySet().iterator();
-               while (hashKeyIterator.hasNext()){
-                       String key = (String) hashKeyIterator.next();
-                       Object value = hash.get(key);
-                       if (value instanceof RPCStruct) {
-                               obj.put(key, ((RPCStruct) value).serializeJSON());
-                       } else if (value instanceof Vector<?>) {
-                               obj.put(key, serializeVector((Vector) value));
-                       } else if (value instanceof Hashtable) {
-                               obj.put(key, serializeHashtable((Hashtable)value));
-                       } else {
-                               obj.put(key, value);
-                       }
-               }
-               return obj;
-       }
-}
+package com.smartdevicelink.marshal;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Iterator;\r
+import java.util.Vector;\r
+\r
+import org.json.JSONArray;\r
+import org.json.JSONException;\r
+import org.json.JSONObject;\r
+\r
+import com.smartdevicelink.proxy.RPCMessage;\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.trace.*;\r
+import com.smartdevicelink.trace.enums.InterfaceActivityDirection;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/*\r
+ * Responsible for marshalling and unmarshing between RPC Objects and byte streams that are sent\r
+ * over transmission\r
+ */\r
+\r
+public class JsonRPCMarshaller {\r
+       \r
+       private static final String SMARTDEVICELINK_LIB_PRIVATE_KEY = "42baba60-eb57-11df-98cf-0800200c9a66";\r
+       \r
+       public static byte[] marshall(RPCMessage msg, byte version) {\r
+               byte[] jsonBytes = null;\r
+               try {\r
+                       JSONObject jsonObject = msg.serializeJSON(version);\r
+                       jsonBytes = jsonObject.toString().getBytes();\r
+                       \r
+                       SmartDeviceLinkTrace.logMarshallingEvent(InterfaceActivityDirection.Transmit, jsonBytes, SMARTDEVICELINK_LIB_PRIVATE_KEY);\r
+               } catch (JSONException e) {\r
+                       DebugTool.logError("Failed to encode messages to JSON.", e);\r
+               }\r
+               return jsonBytes;\r
+       }\r
+       \r
+       public static Hashtable<String, Object> unmarshall(byte[] message) {\r
+               SmartDeviceLinkTrace.logMarshallingEvent(InterfaceActivityDirection.Receive, message, SMARTDEVICELINK_LIB_PRIVATE_KEY);\r
+               Hashtable<String, Object> ret = null;\r
+               try {\r
+                       String jsonString = new String(message);\r
+                       JSONObject jsonObject = new JSONObject(jsonString);\r
+                       ret = deserializeJSONObject(jsonObject);\r
+               } catch (JSONException e) {\r
+                       DebugTool.logError("Failed to parse JSON", e);\r
+               }\r
+               return ret;\r
+       }\r
+       \r
+       public static Hashtable<String, Object> deserializeJSONObject(JSONObject jsonObject) \r
+                       throws JSONException {\r
+               Hashtable<String, Object> ret = new Hashtable<String, Object>();\r
+               Iterator it = jsonObject.keys();\r
+               String key = null;\r
+               while (it.hasNext()) {\r
+                       key = (String) it.next();\r
+                       Object value = jsonObject.get(key);\r
+                       if (value instanceof JSONObject) {\r
+                               ret.put(key, deserializeJSONObject((JSONObject)value));\r
+                       } else if (value instanceof JSONArray) {\r
+                               JSONArray arrayValue = (JSONArray) value;\r
+                               Vector<Object> putList = new Vector<Object>(arrayValue.length());\r
+                               for (int i = 0; i < arrayValue.length(); i++) {\r
+                                       Object anObject = arrayValue.get(i); \r
+                                       if (anObject instanceof JSONObject) {\r
+                                               Hashtable<String, Object> deserializedObject = deserializeJSONObject((JSONObject)anObject);\r
+                                               putList.add(deserializedObject);\r
+                                       } else {\r
+                                               putList.add(anObject);\r
+                                       }\r
+                               }\r
+                               ret.put(key, putList);\r
+                       } else {\r
+                               ret.put(key, value);\r
+                       }\r
+               }\r
+               return ret;\r
+       }\r
+       \r
+       private static JSONArray serializeVector(Vector vector) throws JSONException{\r
+               JSONArray toPut = new JSONArray();\r
+               Iterator<Object> valueIterator = (vector).iterator();\r
+               while(valueIterator.hasNext()){\r
+                       Object anObject = valueIterator.next();\r
+                       if (anObject instanceof RPCStruct) {\r
+                               RPCStruct toSerialize = (RPCStruct) anObject;\r
+                               toPut.put(toSerialize.serializeJSON());\r
+                       } else if(anObject instanceof Hashtable){\r
+                               Hashtable toSerialize = (Hashtable)anObject;\r
+                               toPut.put(serializeHashtable(toSerialize));\r
+                       } else {\r
+                               toPut.put(anObject);\r
+                       }\r
+               }\r
+               return toPut;\r
+       }\r
+\r
+       public static JSONObject serializeHashtable(Hashtable<String, Object> hash) throws JSONException{\r
+               JSONObject obj = new JSONObject();\r
+               Iterator<String> hashKeyIterator = hash.keySet().iterator();\r
+               while (hashKeyIterator.hasNext()){\r
+                       String key = (String) hashKeyIterator.next();\r
+                       Object value = hash.get(key);\r
+                       if (value instanceof RPCStruct) {\r
+                               obj.put(key, ((RPCStruct) value).serializeJSON());\r
+                       } else if (value instanceof Vector<?>) {\r
+                               obj.put(key, serializeVector((Vector) value));\r
+                       } else if (value instanceof Hashtable) {\r
+                               obj.put(key, serializeHashtable((Hashtable)value));\r
+                       } else {\r
+                               obj.put(key, value);\r
+                       }\r
+               }\r
+               return obj;\r
+       }\r
+       \r
+       /*\r
+       public static JSONObject serializeHashtable(Hashtable<String, Object> hash) \r
+                       throws JSONException {\r
+               JSONObject obj = new JSONObject();\r
+               Iterator<String> hashKeyIterator = hash.keySet().iterator();\r
+               while (hashKeyIterator.hasNext()) {\r
+                       String key = (String) hashKeyIterator.next();\r
+                       Object value = hash.get(key);\r
+                       if (value instanceof RPCStruct) {\r
+                               obj.put(key, ((RPCStruct) value).serializeJSON());\r
+                       } else if (value instanceof Vector<?>) {\r
+                               JSONArray toPut = new JSONArray();\r
+                               Iterator<Object> valueIterator = ((Vector) value).iterator();\r
+                               while (valueIterator.hasNext()) {\r
+                                       Object anObject = valueIterator.next();                                 \r
+                                       if (anObject instanceof RPCStruct) {\r
+                                               RPCStruct toSerialize = (RPCStruct) anObject;\r
+                                               toPut.put(toSerialize.serializeJSON());\r
+                                       } else if (anObject instanceof Hashtable) {\r
+                                               Hashtable hashtable = (Hashtable) anObject;\r
+                                               RPCStruct toSerialize = new RPCStruct(hashtable);\r
+                                               toPut.put(toSerialize.serializeJSON());\r
+                                       } else {\r
+                                               toPut.put(anObject);\r
+                                       }\r
+                               }\r
+                               obj.put(key, toPut);\r
+                       } else if (value instanceof Hashtable) {\r
+                               obj.put(key, serializeHashtable((Hashtable)value));\r
+                       } else {\r
+                               obj.put(key, value);\r
+                       }\r
+               }\r
+               return obj;\r
+       }\r
+       */\r
+}\r
index defdc9f..732496a 100755 (executable)
@@ -1,12 +1,9 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.messageDispatcher;
-
-public interface IDispatchingStrategy<messageType> {
-       public void dispatch(messageType message);
-       
-       public void handleDispatchingError(String info, Exception ex);
-       
-       public void handleQueueingError(String info, Exception ex);
-}
+package com.smartdevicelink.messageDispatcher;\r
+\r
+public interface IDispatchingStrategy<messageType> {\r
+       public void dispatch(messageType message);\r
+       \r
+       public void handleDispatchingError(String info, Exception ex);\r
+       \r
+       public void handleQueueingError(String info, Exception ex);\r
+}\r
index f59810b..54ce901 100755 (executable)
@@ -1,17 +1,14 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.messageDispatcher;
-
-import java.util.Comparator;
-
-import com.smartdevicelink.protocol.ProtocolMessage;
-
-public class IncomingProtocolMessageComparitor implements Comparator<ProtocolMessage> {
-
-       @Override
-       public int compare(ProtocolMessage arg0, ProtocolMessage arg1) {
-               // Always return 0, turning the priority queue into a FIFO queue. 
-               return 0;
-       }
-}
+package com.smartdevicelink.messageDispatcher;\r
+\r
+import java.util.Comparator;\r
+\r
+import com.smartdevicelink.protocol.ProtocolMessage;\r
+\r
+public class IncomingProtocolMessageComparitor implements Comparator<ProtocolMessage> {\r
+\r
+       @Override\r
+       public int compare(ProtocolMessage arg0, ProtocolMessage arg1) {\r
+               // Always return 0, turning the priority queue into a FIFO queue. \r
+               return 0;\r
+       }\r
+}\r
index 92de89e..56aa5ca 100755 (executable)
@@ -1,17 +1,14 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.messageDispatcher;
-
-import java.util.Comparator;
-
-import com.smartdevicelink.proxy.callbacks.InternalProxyMessage;
-
-public class InternalProxyMessageComparitor implements Comparator<InternalProxyMessage> {
-
-       @Override
-       public int compare(InternalProxyMessage arg0, InternalProxyMessage arg1) {
-               // Always return 0, turning the priority queue into a FIFO queue. 
-               return 0;
-       }
-}
+package com.smartdevicelink.messageDispatcher;\r
+\r
+import java.util.Comparator;\r
+\r
+import com.smartdevicelink.proxy.callbacks.InternalProxyMessage;\r
+\r
+public class InternalProxyMessageComparitor implements Comparator<InternalProxyMessage> {\r
+\r
+       @Override\r
+       public int compare(InternalProxyMessage arg0, InternalProxyMessage arg1) {\r
+               // Always return 0, turning the priority queue into a FIFO queue. \r
+               return 0;\r
+       }\r
+}\r
index 9545689..73cc7ed 100755 (executable)
@@ -1,18 +1,15 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.messageDispatcher;
-
-import java.util.Comparator;
-
-import com.smartdevicelink.protocol.ProtocolMessage;
-
-public class OutgoingProtocolMessageComparitor implements Comparator<ProtocolMessage> {
-
-       @Override
-       public int compare(ProtocolMessage arg0, ProtocolMessage arg1) {
-               // Always return 0, turning the priority queue into a FIFO queue. 
-               return 0;
-       }
-}
-
+package com.smartdevicelink.messageDispatcher;\r
+\r
+import java.util.Comparator;\r
+\r
+import com.smartdevicelink.protocol.ProtocolMessage;\r
+\r
+public class OutgoingProtocolMessageComparitor implements Comparator<ProtocolMessage> {\r
+\r
+       @Override\r
+       public int compare(ProtocolMessage arg0, ProtocolMessage arg1) {\r
+               // Always return 0, turning the priority queue into a FIFO queue. \r
+               return 0;\r
+       }\r
+}\r
+\r
index b3f72b0..ca73b3f 100755 (executable)
@@ -1,68 +1,65 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.messageDispatcher;
-
-import java.util.Comparator;
-import java.util.concurrent.PriorityBlockingQueue;
-
-import com.smartdevicelink.util.DebugTool;
-
-public class ProxyMessageDispatcher<messageType> {
-       PriorityBlockingQueue<messageType> _queue = null;
-       private Thread _messageDispatchingThread = null;
-       IDispatchingStrategy<messageType> _strategy = null;
-
-       // Boolean to track if disposed
-       private Boolean dispatcherDisposed = false;
-       
-       public ProxyMessageDispatcher(String THREAD_NAME, Comparator<messageType> messageComparator, 
-                       IDispatchingStrategy<messageType> strategy) {
-               _queue = new PriorityBlockingQueue<messageType>(10, messageComparator);
-               
-               _strategy = strategy;
-               
-               // Create dispatching thread
-               _messageDispatchingThread = new Thread(new Runnable() {public void run(){handleMessages();}});
-               _messageDispatchingThread.setName(THREAD_NAME);
-               _messageDispatchingThread.setDaemon(true);
-               _messageDispatchingThread.start();
-       }
-       
-       public void dispose() {
-               dispatcherDisposed = true;
-               
-               if(_messageDispatchingThread != null) {
-                       _messageDispatchingThread.interrupt();
-                       _messageDispatchingThread = null;
-               }
-       }
-               
-       private void handleMessages() {
-               
-               try {
-                       messageType thisMessage;
-               
-                       while(dispatcherDisposed == false) {
-                               thisMessage = _queue.take();
-                               _strategy.dispatch(thisMessage);
-                       }
-               } catch (InterruptedException e) {
-                       // Thread was interrupted by dispose() method, no action required
-                       return;
-               } catch (Exception e) {
-                       DebugTool.logError("Error occurred dispating message.", e);
-                       _strategy.handleDispatchingError("Error occurred dispating message.", e);
-               }
-       }
-               
-       public void queueMessage(messageType message) {
-               try {
-                       _queue.put(message);
-               } catch(ClassCastException e) { 
-                       _strategy.handleQueueingError("ClassCastException encountered when queueing message.", e);
-               } catch(Exception e) {
-                       _strategy.handleQueueingError("Exception encountered when queueing message.", e);
-               }
-       }
-}
+package com.smartdevicelink.messageDispatcher;\r
+\r
+import java.util.Comparator;\r
+import java.util.concurrent.PriorityBlockingQueue;\r
+\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+public class ProxyMessageDispatcher<messageType> {\r
+       PriorityBlockingQueue<messageType> _queue = null;\r
+       private Thread _messageDispatchingThread = null;\r
+       IDispatchingStrategy<messageType> _strategy = null;\r
+\r
+       // Boolean to track if disposed\r
+       private Boolean dispatcherDisposed = false;\r
+       \r
+       public ProxyMessageDispatcher(String THREAD_NAME, Comparator<messageType> messageComparator, \r
+                       IDispatchingStrategy<messageType> strategy) {\r
+               _queue = new PriorityBlockingQueue<messageType>(10, messageComparator);\r
+               \r
+               _strategy = strategy;\r
+               \r
+               // Create dispatching thread\r
+               _messageDispatchingThread = new Thread(new Runnable() {public void run(){handleMessages();}});\r
+               _messageDispatchingThread.setName(THREAD_NAME);\r
+               _messageDispatchingThread.setDaemon(true);\r
+               _messageDispatchingThread.start();\r
+       }\r
+       \r
+       public void dispose() {\r
+               dispatcherDisposed = true;\r
+               \r
+               if(_messageDispatchingThread != null) {\r
+                       _messageDispatchingThread.interrupt();\r
+                       _messageDispatchingThread = null;\r
+               }\r
+       }\r
+               \r
+       private void handleMessages() {\r
+               \r
+               try {\r
+                       messageType thisMessage;\r
+               \r
+                       while(dispatcherDisposed == false) {\r
+                               thisMessage = _queue.take();\r
+                               _strategy.dispatch(thisMessage);\r
+                       }\r
+               } catch (InterruptedException e) {\r
+                       // Thread was interrupted by dispose() method, no action required\r
+                       return;\r
+               } catch (Exception e) {\r
+                       DebugTool.logError("Error occurred dispating message.", e);\r
+                       _strategy.handleDispatchingError("Error occurred dispating message.", e);\r
+               }\r
+       }\r
+               \r
+       public void queueMessage(messageType message) {\r
+               try {\r
+                       _queue.put(message);\r
+               } catch(ClassCastException e) { \r
+                       _strategy.handleQueueingError("ClassCastException encountered when queueing message.", e);\r
+               } catch(Exception e) {\r
+                       _strategy.handleQueueingError("Exception encountered when queueing message.", e);\r
+               }\r
+       }\r
+}\r
index dbbc242..fde67d6 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.protocol;
-
-import com.smartdevicelink.protocol.SmartDeviceLinkProtocol.MessageFrameAssembler;
-import com.smartdevicelink.protocol.enums.SessionType;
-import com.smartdevicelink.trace.SyncTrace;
-import com.smartdevicelink.trace.enums.InterfaceActivityDirection;
-
-public abstract class AbstractProtocol {
-       private static final String SmartDeviceLink_LIB_TRACE_KEY = "42baba60-eb57-11df-98cf-0800200c9a66";
-       
-       private IProtocolListener _protocolListener = null;
-       
-       // Lock to ensure all frames are sent uninterupted 
-       private Object _frameLock = new Object();
-
-       // Caller must provide a non-null IProtocolListener interface reference.
-       public AbstractProtocol(IProtocolListener protocolListener) {
-               if (protocolListener == null) {
-               throw new IllegalArgumentException("Provided protocol listener interface reference is null");
-               } // end-if
-               
-               _protocolListener = protocolListener;
-       } // end-ctor
-
-       // This method receives raw bytes as they arrive from transport.  Those bytes
-       // are then collected by the protocol and assembled into complete messages and
-       // handled internally by the protocol or propagated to the protocol listener.
-       public abstract void HandleReceivedBytes(byte[] receivedBytes, int length);
-
-       // This method receives a protocol message (e.g. RPC, BULK, etc.) and processes
-       // it for transmission over the transport.  The results of this processing will
-       // be sent to the onProtocolMessageBytesToSend() method on protocol listener
-       // interface.  Note that the ProtocolMessage itself contains information
-       // about the type of message (e.g. RPC, BULK, etc.) and the protocol session
-       // over which to send the message, etc.
-       public abstract void SendMessage(ProtocolMessage msg);
-
-       // This method starts a protocol session.  A corresponding call to the protocol
-       // listener onProtocolSessionStarted() method will be made when the protocol
-       // session has been established.
-       public abstract void StartProtocolSession(SessionType sessionType);
-
-       // This method ends a protocol session.  A corresponding call to the protocol
-       // listener onProtocolSessionEnded() method will be made when the protocol
-       // session has ended.
-       public abstract void EndProtocolSession(SessionType sessionType, byte sessionID);
-       
-       // This method is called whenever the protocol receives a complete frame
-       protected void handleProtocolFrameReceived(ProtocolFrameHeader header, byte[] data, MessageFrameAssembler assembler) {
-               SyncTrace.logProtocolEvent(InterfaceActivityDirection.Receive, header, data, 
-                               0, data.length, SmartDeviceLink_LIB_TRACE_KEY);
-               
-               assembler.handleFrame(header, data);
-       }
-       
-       // This method is called whenever a protocol has an entire frame to send
-       protected void handleProtocolFrameToSend(ProtocolFrameHeader header, byte[] data, int offset, int length) {
-               SyncTrace.logProtocolEvent(InterfaceActivityDirection.Transmit, header, data, 
-                               offset, length, SmartDeviceLink_LIB_TRACE_KEY);
-               
-               synchronized(_frameLock) {
-                       byte[] frameHeader = header.assembleHeaderBytes();
-                       handleProtocolMessageBytesToSend(frameHeader, 0, frameHeader.length);
-                       
-                       if (data != null) {
-                               handleProtocolMessageBytesToSend(data, offset, length);
-                       } // end-if
-               }
-       }
-       
-       // This method handles protocol message bytes that are ready to send.
-       // A callback is sent to the protocol listener.
-       protected void handleProtocolMessageBytesToSend(byte[] bytesToSend,
-                       int offset, int length) {
-               _protocolListener.onProtocolMessageBytesToSend(bytesToSend, offset, length);
-       }
-       
-       // This method handles received protocol messages. 
-       protected void handleProtocolMessageReceived(ProtocolMessage message) {
-               _protocolListener.onProtocolMessageReceived(message);
-       }
-       
-       // This method handles the end of a protocol session. A callback is 
-       // sent to the protocol listener.
-       protected void handleProtocolSessionEnded(SessionType sessionType,
-                       byte sessionID, String correlationID) {
-               _protocolListener.onProtocolSessionEnded(sessionType, sessionID, correlationID);
-       }
-       
-       // This method handles the startup of a protocol session. A callback is sent
-       // to the protocol listener.
-       protected void handleProtocolSessionStarted(SessionType sessionType,
-                       byte sessionID, byte version, String correlationID) {
-               _protocolListener.onProtocolSessionStarted(sessionType, sessionID, version, correlationID);
-       }
-       
-       // This method handles protocol errors. A callback is sent to the protocol
-       // listener.
-       protected void handleProtocolError(String string, Exception ex) {
-               _protocolListener.onProtocolError(string, ex);
-       }
-} // end-class
+package com.smartdevicelink.protocol;\r
+\r
+import com.smartdevicelink.protocol.SmartDeviceLinkProtocol.MessageFrameAssembler;\r
+import com.smartdevicelink.protocol.enums.SessionType;\r
+import com.smartdevicelink.trace.SmartDeviceLinkTrace;\r
+import com.smartdevicelink.trace.enums.InterfaceActivityDirection;\r
+\r
+public abstract class AbstractProtocol {\r
+       private static final String SMARTDEVICELINK_LIB_TRACE_KEY = "42baba60-eb57-11df-98cf-0800200c9a66";\r
+       \r
+       private IProtocolListener _protocolListener = null;\r
+       //protected IProtocolListener ProtocolListener() { return _protocolListener; }\r
+       \r
+       // Lock to ensure all frames are sent uninterupted \r
+       private Object _frameLock = new Object();\r
+\r
+       // Caller must provide a non-null IProtocolListener interface reference.\r
+       public AbstractProtocol(IProtocolListener protocolListener) {\r
+               if (protocolListener == null) {\r
+               throw new IllegalArgumentException("Provided protocol listener interface reference is null");\r
+               } // end-if\r
+               \r
+               _protocolListener = protocolListener;\r
+       } // end-ctor\r
+\r
+       // This method receives raw bytes as they arrive from transport.  Those bytes\r
+       // are then collected by the protocol and assembled into complete messages and\r
+       // handled internally by the protocol or propagated to the protocol listener.\r
+       public abstract void HandleReceivedBytes(byte[] receivedBytes, int length);\r
+\r
+       // This method receives a protocol message (e.g. RPC, BULK, etc.) and processes\r
+       // it for transmission over the transport.  The results of this processing will\r
+       // be sent to the onProtocolMessageBytesToSend() method on protocol listener\r
+       // interface.  Note that the ProtocolMessage itself contains information\r
+       // about the type of message (e.g. RPC, BULK, etc.) and the protocol session\r
+       // over which to send the message, etc.\r
+       public abstract void SendMessage(ProtocolMessage msg);\r
+\r
+       // This method starts a protocol session.  A corresponding call to the protocol\r
+       // listener onProtocolSessionStarted() method will be made when the protocol\r
+       // session has been established.\r
+       public abstract void StartProtocolSession(SessionType sessionType);\r
+\r
+       // This method ends a protocol session.  A corresponding call to the protocol\r
+       // listener onProtocolSessionEnded() method will be made when the protocol\r
+       // session has ended.\r
+       public abstract void EndProtocolSession(SessionType sessionType, byte sessionID);\r
+       \r
+       // This method is called whenever the protocol receives a complete frame\r
+       protected void handleProtocolFrameReceived(ProtocolFrameHeader header, byte[] data, MessageFrameAssembler assembler) {\r
+               SmartDeviceLinkTrace.logProtocolEvent(InterfaceActivityDirection.Receive, header, data, \r
+                               0, data.length, SMARTDEVICELINK_LIB_TRACE_KEY);\r
+               \r
+               assembler.handleFrame(header, data);\r
+       }\r
+       \r
+       // This method is called whenever a protocol has an entire frame to send\r
+       protected void handleProtocolFrameToSend(ProtocolFrameHeader header, byte[] data, int offset, int length) {\r
+               SmartDeviceLinkTrace.logProtocolEvent(InterfaceActivityDirection.Transmit, header, data, \r
+                               offset, length, SMARTDEVICELINK_LIB_TRACE_KEY);\r
+               \r
+               synchronized(_frameLock) {\r
+                       byte[] frameHeader = header.assembleHeaderBytes();\r
+                       handleProtocolMessageBytesToSend(frameHeader, 0, frameHeader.length);\r
+                       \r
+                       if (data != null) {\r
+                               handleProtocolMessageBytesToSend(data, offset, length);\r
+                       } // end-if\r
+               }\r
+       }\r
+       \r
+       // This method handles protocol message bytes that are ready to send.\r
+       // A callback is sent to the protocol listener.\r
+       protected void handleProtocolMessageBytesToSend(byte[] bytesToSend,\r
+                       int offset, int length) {\r
+               _protocolListener.onProtocolMessageBytesToSend(bytesToSend, offset, length);\r
+       }\r
+       \r
+       // This method handles received protocol messages. \r
+       protected void handleProtocolMessageReceived(ProtocolMessage message) {\r
+               _protocolListener.onProtocolMessageReceived(message);\r
+       }\r
+       \r
+       // This method handles the end of a protocol session. A callback is \r
+       // sent to the protocol listener.\r
+       protected void handleProtocolSessionEnded(SessionType sessionType,\r
+                       byte sessionID, String correlationID) {\r
+               _protocolListener.onProtocolSessionEnded(sessionType, sessionID, correlationID);\r
+       }\r
+       \r
+       // This method handles the startup of a protocol session. A callback is sent\r
+       // to the protocol listener.\r
+       protected void handleProtocolSessionStarted(SessionType sessionType,\r
+                       byte sessionID, byte version, String correlationID) {\r
+               _protocolListener.onProtocolSessionStarted(sessionType, sessionID, version, correlationID);\r
+       }\r
+       \r
+       // This method handles protocol errors. A callback is sent to the protocol\r
+       // listener.\r
+       protected void handleProtocolError(String string, Exception ex) {\r
+               _protocolListener.onProtocolError(string, ex);\r
+       }\r
+} // end-class\r
old mode 100644 (file)
new mode 100755 (executable)
index 65985ee..e5bc9d7
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.protocol;
-
-import com.smartdevicelink.util.BitConverter;
-
-public class BinaryFrameHeader {
-       private byte _rpcType;
-       private int _functionID;
-       private int _correlationID;
-       private int _jsonSize;
-       
-       private byte[] _jsonData;
-       private byte[] _bulkData;
-       
-       public BinaryFrameHeader() {}
-       
-       public static BinaryFrameHeader parseBinaryHeader(byte[] binHeader) {
-               BinaryFrameHeader msg = new BinaryFrameHeader();
-               
-               byte RPC_Type = (byte) (binHeader[0] >>> 4);
-               msg.setRPCType(RPC_Type);
-               
-               int _functionID = (BitConverter.intFromByteArray(binHeader, 0) & 0x0FFFFFFF);
-               msg.setFunctionID(_functionID);
-               
-               int corrID = BitConverter.intFromByteArray(binHeader, 4);
-               msg.setCorrID(corrID);
-               
-               int _jsonSize = BitConverter.intFromByteArray(binHeader, 8);
-               msg.setJsonSize(_jsonSize);
-               
-               if (_jsonSize > 0) {
-                       byte[] _jsonData = new byte[_jsonSize];
-                       System.arraycopy(binHeader, 12, _jsonData, 0, _jsonSize);
-                       msg.setJsonData(_jsonData);
-               }
-               
-               if (binHeader.length - _jsonSize - 12 > 0) {
-                       byte[] _bulkData = new byte[binHeader.length - _jsonSize - 12];
-                       System.arraycopy(binHeader, 12 + _jsonSize, _bulkData, 0, _bulkData.length);
-                       msg.setBulkData(_bulkData);
-               }               
-               
-               return msg;
-       }
-       
-       protected byte[] assembleHeaderBytes() {
-               int binHeader = _functionID;
-               binHeader |= (_rpcType << 28);
-               
-               byte[] ret = new byte[12];
-               System.arraycopy(BitConverter.intToByteArray(binHeader), 0, ret, 0, 4);
-               System.arraycopy(BitConverter.intToByteArray(_correlationID), 0, ret, 4, 4);
-               System.arraycopy(BitConverter.intToByteArray(_jsonSize), 0, ret, 8, 4);
-               
-               return ret;
-       }
-       
-       public byte getRPCType() {
-               return _rpcType;
-       }
-
-       public void setRPCType(byte _rpcType) {
-               this._rpcType = _rpcType;
-       }
-
-       public int getFunctionID() {
-               return _functionID;
-       }
-
-       public void setFunctionID(int _functionID) {
-               this._functionID = _functionID;
-       }
-
-       public int getCorrID() {
-               return _correlationID;
-       }
-
-       public void setCorrID(int _correlationID) {
-               this._correlationID = _correlationID;
-       }
-
-       public int getJsonSize() {
-               return _jsonSize;
-       }
-
-       public void setJsonSize(int _jsonSize) {
-               this._jsonSize = _jsonSize;
-       }
-       
-       public byte[] getJsonData() {
-               return _jsonData;
-       }
-       
-       public void setJsonData(byte[] _jsonData) {
-               this._jsonData = new byte[this._jsonSize];
-               System.arraycopy(_jsonData, 0, this._jsonData, 0, _jsonSize);
-       }
-       
-       public byte[] getBulkData() {
-               return _bulkData;
-       }
-       
-       public void setBulkData(byte[] _bulkData) {
-               this._bulkData = _bulkData;
-       }
-}
+package com.smartdevicelink.protocol;\r
+\r
+import com.smartdevicelink.util.BitConverter;\r
+\r
+public class BinaryFrameHeader {\r
+       private byte _rpcType;\r
+       private int _functionID;\r
+       private int _correlationID;\r
+       private int _jsonSize;\r
+       \r
+       private byte[] _jsonData;\r
+       private byte[] _bulkData;\r
+       \r
+       public BinaryFrameHeader() {}\r
+       \r
+       public static BinaryFrameHeader parseBinaryHeader(byte[] binHeader) {\r
+               BinaryFrameHeader msg = new BinaryFrameHeader();\r
+               \r
+               byte RPC_Type = (byte) (binHeader[0] >>> 4);\r
+               msg.setRPCType(RPC_Type);\r
+               \r
+               int _functionID = (BitConverter.intFromByteArray(binHeader, 0) & 0x0FFFFFFF);\r
+               msg.setFunctionID(_functionID);\r
+               \r
+               int corrID = BitConverter.intFromByteArray(binHeader, 4);\r
+               msg.setCorrID(corrID);\r
+               \r
+               int _jsonSize = BitConverter.intFromByteArray(binHeader, 8);\r
+               msg.setJsonSize(_jsonSize);\r
+               \r
+               if (_jsonSize > 0) {\r
+                       byte[] _jsonData = new byte[_jsonSize];\r
+                       System.arraycopy(binHeader, 12, _jsonData, 0, _jsonSize);\r
+                       msg.setJsonData(_jsonData);\r
+               }\r
+               \r
+               if (binHeader.length - _jsonSize - 12 > 0) {\r
+                       byte[] _bulkData = new byte[binHeader.length - _jsonSize - 12];\r
+                       System.arraycopy(binHeader, 12 + _jsonSize, _bulkData, 0, _bulkData.length);\r
+                       msg.setBulkData(_bulkData);\r
+               }               \r
+               \r
+               return msg;\r
+       }\r
+       \r
+       protected byte[] assembleHeaderBytes() {\r
+               int binHeader = _functionID;\r
+               binHeader |= (_rpcType << 28);\r
+               \r
+               byte[] ret = new byte[12];\r
+               System.arraycopy(BitConverter.intToByteArray(binHeader), 0, ret, 0, 4);\r
+               System.arraycopy(BitConverter.intToByteArray(_correlationID), 0, ret, 4, 4);\r
+               System.arraycopy(BitConverter.intToByteArray(_jsonSize), 0, ret, 8, 4);\r
+               \r
+               return ret;\r
+       }\r
+       \r
+       public byte getRPCType() {\r
+               return _rpcType;\r
+       }\r
+\r
+       public void setRPCType(byte _rpcType) {\r
+               this._rpcType = _rpcType;\r
+       }\r
+\r
+       public int getFunctionID() {\r
+               return _functionID;\r
+       }\r
+\r
+       public void setFunctionID(int _functionID) {\r
+               this._functionID = _functionID;\r
+       }\r
+\r
+       public int getCorrID() {\r
+               return _correlationID;\r
+       }\r
+\r
+       public void setCorrID(int _correlationID) {\r
+               this._correlationID = _correlationID;\r
+       }\r
+\r
+       public int getJsonSize() {\r
+               return _jsonSize;\r
+       }\r
+\r
+       public void setJsonSize(int _jsonSize) {\r
+               this._jsonSize = _jsonSize;\r
+       }\r
+       \r
+       public byte[] getJsonData() {\r
+               return _jsonData;\r
+       }\r
+       \r
+       public void setJsonData(byte[] _jsonData) {\r
+               this._jsonData = new byte[this._jsonSize];\r
+               System.arraycopy(_jsonData, 0, this._jsonData, 0, _jsonSize);\r
+               //this._jsonData = _jsonData;\r
+       }\r
+       \r
+       public byte[] getBulkData() {\r
+               return _bulkData;\r
+       }\r
+       \r
+       public void setBulkData(byte[] _bulkData) {\r
+               this._bulkData = _bulkData;\r
+       }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/protocol/IProtocol.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/protocol/IProtocol.java
deleted file mode 100755 (executable)
index 5acba98..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.protocol;
-
-import com.smartdevicelink.protocol.enums.SessionType;
-import com.smartdevicelink.transport.ISmartDeviceLinkTransport;
-import com.smartdevicelink.transport.ITransportListener;
-
-public interface IProtocol extends ITransportListener {
-
-       void handleBytesFromTransport(byte[] receivedBytes, int receivedBytesLength);
-       public void sendStartSession(SessionType sessionType);
-       public void sendEndSession(SessionType sessionType, byte sessionID);
-       
-       public void sendData(SessionType sessionType, byte sessionID, byte[] data);
-       
-       public ISmartDeviceLinkTransport getTransport();
-       public void setTransport(ISmartDeviceLinkTransport transport);
-       
-       void addProtocolListener(IProtocolListener listener);
-       boolean removeProtocolListener(IProtocolListener listener);
-       
-       public void close();
-}
index b660030..b031d0a 100755 (executable)
@@ -1,25 +1,22 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.protocol;
-
-import com.smartdevicelink.protocol.enums.*;
-
-public interface IProtocolListener {
-       // Called to indicate that these bytes are to be sent as part of a message.
-       // This call includes the part of the message.
-       void onProtocolMessageBytesToSend(byte[] msgBytes, int offset, int length);
-
-       // Called to indicate that a complete message (RPC, BULK, etc.) has been
-       // received.  This call includes the message.
-       void onProtocolMessageReceived(ProtocolMessage msg);
-
-       // Called to indicate that a protocol session has been started (from either side)
-       void onProtocolSessionStarted(SessionType sessionType, byte sessionID, byte version, String correlationID);
-
-       // Called to indicate that a protocol session has ended (from either side)
-       void onProtocolSessionEnded(SessionType sessionType, byte sessionID, String correlationID /*, String info, Exception ex*/);
-
-       // Called to indicate that a protocol error was detected in received data.
-       void onProtocolError(String info, Exception e);
-} // end-interfCe
+package com.smartdevicelink.protocol;\r
+\r
+import com.smartdevicelink.protocol.enums.*;\r
+\r
+public interface IProtocolListener {\r
+       // Called to indicate that these bytes are to be sent as part of a message.\r
+       // This call includes the part of the message.\r
+       void onProtocolMessageBytesToSend(byte[] msgBytes, int offset, int length);\r
+\r
+       // Called to indicate that a complete message (RPC, BULK, etc.) has been\r
+       // received.  This call includes the message.\r
+       void onProtocolMessageReceived(ProtocolMessage msg);\r
+\r
+       // Called to indicate that a protocol session has been started (from either side)\r
+       void onProtocolSessionStarted(SessionType sessionType, byte sessionID, byte version, String correlationID);\r
+\r
+       // Called to indicate that a protocol session has ended (from either side)\r
+       void onProtocolSessionEnded(SessionType sessionType, byte sessionID, String correlationID /*, String info, Exception ex*/);\r
+\r
+       // Called to indicate that a protocol error was detected in received data.\r
+       void onProtocolError(String info, Exception e);\r
+} // end-interfCe
\ No newline at end of file
index be8bd87..134e7cd 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.protocol;
-
-import com.smartdevicelink.protocol.enums.FrameType;
-import com.smartdevicelink.protocol.enums.SessionType;
-import com.smartdevicelink.util.BitConverter;
-
-public class ProtocolFrameHeader {
-       private byte version = 1;
-       private boolean compressed = false;
-       private FrameType frameType = FrameType.Control;
-       private SessionType sessionType = SessionType.RPC;
-       private byte frameData = 0;
-       private byte sessionID;
-       private int dataSize;
-       private int messageID;
-       
-       public static final byte FrameDataSingleFrame = 0x00;
-       public static final byte FrameDataFirstFrame = 0x00;
-       public static final byte FrameDataFinalConsecutiveFrame = 0x00;
-       
-       public ProtocolFrameHeader() {}
-       
-       public static ProtocolFrameHeader parseWiProHeader(byte[] header) {
-               ProtocolFrameHeader msg = new ProtocolFrameHeader();
-               
-               byte version = (byte) (header[0] >>> 4);
-               msg.setVersion(version);
-               
-               boolean compressed = 1 == ((header[0] & 0x08) >>> 3);
-               msg.setCompressed(compressed);
-               
-               byte frameType = (byte) (header[0] & 0x07);
-               msg.setFrameType(FrameType.valueOf(frameType));
-               
-               byte serviceType = header[1];
-               msg.setSessionType(SessionType.valueOf(serviceType));
-               
-               byte frameData = header[2];
-               msg.setFrameData(frameData);
-               
-               byte sessionID = header[3];
-               msg.setSessionID(sessionID);
-               
-               int dataSize = BitConverter.intFromByteArray(header, 4);
-               msg.setDataSize(dataSize);
-               
-               if (version == 2) {
-                       int messageID = BitConverter.intFromByteArray(header, 8);
-                       msg.setMessageID(messageID);
-               } else msg.setMessageID(0);
-               
-               return msg;
-       }
-       
-       protected byte[] assembleHeaderBytes() {
-               int header = 0;
-               header |= version;
-               header <<= 1;
-               header |= (compressed ? 1 : 0);
-               header <<= 3;
-               header |= frameType.value();
-               header <<= 8;
-               header |= sessionType.value();
-               header <<= 8;
-               header |= frameData;
-               header <<= 8;
-               header |= sessionID;
-               
-               if (version == 1) {
-                       byte[] ret = new byte[8];
-                       System.arraycopy(BitConverter.intToByteArray(header), 0, ret, 0, 4);
-                       System.arraycopy(BitConverter.intToByteArray(dataSize), 0, ret, 4, 4);
-                       
-                       return ret;
-               } else if (version == 2) {
-                       byte[] ret = new byte[12];
-                       System.arraycopy(BitConverter.intToByteArray(header), 0, ret, 0, 4);
-                       System.arraycopy(BitConverter.intToByteArray(dataSize), 0, ret, 4, 4);
-                       System.arraycopy(BitConverter.intToByteArray(messageID), 0, ret, 8, 4);
-                       
-                       return ret;
-               } else return null;
-       }
-       
-       public String toString() {
-               String ret = "";
-               ret += "version " + version + ", " + (compressed ? "compressed" : "uncompressed") + "\n";
-               ret += "frameType " + frameType + ", serviceType " + sessionType;
-               ret += "\nframeData " + frameData;
-               ret += ", sessionID " + sessionID;
-               ret += ", dataSize " + dataSize;
-               ret += ", messageID " + messageID;
-               return ret;
-       }
-       
-       public byte getVersion() {
-               return version;
-       }
-
-       public void setVersion(byte version) {
-               this.version = version;
-       }
-
-       public boolean isCompressed() {
-               return compressed;
-       }
-
-       public void setCompressed(boolean compressed) {
-               this.compressed = compressed;
-       }
-
-       public byte getFrameData() {
-               return frameData;
-       }
-
-       public void setFrameData(byte frameData) {
-               this.frameData = frameData;
-       }
-
-       public byte getSessionID() {
-               return sessionID;
-       }
-
-       public void setSessionID(byte sessionID) {
-               this.sessionID = sessionID;
-       }
-
-       public int getDataSize() {
-               return dataSize;
-       }
-
-       public void setDataSize(int dataSize) {
-               this.dataSize = dataSize;
-       }
-
-       public int getMessageID() {
-               return messageID;
-       }
-
-       public void setMessageID(int messageID) {
-               this.messageID = messageID;
-       }
-
-       public FrameType getFrameType() {
-               return frameType;
-       }
-
-       public void setFrameType(FrameType frameType) {
-               this.frameType = frameType;
-       }
-
-       public SessionType getSessionType() {
-               return sessionType;
-       }
-
-       public void setSessionType(SessionType sessionType) {
-               this.sessionType = sessionType;
-       }
-}
+package com.smartdevicelink.protocol;\r
+\r
+import com.smartdevicelink.protocol.enums.FrameType;\r
+import com.smartdevicelink.protocol.enums.SessionType;\r
+import com.smartdevicelink.util.BitConverter;\r
+\r
+public class ProtocolFrameHeader {\r
+       private byte version = 1;\r
+       private boolean compressed = false;\r
+       private FrameType frameType = FrameType.Control;\r
+       private SessionType sessionType = SessionType.RPC;\r
+       private byte frameData = 0;\r
+       private byte sessionID;\r
+       private int dataSize;\r
+       private int messageID;\r
+       \r
+       public static final byte FrameDataSingleFrame = 0x00;\r
+       public static final byte FrameDataFirstFrame = 0x00;\r
+       public static final byte FrameDataFinalConsecutiveFrame = 0x00;\r
+       \r
+       public ProtocolFrameHeader() {}\r
+       \r
+       public static ProtocolFrameHeader parseSmartDeviceLinkProHeader(byte[] header) {\r
+               ProtocolFrameHeader msg = new ProtocolFrameHeader();\r
+               \r
+               byte version = (byte) (header[0] >>> 4);\r
+               msg.setVersion(version);\r
+               \r
+               boolean compressed = 1 == ((header[0] & 0x08) >>> 3);\r
+               msg.setCompressed(compressed);\r
+               \r
+               byte frameType = (byte) (header[0] & 0x07);\r
+               msg.setFrameType(FrameType.valueOf(frameType));\r
+               \r
+               byte serviceType = header[1];\r
+               msg.setSessionType(SessionType.valueOf(serviceType));\r
+               \r
+               byte frameData = header[2];\r
+               msg.setFrameData(frameData);\r
+               \r
+               byte sessionID = header[3];\r
+               msg.setSessionID(sessionID);\r
+               \r
+               int dataSize = BitConverter.intFromByteArray(header, 4);\r
+               msg.setDataSize(dataSize);\r
+               \r
+               if (version == 2) {\r
+                       int messageID = BitConverter.intFromByteArray(header, 8);\r
+                       msg.setMessageID(messageID);\r
+               } else msg.setMessageID(0);\r
+               \r
+               return msg;\r
+       }\r
+       \r
+       protected byte[] assembleHeaderBytes() {\r
+               int header = 0;\r
+               header |= (version & 0x0F);\r
+               header <<= 1;\r
+               header |= (compressed ? 1 : 0);\r
+               header <<= 3;\r
+               header |= (frameType.value() & 0x07);\r
+               header <<= 8;\r
+               header |= (sessionType.value() & 0xFF);\r
+               header <<= 8;\r
+               header |= (frameData & 0xFF);\r
+               header <<= 8;\r
+               header |= (sessionID & 0xFF);\r
+               \r
+               if (version == 1) {\r
+                       byte[] ret = new byte[8];\r
+                       System.arraycopy(BitConverter.intToByteArray(header), 0, ret, 0, 4);\r
+                       System.arraycopy(BitConverter.intToByteArray(dataSize), 0, ret, 4, 4);\r
+                       \r
+                       return ret;\r
+               } else if (version == 2) {\r
+                       byte[] ret = new byte[12];\r
+                       System.arraycopy(BitConverter.intToByteArray(header), 0, ret, 0, 4);\r
+                       System.arraycopy(BitConverter.intToByteArray(dataSize), 0, ret, 4, 4);\r
+                       System.arraycopy(BitConverter.intToByteArray(messageID), 0, ret, 8, 4);\r
+                       \r
+                       return ret;\r
+               } else return null;\r
+       }\r
+       \r
+       public String toString() {\r
+               String ret = "";\r
+               ret += "version " + version + ", " + (compressed ? "compressed" : "uncompressed") + "\n";\r
+               ret += "frameType " + frameType + ", serviceType " + sessionType;\r
+               ret += "\nframeData " + frameData;\r
+               ret += ", sessionID " + sessionID;\r
+               ret += ", dataSize " + dataSize;\r
+               ret += ", messageID " + messageID;\r
+               return ret;\r
+       }\r
+       \r
+       public byte getVersion() {\r
+               return version;\r
+       }\r
+\r
+       public void setVersion(byte version) {\r
+               this.version = version;\r
+       }\r
+\r
+       public boolean isCompressed() {\r
+               return compressed;\r
+       }\r
+\r
+       public void setCompressed(boolean compressed) {\r
+               this.compressed = compressed;\r
+       }\r
+\r
+       public byte getFrameData() {\r
+               return frameData;\r
+       }\r
+\r
+       public void setFrameData(byte frameData) {\r
+               this.frameData = frameData;\r
+       }\r
+\r
+       public byte getSessionID() {\r
+               return sessionID;\r
+       }\r
+\r
+       public void setSessionID(byte sessionID) {\r
+               this.sessionID = sessionID;\r
+       }\r
+\r
+       public int getDataSize() {\r
+               return dataSize;\r
+       }\r
+\r
+       public void setDataSize(int dataSize) {\r
+               this.dataSize = dataSize;\r
+       }\r
+\r
+       public int getMessageID() {\r
+               return messageID;\r
+       }\r
+\r
+       public void setMessageID(int messageID) {\r
+               this.messageID = messageID;\r
+       }\r
+\r
+       public FrameType getFrameType() {\r
+               return frameType;\r
+       }\r
+\r
+       public void setFrameType(FrameType frameType) {\r
+               this.frameType = frameType;\r
+       }\r
+\r
+       public SessionType getSessionType() {\r
+               return sessionType;\r
+       }\r
+\r
+       public void setSessionType(SessionType sessionType) {\r
+               this.sessionType = sessionType;\r
+       }\r
+}\r
index d92b921..3a1e0d8 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.protocol;
-
-import com.smartdevicelink.protocol.enums.*;
-
-public class ProtocolFrameHeaderFactory {
-
-       public static ProtocolFrameHeader createStartSession(SessionType serviceType, int messageID, byte version) {
-               ProtocolFrameHeader msg = new ProtocolFrameHeader();
-               msg.setVersion(version);
-               msg.setFrameType(FrameType.Control);
-               msg.setSessionType(serviceType);
-               msg.setFrameData(FrameDataControlFrameType.StartSession.value());
-               msg.setMessageID(messageID);
-
-               return msg;
-       }
-
-       public static ProtocolFrameHeader createStartSessionACK(SessionType serviceType, byte sessionID, int messageID, byte version) {
-               ProtocolFrameHeader msg = new ProtocolFrameHeader();
-               msg.setVersion(version);
-               msg.setFrameType(FrameType.Control);
-               msg.setSessionType(serviceType);
-               msg.setSessionID(sessionID);
-               msg.setFrameData(FrameDataControlFrameType.StartSessionACK.value());
-               msg.setMessageID(messageID);
-
-               return msg;
-       }
-
-       public static ProtocolFrameHeader createStartSessionNACK(SessionType serviceType, byte sessionID, int messageID, byte version) {
-               ProtocolFrameHeader msg = new ProtocolFrameHeader();
-               msg.setVersion(version);
-               msg.setFrameType(FrameType.Control);
-               msg.setSessionType(serviceType);
-               msg.setSessionID(sessionID);
-               msg.setFrameData(FrameDataControlFrameType.StartSessionNACK.value());
-               msg.setMessageID(messageID);
-
-               return msg;
-       }
-
-       public static ProtocolFrameHeader createEndSession(SessionType serviceType, byte sessionID, int messageID, byte version) {
-               ProtocolFrameHeader msg = new ProtocolFrameHeader();
-               msg.setVersion(version);
-               msg.setFrameType(FrameType.Control);
-               msg.setSessionType(serviceType);
-               msg.setSessionID(sessionID);
-               msg.setFrameData(FrameDataControlFrameType.EndSession.value());
-               msg.setMessageID(messageID);
-
-               return msg;
-       }
-
-       public static ProtocolFrameHeader createSingleSendData(SessionType serviceType, byte sessionID,
-                       int dataLength, int messageID, byte version) {
-               ProtocolFrameHeader msg = new ProtocolFrameHeader();
-               msg.setVersion(version);
-               msg.setFrameType(FrameType.Single);
-               msg.setSessionType(serviceType);
-               msg.setFrameData(ProtocolFrameHeader.FrameDataSingleFrame);
-               msg.setSessionID(sessionID);
-               msg.setDataSize(dataLength);
-               msg.setMessageID(messageID);
-
-               return msg;
-       }
-
-       public static ProtocolFrameHeader createMultiSendDataFirst(SessionType serviceType, byte sessionID, 
-                       int messageID, byte version) {
-               ProtocolFrameHeader msg = new ProtocolFrameHeader();
-               msg.setVersion(version);
-               msg.setFrameType(FrameType.First);
-               msg.setSessionType(serviceType);
-               msg.setFrameData(ProtocolFrameHeader.FrameDataFirstFrame);
-               msg.setSessionID(sessionID);
-               msg.setDataSize(8);
-               msg.setMessageID(messageID);
-
-               return msg;
-       }
-
-       public static ProtocolFrameHeader createMultiSendDataRest(SessionType serviceType, byte sessionID,
-                       int dataLength, byte frameSequenceNumber, int messageID, byte version) {
-               ProtocolFrameHeader msg = new ProtocolFrameHeader();
-               msg.setVersion(version);
-               msg.setFrameType(FrameType.Consecutive);
-               msg.setSessionType(serviceType);
-               msg.setFrameData(frameSequenceNumber/*FrameData.ConsecutiveFrame.value()*/);
-               msg.setSessionID(sessionID);
-               msg.setDataSize(dataLength);
-               msg.setMessageID(messageID);
-
-               return msg;
-       }
-       
-       public static ProtocolFrameHeader createMultiSendDataRest(SessionType serviceType, byte sessionID,
-                       int dataLength, int messageID, byte version) {
-               ProtocolFrameHeader msg = new ProtocolFrameHeader();
-               msg.setVersion(version);
-               msg.setFrameType(FrameType.Consecutive);
-               msg.setSessionType(serviceType);
-               msg.setFrameData(FrameData.ConsecutiveFrame.value());
-               msg.setSessionID(sessionID);
-               msg.setDataSize(dataLength);
-               msg.setMessageID(messageID);
-
-               return msg;
-       }
-       
-       public static BinaryFrameHeader createBinaryFrameHeader(byte rpcType, int functionID, int corrID, int jsonSize) {
-               BinaryFrameHeader msg = new BinaryFrameHeader();
-               msg.setRPCType(rpcType);
-               msg.setFunctionID(functionID);
-               msg.setCorrID(corrID);
-               msg.setJsonSize(jsonSize);
-               
-               return msg;
-       }
-}
+package com.smartdevicelink.protocol;\r
+\r
+import com.smartdevicelink.protocol.enums.*;\r
+\r
+public class ProtocolFrameHeaderFactory {\r
+\r
+       public static ProtocolFrameHeader createStartSession(SessionType serviceType, int messageID, byte version) {\r
+               ProtocolFrameHeader msg = new ProtocolFrameHeader();\r
+               msg.setVersion(version);\r
+               msg.setFrameType(FrameType.Control);\r
+               msg.setSessionType(serviceType);\r
+               msg.setFrameData(FrameDataControlFrameType.StartSession.value());\r
+               msg.setMessageID(messageID);\r
+\r
+               return msg;\r
+       }\r
+\r
+       public static ProtocolFrameHeader createStartSessionACK(SessionType serviceType, byte sessionID, int messageID, byte version) {\r
+               ProtocolFrameHeader msg = new ProtocolFrameHeader();\r
+               msg.setVersion(version);\r
+               msg.setFrameType(FrameType.Control);\r
+               msg.setSessionType(serviceType);\r
+               msg.setSessionID(sessionID);\r
+               msg.setFrameData(FrameDataControlFrameType.StartSessionACK.value());\r
+               msg.setMessageID(messageID);\r
+\r
+               return msg;\r
+       }\r
+\r
+       public static ProtocolFrameHeader createStartSessionNACK(SessionType serviceType, byte sessionID, int messageID, byte version) {\r
+               ProtocolFrameHeader msg = new ProtocolFrameHeader();\r
+               msg.setVersion(version);\r
+               msg.setFrameType(FrameType.Control);\r
+               msg.setSessionType(serviceType);\r
+               msg.setSessionID(sessionID);\r
+               msg.setFrameData(FrameDataControlFrameType.StartSessionNACK.value());\r
+               msg.setMessageID(messageID);\r
+\r
+               return msg;\r
+       }\r
+\r
+       public static ProtocolFrameHeader createEndSession(SessionType serviceType, byte sessionID, int messageID, byte version) {\r
+               ProtocolFrameHeader msg = new ProtocolFrameHeader();\r
+               msg.setVersion(version);\r
+               msg.setFrameType(FrameType.Control);\r
+               msg.setSessionType(serviceType);\r
+               msg.setSessionID(sessionID);\r
+               msg.setFrameData(FrameDataControlFrameType.EndSession.value());\r
+               msg.setMessageID(messageID);\r
+\r
+               return msg;\r
+       }\r
+\r
+       public static ProtocolFrameHeader createSingleSendData(SessionType serviceType, byte sessionID,\r
+                       int dataLength, int messageID, byte version) {\r
+               ProtocolFrameHeader msg = new ProtocolFrameHeader();\r
+               msg.setVersion(version);\r
+               msg.setFrameType(FrameType.Single);\r
+               msg.setSessionType(serviceType);\r
+               msg.setFrameData(ProtocolFrameHeader.FrameDataSingleFrame);\r
+               msg.setSessionID(sessionID);\r
+               msg.setDataSize(dataLength);\r
+               msg.setMessageID(messageID);\r
+\r
+               return msg;\r
+       }\r
+\r
+       public static ProtocolFrameHeader createMultiSendDataFirst(SessionType serviceType, byte sessionID, \r
+                       int messageID, byte version) {\r
+               ProtocolFrameHeader msg = new ProtocolFrameHeader();\r
+               msg.setVersion(version);\r
+               msg.setFrameType(FrameType.First);\r
+               msg.setSessionType(serviceType);\r
+               msg.setFrameData(ProtocolFrameHeader.FrameDataFirstFrame);\r
+               msg.setSessionID(sessionID);\r
+               msg.setDataSize(8);\r
+               msg.setMessageID(messageID);\r
+\r
+               return msg;\r
+       }\r
+\r
+       public static ProtocolFrameHeader createMultiSendDataRest(SessionType serviceType, byte sessionID,\r
+                       int dataLength, byte frameSequenceNumber, int messageID, byte version) {\r
+               ProtocolFrameHeader msg = new ProtocolFrameHeader();\r
+               msg.setVersion(version);\r
+               msg.setFrameType(FrameType.Consecutive);\r
+               msg.setSessionType(serviceType);\r
+               msg.setFrameData(frameSequenceNumber/*FrameData.ConsecutiveFrame.value()*/);\r
+               msg.setSessionID(sessionID);\r
+               msg.setDataSize(dataLength);\r
+               msg.setMessageID(messageID);\r
+\r
+               return msg;\r
+       }\r
+       \r
+       public static ProtocolFrameHeader createMultiSendDataRest(SessionType serviceType, byte sessionID,\r
+                       int dataLength, int messageID, byte version) {\r
+               ProtocolFrameHeader msg = new ProtocolFrameHeader();\r
+               msg.setVersion(version);\r
+               msg.setFrameType(FrameType.Consecutive);\r
+               msg.setSessionType(serviceType);\r
+               msg.setFrameData(FrameData.ConsecutiveFrame.value());\r
+               msg.setSessionID(sessionID);\r
+               msg.setDataSize(dataLength);\r
+               msg.setMessageID(messageID);\r
+\r
+               return msg;\r
+       }\r
+       \r
+       public static BinaryFrameHeader createBinaryFrameHeader(byte rpcType, int functionID, int corrID, int jsonSize) {\r
+               BinaryFrameHeader msg = new BinaryFrameHeader();\r
+               msg.setRPCType(rpcType);\r
+               msg.setFunctionID(functionID);\r
+               msg.setCorrID(corrID);\r
+               msg.setJsonSize(jsonSize);\r
+               \r
+               return msg;\r
+       }\r
+}\r
index 06668f2..945c683 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.protocol;
-
-import com.smartdevicelink.protocol.enums.MessageType;
-import com.smartdevicelink.protocol.enums.SessionType;
-
-public class ProtocolMessage {
-       private byte version = 1;
-       private SessionType _sessionType = SessionType.RPC;
-       private MessageType _messageType = MessageType.UNDEFINED;
-       private byte _sessionID = 0;
-       private byte _rpcType;
-       private int _functionID;
-       private int _correlationID;
-       private int _jsonSize;
-       
-       private byte[] _data = null;
-       private byte[] _bulkData = null;
-       
-       public ProtocolMessage() {}
-
-       public byte getVersion() {
-               return version;
-       }
-
-       public void setVersion(byte version) {
-               this.version = version;
-       }
-
-       public byte getSessionID() {
-               return _sessionID;
-       }
-
-       public void setSessionID(byte sessionID) {
-               this._sessionID = sessionID;
-       }
-
-       public byte[] getData() {
-               return _data;
-       }
-
-       public void setData(byte[] data) {
-               this._data = data;
-               this._jsonSize = data.length;
-       }
-
-       public byte[] getBulkData() {
-               return _bulkData;
-       }
-
-       public void setBulkData(byte[] bulkData) {
-               if (this._bulkData != null)
-                       this._bulkData = null;
-               this._bulkData = new byte[bulkData.length];
-               System.arraycopy(bulkData, 0, this._bulkData, 0, bulkData.length);
-               //this._bulkData = bulkData;
-       }
-
-       public SessionType getSessionType() {
-               return _sessionType;
-       }
-
-       public void setSessionType(SessionType sessionType) {
-               this._sessionType = sessionType;
-       }
-
-       public MessageType getMessageType() {
-               return _messageType;
-       }
-
-       public void setMessageType(MessageType messageType) {
-               this._messageType = messageType;
-       }
-       
-       public byte getRPCType() {
-               return _rpcType;
-       }
-       
-       public void setRPCType(byte _rpcType) {
-               this._rpcType = _rpcType;
-       }
-       
-       public int getFunctionID() {
-               return _functionID;
-       }
-       
-       public void setFunctionID(int _functionID) {
-               this._functionID = _functionID;
-       }
-       
-       public int getCorrID() {
-               return _correlationID;
-       }
-       
-       public void setCorrID(int _correlationID) {
-               this._correlationID = _correlationID;
-       }
-
-       public int getJsonSize() {
-               return _jsonSize;
-       }
-
-       public void setJsonSize(int _jsonSize) {
-               this._jsonSize = _jsonSize;
-       }
-} // end-class
+package com.smartdevicelink.protocol;\r
+\r
+import com.smartdevicelink.protocol.enums.MessageType;\r
+import com.smartdevicelink.protocol.enums.SessionType;\r
+\r
+public class ProtocolMessage {\r
+       private byte version = 1;\r
+       private SessionType _sessionType = SessionType.RPC;\r
+       private MessageType _messageType = MessageType.UNDEFINED;\r
+       private byte _sessionID = 0;\r
+       private byte _rpcType;\r
+       private int _functionID;\r
+       private int _correlationID;\r
+       private int _jsonSize;\r
+       \r
+       private byte[] _data = null;\r
+       private byte[] _bulkData = null;\r
+       \r
+       public ProtocolMessage() {}\r
+\r
+       public byte getVersion() {\r
+               return version;\r
+       }\r
+\r
+       public void setVersion(byte version) {\r
+               this.version = version;\r
+       }\r
+\r
+       public byte getSessionID() {\r
+               return _sessionID;\r
+       }\r
+\r
+       public void setSessionID(byte sessionID) {\r
+               this._sessionID = sessionID;\r
+       }\r
+\r
+       public byte[] getData() {\r
+               return _data;\r
+       }\r
+\r
+       public void setData(byte[] data) {\r
+               this._data = data;\r
+               this._jsonSize = data.length;\r
+       }\r
+\r
+       public byte[] getBulkData() {\r
+               return _bulkData;\r
+       }\r
+\r
+       public void setBulkData(byte[] bulkData) {\r
+               if (this._bulkData != null)\r
+                       this._bulkData = null;\r
+               this._bulkData = new byte[bulkData.length];\r
+               System.arraycopy(bulkData, 0, this._bulkData, 0, bulkData.length);\r
+               //this._bulkData = bulkData;\r
+       }\r
+\r
+       public SessionType getSessionType() {\r
+               return _sessionType;\r
+       }\r
+\r
+       public void setSessionType(SessionType sessionType) {\r
+               this._sessionType = sessionType;\r
+       }\r
+\r
+       public MessageType getMessageType() {\r
+               return _messageType;\r
+       }\r
+\r
+       public void setMessageType(MessageType messageType) {\r
+               this._messageType = messageType;\r
+       }\r
+       \r
+       public byte getRPCType() {\r
+               return _rpcType;\r
+       }\r
+       \r
+       public void setRPCType(byte _rpcType) {\r
+               this._rpcType = _rpcType;\r
+       }\r
+       \r
+       public int getFunctionID() {\r
+               return _functionID;\r
+       }\r
+       \r
+       public void setFunctionID(int _functionID) {\r
+               this._functionID = _functionID;\r
+       }\r
+       \r
+       public int getCorrID() {\r
+               return _correlationID;\r
+       }\r
+       \r
+       public void setCorrID(int _correlationID) {\r
+               this._correlationID = _correlationID;\r
+       }\r
+\r
+       public int getJsonSize() {\r
+               return _jsonSize;\r
+       }\r
+\r
+       public void setJsonSize(int _jsonSize) {\r
+               this._jsonSize = _jsonSize;\r
+       }\r
+} // end-class
\ No newline at end of file
index d1d5f38..286debe 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.protocol;
-
-import java.io.ByteArrayOutputStream;
-import java.util.Hashtable;
-
-import com.smartdevicelink.protocol.enums.*;
-import com.smartdevicelink.util.BitConverter;
-import com.smartdevicelink.util.DebugTool;
-import com.smartdevicelink.exception.*;
-
-public class SmartDeviceLinkProtocol extends AbstractProtocol {
-       byte _version = 1;
-       private final static String FailurePropagating_Msg = "Failure propagating ";
-
-       public static final int MTU_SIZE = 1500;
-       public static int HEADER_SIZE = 8;
-       public static int MAX_DATA_SIZE = MTU_SIZE - HEADER_SIZE;
-
-       boolean _haveHeader = false;
-       byte[] _headerBuf = new byte[HEADER_SIZE];
-       int _headerBufWritePos = 0;
-       ProtocolFrameHeader _currentHeader = null;
-       byte[] _dataBuf = null;
-       int _dataBufWritePos = 0;
-       
-       int hashID = 0;
-       int messageID = 0;
-       
-       Hashtable<Integer, MessageFrameAssembler> _assemblerForMessageID = new Hashtable<Integer, MessageFrameAssembler>();
-       Hashtable<Byte, Hashtable<Integer, MessageFrameAssembler>> _assemblerForSessionID = new Hashtable<Byte, Hashtable<Integer, MessageFrameAssembler>>();
-       Hashtable<Byte, Object> _messageLocks = new Hashtable<Byte, Object>();
-
-       // Hide no-arg ctor
-       private SmartDeviceLinkProtocol() {
-               super(null);
-       } // end-ctor
-
-       public SmartDeviceLinkProtocol(IProtocolListener protocolListener) {
-               super(protocolListener);
-       } // end-ctor
-       
-       public byte getVersion() {
-               return this._version;
-       }
-       
-       public void setVersion(byte version) {
-               this._version = version;
-               if (version == 2) {
-                       HEADER_SIZE = 12;
-                       MAX_DATA_SIZE = MTU_SIZE - HEADER_SIZE;
-                       _headerBuf = new byte[HEADER_SIZE];
-               }
-       }
-
-       public void StartProtocolSession(SessionType sessionType) {
-               ProtocolFrameHeader header = ProtocolFrameHeaderFactory.createStartSession(sessionType, 0x00, _version);
-               sendFrameToTransport(header);
-       } // end-method
-
-       private void sendStartProtocolSessionACK(SessionType sessionType, byte sessionID) {
-               ProtocolFrameHeader header = ProtocolFrameHeaderFactory.createStartSessionACK(sessionType, sessionID, 0x00, _version);
-               sendFrameToTransport(header);
-       } // end-method
-
-       public void EndProtocolSession(SessionType sessionType, byte sessionID) {
-               ProtocolFrameHeader header = ProtocolFrameHeaderFactory.createEndSession(sessionType, sessionID, 0x00, _version);
-               sendFrameToTransport(header);
-       } // end-method
-
-       public void SendMessage(ProtocolMessage protocolMsg) {  
-               protocolMsg.setRPCType((byte) 0x00); //always sending a request
-               SessionType sessionType = protocolMsg.getSessionType();
-               byte sessionID = protocolMsg.getSessionID();
-               
-               byte[] data = null;
-               if (_version == 2) {
-                       if (protocolMsg.getBulkData() != null) {
-                               data = new byte[12 + protocolMsg.getJsonSize() + protocolMsg.getBulkData().length];
-                               sessionType = SessionType.Bulk_Data;
-                       } else data = new byte[12 + protocolMsg.getJsonSize()];
-                       BinaryFrameHeader binFrameHeader = new BinaryFrameHeader();
-                       binFrameHeader = ProtocolFrameHeaderFactory.createBinaryFrameHeader(protocolMsg.getRPCType(), protocolMsg.getFunctionID(), protocolMsg.getCorrID(), protocolMsg.getJsonSize());
-                       System.arraycopy(binFrameHeader.assembleHeaderBytes(), 0, data, 0, 12);
-                       System.arraycopy(protocolMsg.getData(), 0, data, 12, protocolMsg.getJsonSize());
-                       if (protocolMsg.getBulkData() != null) {
-                               System.arraycopy(protocolMsg.getBulkData(), 0, data, 12 + protocolMsg.getJsonSize(), protocolMsg.getBulkData().length);
-                       }
-               } else {
-                       data = protocolMsg.getData();
-               }
-               
-               // Get the message lock for this protocol session
-               Object messageLock = _messageLocks.get(sessionID);
-               if (messageLock == null) {
-                       handleProtocolError("Error sending protocol message to SmartDeviceLink.", 
-                                       new SmartDeviceLinkException("Attempt to send protocol message prior to startSession ACK.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE));
-                       return;
-               }
-               
-               synchronized(messageLock) {
-                       if (data.length > MAX_DATA_SIZE) {
-                               
-                               messageID++;
-                               ProtocolFrameHeader firstHeader = ProtocolFrameHeaderFactory.createMultiSendDataFirst(sessionType, sessionID, messageID, _version);
-       
-                               // Assemble first frame.
-                               int frameCount = data.length / MAX_DATA_SIZE;
-                               if (data.length % MAX_DATA_SIZE > 0) {
-                                       frameCount++;
-                               }
-                               byte[] firstFrameData = new byte[8];
-                               // First four bytes are data size.
-                               System.arraycopy(BitConverter.intToByteArray(data.length), 0, firstFrameData, 0, 4);
-                               // Second four bytes are frame count.
-                               System.arraycopy(BitConverter.intToByteArray(frameCount), 0, firstFrameData, 4, 4);
-                               
-                               handleProtocolFrameToSend(firstHeader, firstFrameData, 0, firstFrameData.length);
-                               
-                               int currentOffset = 0;
-                               byte frameSequenceNumber = 0;
-                               
-                               for (int i = 0; i < frameCount; i++) {
-                                       if (i < (frameCount - 1)) {
-                                               frameSequenceNumber = (byte)(i + 1);
-                                       } else {
-                                               frameSequenceNumber = ProtocolFrameHeader.FrameDataFinalConsecutiveFrame;
-                                       } // end-if
-                                       
-                                       int bytesToWrite = data.length - currentOffset;
-                                       if (bytesToWrite > MAX_DATA_SIZE) { 
-                                               bytesToWrite = MAX_DATA_SIZE; 
-                                       }
-
-                                       ProtocolFrameHeader consecHeader = ProtocolFrameHeaderFactory.createMultiSendDataRest(sessionType, sessionID, bytesToWrite, frameSequenceNumber , messageID, _version);
-                                       handleProtocolFrameToSend(consecHeader, data, currentOffset, bytesToWrite);
-                                       currentOffset += bytesToWrite;
-                               }
-                       } else {
-                               messageID++;
-                               ProtocolFrameHeader header = ProtocolFrameHeaderFactory.createSingleSendData(sessionType, sessionID, data.length, messageID, _version);
-                               handleProtocolFrameToSend(header, data, 0, data.length);
-                       }
-               }
-       }
-
-       private void sendFrameToTransport(ProtocolFrameHeader header) {
-               handleProtocolFrameToSend(header, null, 0, 0);
-       }
-
-       public void HandleReceivedBytes(byte[] receivedBytes, int receivedBytesLength) {
-               int receivedBytesReadPos = 0;
-               
-               //Check for a version difference
-               if (_version == 1) {
-                       //Nothing has been read into the buffer and version is 2
-                       if (_headerBufWritePos == 0 && (byte) (receivedBytes[0] >>> 4) == 2) {
-                               setVersion((byte) (receivedBytes[0] >>> 4));
-                       //Buffer has something in it and version is 2
-                       } else if ((byte) (_headerBuf[0] >>> 4) == 2) {
-                               //safe current state of the buffer and also set the new version
-                               byte[] tempHeader = new byte[_headerBufWritePos];
-                               tempHeader = _headerBuf;
-                               setVersion((byte) (_headerBuf[0] >>> 4));
-                               _headerBuf = tempHeader;
-                       }
-               }
-               
-               // If I don't yet know the message size, grab those bytes.
-               if (!_haveHeader) {
-                       // If I can't get the size, just get the bytes that are there.
-                       int headerBytesNeeded = _headerBuf.length - _headerBufWritePos;
-                       if (receivedBytesLength < headerBytesNeeded) {
-                               System.arraycopy(receivedBytes, receivedBytesReadPos,
-                                               _headerBuf, _headerBufWritePos, receivedBytesLength);
-                               _headerBufWritePos += receivedBytesLength;
-                               return;
-                       } else {
-                       // If I got the size, allocate the buffer
-                               System.arraycopy(receivedBytes, receivedBytesReadPos,
-                                               _headerBuf, _headerBufWritePos, headerBytesNeeded);
-                               _headerBufWritePos += headerBytesNeeded;
-                               receivedBytesReadPos += headerBytesNeeded;
-                               _haveHeader = true;
-                               _currentHeader  = ProtocolFrameHeader.parseWiProHeader(_headerBuf);
-                               _dataBuf = new byte[_currentHeader.getDataSize()];
-                               _dataBufWritePos = 0;
-                       }
-               }
-
-               int bytesLeft = receivedBytesLength - receivedBytesReadPos;
-               int bytesNeeded = _dataBuf.length - _dataBufWritePos;
-               // If I don't have enough bytes for the message, just grab what's there.
-               if (bytesLeft < bytesNeeded) {
-                       System.arraycopy(receivedBytes, receivedBytesReadPos, _dataBuf,
-                                       _dataBufWritePos, bytesLeft);
-                       _dataBufWritePos += bytesLeft;
-                       return;
-               } else {
-               // Fill the buffer and call the handler!
-                       System.arraycopy(receivedBytes, receivedBytesReadPos, _dataBuf, _dataBufWritePos, bytesNeeded);
-                       receivedBytesReadPos += bytesNeeded;
-
-                       MessageFrameAssembler assembler = getFrameAssemblerForFrame(_currentHeader);
-                       handleProtocolFrameReceived(_currentHeader, _dataBuf, assembler);
-
-                       // Reset all class member variables for next frame
-                       _dataBuf = null;
-                       _dataBufWritePos = 0;
-                       _haveHeader = false;
-                       _headerBuf = new byte[HEADER_SIZE];
-                       _currentHeader = null;
-                       _headerBufWritePos = 0;
-                       
-                       // If there are any bytes left, recurse.
-                       int moreBytesLeft = receivedBytesLength - receivedBytesReadPos;
-                       if (moreBytesLeft > 0) {
-                               byte[] moreBytes = new byte[moreBytesLeft];
-                               System.arraycopy(receivedBytes, receivedBytesReadPos,
-                                               moreBytes, 0, moreBytesLeft);
-                               HandleReceivedBytes(moreBytes, moreBytesLeft);
-                       }
-               }
-       }
-       
-       protected MessageFrameAssembler getFrameAssemblerForFrame(ProtocolFrameHeader header) {
-               Hashtable<Integer, MessageFrameAssembler> hashSessionID = _assemblerForSessionID.get(new Byte(header.getSessionID()));
-               if (hashSessionID == null) {
-                       hashSessionID = new Hashtable<Integer, MessageFrameAssembler>();
-                       _assemblerForSessionID.put(new Byte(header.getSessionID()), hashSessionID);
-               } // end-if
-               
-               MessageFrameAssembler ret = (MessageFrameAssembler) _assemblerForMessageID.get(new Integer(header.getMessageID()));
-               if (ret == null) {
-                       ret = new MessageFrameAssembler();
-                       _assemblerForMessageID.put(new Integer(header.getMessageID()), ret);
-               } // end-if
-               
-               return ret;
-       } // end-method
-
-       protected class MessageFrameAssembler {
-               protected boolean hasFirstFrame = false;
-               protected boolean hasSecondFrame = false;
-               protected ByteArrayOutputStream accumulator = null;
-               protected int totalSize = 0;
-               protected int framesRemaining = 0;
-
-               protected void handleFirstDataFrame(ProtocolFrameHeader header, byte[] data) {
-                       //The message is new, so let's figure out how big it is.
-                       hasFirstFrame = true;
-                       totalSize = BitConverter.intFromByteArray(data, 0) - HEADER_SIZE;
-                       framesRemaining = BitConverter.intFromByteArray(data, 4);
-                       accumulator = new ByteArrayOutputStream(totalSize);
-               }
-               
-               protected void handleSecondFrame(ProtocolFrameHeader header, byte[] data) {
-                       handleRemainingFrame(header, data);
-               }
-               
-               protected void handleRemainingFrame(ProtocolFrameHeader header, byte[] data) {
-                       accumulator.write(data, 0, header.getDataSize());
-                       notifyIfFinished(header);
-               }
-               
-               protected void notifyIfFinished(ProtocolFrameHeader header) {
-                       //if (framesRemaining == 0) {
-                       if (header.getFrameType() == FrameType.Consecutive && header.getFrameData() == 0x0) 
-                       {
-                               ProtocolMessage message = new ProtocolMessage();
-                               message.setSessionType(header.getSessionType());
-                               message.setSessionID(header.getSessionID());
-                               //If it is WiPro 2.0 it must have binary header
-                               if (_version == 2) {
-                                       BinaryFrameHeader binFrameHeader = BinaryFrameHeader.
-                                                       parseBinaryHeader(accumulator.toByteArray());
-                                       message.setVersion(_version);
-                                       message.setRPCType(binFrameHeader.getRPCType());
-                                       message.setFunctionID(binFrameHeader.getFunctionID());
-                                       message.setCorrID(binFrameHeader.getCorrID());
-                                       if (binFrameHeader.getJsonSize() > 0) message.setData(binFrameHeader.getJsonData());
-                                       if (binFrameHeader.getBulkData() != null) message.setBulkData(binFrameHeader.getBulkData());
-                               } else message.setData(accumulator.toByteArray());
-                               
-                               _assemblerForMessageID.remove(header.getMessageID());
-                               
-                               try {
-                                       handleProtocolMessageReceived(message);
-                               } catch (Exception excp) {
-                                       DebugTool.logError(FailurePropagating_Msg + "onProtocolMessageReceived: " + excp.toString(), excp);
-                               } // end-catch
-                               
-                               hasFirstFrame = false;
-                               hasSecondFrame = false;
-                               accumulator = null;
-                       } // end-if
-               } // end-method
-               
-               protected void handleMultiFrameMessageFrame(ProtocolFrameHeader header, byte[] data) {
-                       if (header.getFrameType() == FrameType.First) {
-                               handleFirstDataFrame(header, data);
-                       } else {
-                               handleRemainingFrame(header, data);
-                       }
-                               
-                       //}
-               } // end-method
-               
-               protected void handleFrame(ProtocolFrameHeader header, byte[] data) {
-                       if (header.getFrameType().equals(FrameType.Control)) {
-                               handleControlFrame(header, data);
-                       } else {
-                               // Must be a form of data frame (single, first, consecutive, etc.)
-                               if (   header.getFrameType() == FrameType.First
-                                       || header.getFrameType() == FrameType.Consecutive
-                                       ) {
-                                       handleMultiFrameMessageFrame(header, data);
-                               } else {
-                                       handleSingleFrameMessageFrame(header, data);
-                               }
-                       } // end-if
-               } // end-method
-               
-               private void handleProtocolHeartbeat(ProtocolFrameHeader header, byte[] data) {
-               } // end-method
-               
-               private void handleControlFrame(ProtocolFrameHeader header, byte[] data) {
-                       if (header.getFrameData() == FrameDataControlFrameType.StartSession.getValue()) {
-                               sendStartProtocolSessionACK(header.getSessionType(), header.getSessionID());
-                       } else if (header.getFrameData() == FrameDataControlFrameType.StartSessionACK.getValue()) {
-                               // Use this sessionID to create a message lock
-                               Object messageLock = _messageLocks.get(header.getSessionID());
-                               if (messageLock == null) {
-                                       messageLock = new Object();
-                                       _messageLocks.put(header.getSessionID(), messageLock);
-                               }
-                               handleProtocolSessionStarted(header.getSessionType(), header.getSessionID(), _version, "");                             
-                       } else if (header.getFrameData() == FrameDataControlFrameType.StartSessionNACK.getValue()) {
-                               handleProtocolError("Got StartSessionNACK for protocol sessionID=" + header.getSessionID(), null);
-                       } else if (header.getFrameData() == FrameDataControlFrameType.EndSession.getValue()) {
-                               handleProtocolSessionEnded(header.getSessionType(), header.getSessionID(), "");
-                       }
-               } // end-method
-                               
-               private void handleSingleFrameMessageFrame(ProtocolFrameHeader header, byte[] data) {
-                       ProtocolMessage message = new ProtocolMessage();
-                       if (header.getSessionType() == SessionType.RPC) {
-                               message.setMessageType(MessageType.RPC);
-                       } else if (header.getSessionType() == SessionType.Bulk_Data) {
-                               message.setMessageType(MessageType.BULK);
-                       } // end-if
-                       message.setSessionType(header.getSessionType());
-                       message.setSessionID(header.getSessionID());
-                       
-                       if (_version == 2) {
-                               BinaryFrameHeader binFrameHeader = BinaryFrameHeader.
-                                               parseBinaryHeader(data);
-                               message.setVersion(_version);
-                               message.setRPCType(binFrameHeader.getRPCType());
-                               message.setFunctionID(binFrameHeader.getFunctionID());
-                               message.setCorrID(binFrameHeader.getCorrID());
-                               if (binFrameHeader.getJsonSize() > 0) message.setData(binFrameHeader.getJsonData());
-                               if (binFrameHeader.getBulkData() != null) message.setBulkData(binFrameHeader.getBulkData());
-                       } else message.setData(data);
-                       
-                       _assemblerForMessageID.remove(header.getMessageID());
-                       
-                       try {
-                               handleProtocolMessageReceived(message);
-                       } catch (Exception ex) {
-                               DebugTool.logError(FailurePropagating_Msg + "onProtocolMessageReceived: " + ex.toString(), ex);
-                               handleProtocolError(FailurePropagating_Msg + "onProtocolMessageReceived: ", ex);
-                       } // end-catch
-               } // end-method
-       } // end-class
-} // end-class
+package com.smartdevicelink.protocol;\r
+\r
+import java.io.ByteArrayOutputStream;\r
+import java.util.Hashtable;\r
+\r
+import android.util.Log;\r
+\r
+import com.smartdevicelink.exception.*;\r
+import com.smartdevicelink.protocol.enums.*;\r
+import com.smartdevicelink.util.BitConverter;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+public class SmartDeviceLinkProtocol extends AbstractProtocol {\r
+       byte _version = 1;\r
+       private final static String FailurePropagating_Msg = "Failure propagating ";\r
+\r
+       private static final int MTU_SIZE = 1500;\r
+       private static int HEADER_SIZE = 8;\r
+       private static int MAX_DATA_SIZE = MTU_SIZE - HEADER_SIZE;\r
+\r
+       boolean _haveHeader = false;\r
+       byte[] _headerBuf = new byte[HEADER_SIZE];\r
+       int _headerBufWritePos = 0;\r
+       ProtocolFrameHeader _currentHeader = null;\r
+       byte[] _dataBuf = null;\r
+       int _dataBufWritePos = 0;\r
+       \r
+       int hashID = 0;\r
+       int messageID = 0;\r
+       \r
+       Hashtable<Integer, MessageFrameAssembler> _assemblerForMessageID = new Hashtable<Integer, MessageFrameAssembler>();\r
+       Hashtable<Byte, Hashtable<Integer, MessageFrameAssembler>> _assemblerForSessionID = new Hashtable<Byte, Hashtable<Integer, MessageFrameAssembler>>();\r
+       Hashtable<Byte, Object> _messageLocks = new Hashtable<Byte, Object>();\r
+\r
+       // Hide no-arg ctor\r
+       private SmartDeviceLinkProtocol() {\r
+               super(null);\r
+       } // end-ctor\r
+\r
+       public SmartDeviceLinkProtocol(IProtocolListener protocolListener) {\r
+               super(protocolListener);\r
+       } // end-ctor\r
+       \r
+       public byte getVersion() {\r
+               return this._version;\r
+       }\r
+       \r
+       public void setVersion(byte version) {\r
+               this._version = version;\r
+               if (version == 2) {\r
+                       HEADER_SIZE = 12;\r
+                       MAX_DATA_SIZE = MTU_SIZE - HEADER_SIZE;\r
+                       _headerBuf = new byte[HEADER_SIZE];\r
+               }\r
+       }\r
+\r
+       public void StartProtocolSession(SessionType sessionType) {\r
+               ProtocolFrameHeader header = ProtocolFrameHeaderFactory.createStartSession(sessionType, 0x00, _version);\r
+               sendFrameToTransport(header);\r
+       } // end-method\r
+\r
+       private void sendStartProtocolSessionACK(SessionType sessionType, byte sessionID) {\r
+               ProtocolFrameHeader header = ProtocolFrameHeaderFactory.createStartSessionACK(sessionType, sessionID, 0x00, _version);\r
+               sendFrameToTransport(header);\r
+       } // end-method\r
+       \r
+       public void EndProtocolSession(SessionType sessionType, byte sessionID) {\r
+               ProtocolFrameHeader header = ProtocolFrameHeaderFactory.createEndSession(sessionType, sessionID, hashID, _version);\r
+               //byte[] data = new byte[4];\r
+               //data = BitConverter.intToByteArray(hashID);\r
+               //handleProtocolFrameToSend(header, data, 0, data.length);\r
+               sendFrameToTransport(header);\r
+       } // end-method\r
+\r
+       public void SendMessage(ProtocolMessage protocolMsg) {  \r
+               protocolMsg.setRPCType((byte) 0x00); //always sending a request\r
+               SessionType sessionType = protocolMsg.getSessionType();\r
+               byte sessionID = protocolMsg.getSessionID();\r
+               \r
+               byte[] data = null;\r
+               if (_version == 2) {\r
+                       if (protocolMsg.getBulkData() != null) {\r
+                               data = new byte[12 + protocolMsg.getJsonSize() + protocolMsg.getBulkData().length];\r
+                               sessionType = SessionType.Bulk_Data;\r
+                       } else data = new byte[12 + protocolMsg.getJsonSize()];\r
+                       BinaryFrameHeader binFrameHeader = new BinaryFrameHeader();\r
+                       binFrameHeader = ProtocolFrameHeaderFactory.createBinaryFrameHeader(protocolMsg.getRPCType(), protocolMsg.getFunctionID(), protocolMsg.getCorrID(), protocolMsg.getJsonSize());\r
+                       System.arraycopy(binFrameHeader.assembleHeaderBytes(), 0, data, 0, 12);\r
+                       System.arraycopy(protocolMsg.getData(), 0, data, 12, protocolMsg.getJsonSize());\r
+                       if (protocolMsg.getBulkData() != null) {\r
+                               System.arraycopy(protocolMsg.getBulkData(), 0, data, 12 + protocolMsg.getJsonSize(), protocolMsg.getBulkData().length);\r
+                       }\r
+               } else {\r
+                       data = protocolMsg.getData();\r
+               }\r
+               \r
+               // Get the message lock for this protocol session\r
+               Object messageLock = _messageLocks.get(sessionID);\r
+               if (messageLock == null) {\r
+                       handleProtocolError("Error sending protocol message to SMARTDEVICELINK.", \r
+                                       new SmartDeviceLinkException("Attempt to send protocol message prior to startSession ACK.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE));\r
+                       return;\r
+               }\r
+               \r
+               synchronized(messageLock) {\r
+                       if (data.length > MAX_DATA_SIZE) {\r
+                               \r
+                               messageID++;\r
+                               ProtocolFrameHeader firstHeader = ProtocolFrameHeaderFactory.createMultiSendDataFirst(sessionType, sessionID, messageID, _version);\r
+       \r
+                               // Assemble first frame.\r
+                               int frameCount = data.length / MAX_DATA_SIZE;\r
+                               if (data.length % MAX_DATA_SIZE > 0) {\r
+                                       frameCount++;\r
+                               }\r
+                               //byte[] firstFrameData = new byte[HEADER_SIZE];\r
+                               byte[] firstFrameData = new byte[8];\r
+                               // First four bytes are data size.\r
+                               System.arraycopy(BitConverter.intToByteArray(data.length), 0, firstFrameData, 0, 4);\r
+                               // Second four bytes are frame count.\r
+                               System.arraycopy(BitConverter.intToByteArray(frameCount), 0, firstFrameData, 4, 4);\r
+                               \r
+                               handleProtocolFrameToSend(firstHeader, firstFrameData, 0, firstFrameData.length);\r
+                               \r
+                               int currentOffset = 0;\r
+                               byte frameSequenceNumber = 0;\r
+                               \r
+                               for (int i = 0; i < frameCount; i++) {\r
+                                       if (i < (frameCount - 1)) {\r
+                                               frameSequenceNumber = (byte)(i + 1);\r
+                                       } else {\r
+                                               frameSequenceNumber = ProtocolFrameHeader.FrameDataFinalConsecutiveFrame;\r
+                                       } // end-if\r
+                                       \r
+                                       int bytesToWrite = data.length - currentOffset;\r
+                                       if (bytesToWrite > MAX_DATA_SIZE) { \r
+                                               bytesToWrite = MAX_DATA_SIZE; \r
+                                       }\r
+\r
+                                       ProtocolFrameHeader consecHeader = ProtocolFrameHeaderFactory.createMultiSendDataRest(sessionType, sessionID, bytesToWrite, frameSequenceNumber , messageID, _version);\r
+                                       handleProtocolFrameToSend(consecHeader, data, currentOffset, bytesToWrite);\r
+                                       currentOffset += bytesToWrite;\r
+                               }\r
+                       } else {\r
+                               messageID++;\r
+                               ProtocolFrameHeader header = ProtocolFrameHeaderFactory.createSingleSendData(sessionType, sessionID, data.length, messageID, _version);\r
+                               handleProtocolFrameToSend(header, data, 0, data.length);\r
+                       }\r
+               }\r
+       }\r
+\r
+       private void sendFrameToTransport(ProtocolFrameHeader header) {\r
+               handleProtocolFrameToSend(header, null, 0, 0);\r
+       }\r
+\r
+       public void HandleReceivedBytes(byte[] receivedBytes, int receivedBytesLength) {\r
+               int receivedBytesReadPos = 0;\r
+               \r
+               //Check for a version difference\r
+               if (_version == 1) {\r
+                       //Nothing has been read into the buffer and version is 2\r
+                       if (_headerBufWritePos == 0 && (byte) (receivedBytes[0] >>> 4) == 2) {\r
+                               setVersion((byte) (receivedBytes[0] >>> 4));\r
+                       //Buffer has something in it and version is 2\r
+                       } else if ((byte) (_headerBuf[0] >>> 4) == 2) {\r
+                               //safe current state of the buffer and also set the new version\r
+                               byte[] tempHeader = new byte[_headerBufWritePos];\r
+                               tempHeader = _headerBuf;\r
+                               setVersion((byte) (_headerBuf[0] >>> 4));\r
+                               _headerBuf = tempHeader;\r
+                       }\r
+               }\r
+               \r
+               // If I don't yet know the message size, grab those bytes.\r
+               if (!_haveHeader) {\r
+                       // If I can't get the size, just get the bytes that are there.\r
+                       int headerBytesNeeded = _headerBuf.length - _headerBufWritePos;\r
+                       if (receivedBytesLength < headerBytesNeeded) {\r
+                               System.arraycopy(receivedBytes, receivedBytesReadPos,\r
+                                               _headerBuf, _headerBufWritePos, receivedBytesLength);\r
+                               _headerBufWritePos += receivedBytesLength;\r
+                               return;\r
+                       } else {\r
+                       // If I got the size, allocate the buffer\r
+                               System.arraycopy(receivedBytes, receivedBytesReadPos,\r
+                                               _headerBuf, _headerBufWritePos, headerBytesNeeded);\r
+                               _headerBufWritePos += headerBytesNeeded;\r
+                               receivedBytesReadPos += headerBytesNeeded;\r
+                               _haveHeader = true;\r
+                               _currentHeader  = ProtocolFrameHeader.parseSmartDeviceLinkProHeader(_headerBuf);\r
+                               \r
+                               \r
+                               int iDataSize = _currentHeader.getDataSize();   \r
+\r
+                               if (iDataSize <= 4000)\r
+                               {\r
+                                       _dataBuf = new byte[iDataSize];\r
+                               }\r
+                               else\r
+                               {\r
+                                       //something is wrong with the header\r
+                                       Log.e("HandleReceivedBytes", "Corrupt header found, request to allocate a byte array of size: " + iDataSize);   \r
+                                       Log.e("HandleReceivedBytes", "_headerBuf: " + _headerBuf.toString());\r
+                                       Log.e("HandleReceivedBytes", "_currentHeader: " + _currentHeader.toString());\r
+                                       Log.e("HandleReceivedBytes", "receivedBytes: " + receivedBytes.toString());\r
+                                       Log.e("HandleReceivedBytes", "receivedBytesReadPos: " + receivedBytesReadPos);\r
+                                       Log.e("HandleReceivedBytes", "_headerBufWritePos: " + _headerBufWritePos);\r
+                                       Log.e("HandleReceivedBytes", "headerBytesNeeded: " + headerBytesNeeded);\r
+                                       handleProtocolError("Error handling protocol message from SMARTDEVICELINK, header invalid.", \r
+                                                       new SmartDeviceLinkException("Error handling protocol message from SMARTDEVICELINK, header invalid.", SmartDeviceLinkExceptionCause.INVALID_HEADER));\r
+                                       return;                                 \r
+                               }\r
+                               _dataBufWritePos = 0;\r
+                       }\r
+               }\r
+\r
+               int bytesLeft = receivedBytesLength - receivedBytesReadPos;\r
+               int bytesNeeded = _dataBuf.length - _dataBufWritePos;\r
+               // If I don't have enough bytes for the message, just grab what's there.\r
+               if (bytesLeft < bytesNeeded) {\r
+                       System.arraycopy(receivedBytes, receivedBytesReadPos, _dataBuf,\r
+                                       _dataBufWritePos, bytesLeft);\r
+                       _dataBufWritePos += bytesLeft;\r
+                       return;\r
+               } else {\r
+               // Fill the buffer and call the handler!\r
+                       System.arraycopy(receivedBytes, receivedBytesReadPos, _dataBuf, _dataBufWritePos, bytesNeeded);\r
+                       receivedBytesReadPos += bytesNeeded;\r
+\r
+                       MessageFrameAssembler assembler = getFrameAssemblerForFrame(_currentHeader);\r
+                       handleProtocolFrameReceived(_currentHeader, _dataBuf, assembler);\r
+\r
+                       // Reset all class member variables for next frame\r
+                       _dataBuf = null;\r
+                       _dataBufWritePos = 0;\r
+                       _haveHeader = false;\r
+                       _headerBuf = new byte[HEADER_SIZE];\r
+                       _currentHeader = null;\r
+                       _headerBufWritePos = 0;\r
+                       \r
+                       // If there are any bytes left, recurse.\r
+                       int moreBytesLeft = receivedBytesLength - receivedBytesReadPos;\r
+                       if (moreBytesLeft > 0) {\r
+                               byte[] moreBytes = new byte[moreBytesLeft];\r
+                               System.arraycopy(receivedBytes, receivedBytesReadPos,\r
+                                               moreBytes, 0, moreBytesLeft);\r
+                               HandleReceivedBytes(moreBytes, moreBytesLeft);\r
+                       }\r
+               }\r
+       }\r
+       \r
+       protected MessageFrameAssembler getFrameAssemblerForFrame(ProtocolFrameHeader header) {\r
+               Hashtable<Integer, MessageFrameAssembler> hashSessionID = _assemblerForSessionID.get(new Byte(header.getSessionID()));\r
+               if (hashSessionID == null) {\r
+                       hashSessionID = new Hashtable<Integer, MessageFrameAssembler>();\r
+                       _assemblerForSessionID.put(new Byte(header.getSessionID()), hashSessionID);\r
+               } // end-if\r
+               \r
+               MessageFrameAssembler ret = (MessageFrameAssembler) _assemblerForMessageID.get(new Integer(header.getMessageID()));\r
+               if (ret == null) {\r
+                       ret = new MessageFrameAssembler();\r
+                       _assemblerForMessageID.put(new Integer(header.getMessageID()), ret);\r
+               } // end-if\r
+               \r
+               return ret;\r
+       } // end-method\r
+\r
+       protected class MessageFrameAssembler {\r
+               protected boolean hasFirstFrame = false;\r
+               protected boolean hasSecondFrame = false;\r
+               protected ByteArrayOutputStream accumulator = null;\r
+               protected int totalSize = 0;\r
+               protected int framesRemaining = 0;\r
+\r
+               protected void handleFirstDataFrame(ProtocolFrameHeader header, byte[] data) {\r
+                       //The message is new, so let's figure out how big it is.\r
+                       hasFirstFrame = true;\r
+                       totalSize = BitConverter.intFromByteArray(data, 0) - HEADER_SIZE;\r
+                       framesRemaining = BitConverter.intFromByteArray(data, 4);\r
+                       accumulator = new ByteArrayOutputStream(totalSize);\r
+               }\r
+               \r
+               protected void handleSecondFrame(ProtocolFrameHeader header, byte[] data) {\r
+                       handleRemainingFrame(header, data);\r
+               }\r
+               \r
+               protected void handleRemainingFrame(ProtocolFrameHeader header, byte[] data) {\r
+                       accumulator.write(data, 0, header.getDataSize());\r
+                       notifyIfFinished(header);\r
+               }\r
+               \r
+               protected void notifyIfFinished(ProtocolFrameHeader header) {\r
+                       //if (framesRemaining == 0) {\r
+                       if (header.getFrameType() == FrameType.Consecutive && header.getFrameData() == 0x0) \r
+                       {\r
+                               ProtocolMessage message = new ProtocolMessage();\r
+                               message.setSessionType(header.getSessionType());\r
+                               message.setSessionID(header.getSessionID());\r
+                               //If it is SmartDeviceLinkPro 2.0 it must have binary header\r
+                               if (_version == 2) {\r
+                                       BinaryFrameHeader binFrameHeader = BinaryFrameHeader.\r
+                                                       parseBinaryHeader(accumulator.toByteArray());\r
+                                       message.setVersion(_version);\r
+                                       message.setRPCType(binFrameHeader.getRPCType());\r
+                                       message.setFunctionID(binFrameHeader.getFunctionID());\r
+                                       message.setCorrID(binFrameHeader.getCorrID());\r
+                                       if (binFrameHeader.getJsonSize() > 0) message.setData(binFrameHeader.getJsonData());\r
+                                       if (binFrameHeader.getBulkData() != null) message.setBulkData(binFrameHeader.getBulkData());\r
+                               } else message.setData(accumulator.toByteArray());\r
+                               \r
+                               _assemblerForMessageID.remove(header.getMessageID());\r
+                               \r
+                               try {\r
+                                       handleProtocolMessageReceived(message);\r
+                               } catch (Exception excp) {\r
+                                       DebugTool.logError(FailurePropagating_Msg + "onProtocolMessageReceived: " + excp.toString(), excp);\r
+                               } // end-catch\r
+                               \r
+                               hasFirstFrame = false;\r
+                               hasSecondFrame = false;\r
+                               accumulator = null;\r
+                       } // end-if\r
+               } // end-method\r
+               \r
+               protected void handleMultiFrameMessageFrame(ProtocolFrameHeader header, byte[] data) {\r
+                       //if (!hasFirstFrame) {\r
+                       //      hasFirstFrame = true;\r
+                       if (header.getFrameType() == FrameType.First)\r
+                       {\r
+                               handleFirstDataFrame(header, data);\r
+                       }\r
+                               \r
+                       //} else if (!hasSecondFrame) {\r
+                       //      hasSecondFrame = true;\r
+                       //      framesRemaining--;\r
+                       //      handleSecondFrame(header, data);\r
+                       //} else {\r
+                       //      framesRemaining--;\r
+                       else\r
+                       {\r
+                               handleRemainingFrame(header, data);\r
+                       }\r
+                               \r
+                       //}\r
+               } // end-method\r
+               \r
+               protected void handleFrame(ProtocolFrameHeader header, byte[] data) {\r
+                       if (header.getFrameType().equals(FrameType.Control)) {\r
+                               handleControlFrame(header, data);\r
+                       } else {\r
+                               // Must be a form of data frame (single, first, consecutive, etc.)\r
+                               if (   header.getFrameType() == FrameType.First\r
+                                       || header.getFrameType() == FrameType.Consecutive\r
+                                       ) {\r
+                                       handleMultiFrameMessageFrame(header, data);\r
+                               } else {\r
+                                       handleSingleFrameMessageFrame(header, data);\r
+                               }\r
+                       } // end-if\r
+               } // end-method\r
+               \r
+               \r
+               private void handleControlFrame(ProtocolFrameHeader header, byte[] data) {\r
+                       if (header.getFrameData() == FrameDataControlFrameType.StartSession.getValue()) {\r
+                               sendStartProtocolSessionACK(header.getSessionType(), header.getSessionID());\r
+                       } else if (header.getFrameData() == FrameDataControlFrameType.StartSessionACK.getValue()) {\r
+                               // Use this sessionID to create a message lock\r
+                               Object messageLock = _messageLocks.get(header.getSessionID());\r
+                               if (messageLock == null) {\r
+                                       messageLock = new Object();\r
+                                       _messageLocks.put(header.getSessionID(), messageLock);\r
+                               }\r
+                               //hashID = BitConverter.intFromByteArray(data, 0);\r
+                               if (_version == 2) hashID = header.getMessageID();\r
+                               handleProtocolSessionStarted(header.getSessionType(), header.getSessionID(), _version, "");                             \r
+                       } else if (header.getFrameData() == FrameDataControlFrameType.StartSessionNACK.getValue()) {\r
+                               handleProtocolError("Got StartSessionNACK for protocol sessionID=" + header.getSessionID(), null);\r
+                       } else if (header.getFrameData() == FrameDataControlFrameType.EndSession.getValue()) {\r
+                               //if (hashID == BitConverter.intFromByteArray(data, 0)) \r
+                               if (_version == 2) {\r
+                                       if (hashID == header.getMessageID())\r
+                                               handleProtocolSessionEnded(header.getSessionType(), header.getSessionID(), "");\r
+                               } else handleProtocolSessionEnded(header.getSessionType(), header.getSessionID(), "");\r
+                       }\r
+               } // end-method\r
+                               \r
+               private void handleSingleFrameMessageFrame(ProtocolFrameHeader header, byte[] data) {\r
+                       ProtocolMessage message = new ProtocolMessage();\r
+                       if (header.getSessionType() == SessionType.RPC) {\r
+                               message.setMessageType(MessageType.RPC);\r
+                       } else if (header.getSessionType() == SessionType.Bulk_Data) {\r
+                               message.setMessageType(MessageType.BULK);\r
+                       } // end-if\r
+                       message.setSessionType(header.getSessionType());\r
+                       message.setSessionID(header.getSessionID());\r
+                       //If it is SmartDeviceLinkPro 2.0 it must have binary header\r
+                       if (_version == 2) {\r
+                               BinaryFrameHeader binFrameHeader = BinaryFrameHeader.\r
+                                               parseBinaryHeader(data);\r
+                               message.setVersion(_version);\r
+                               message.setRPCType(binFrameHeader.getRPCType());\r
+                               message.setFunctionID(binFrameHeader.getFunctionID());\r
+                               message.setCorrID(binFrameHeader.getCorrID());\r
+                               if (binFrameHeader.getJsonSize() > 0) message.setData(binFrameHeader.getJsonData());\r
+                               if (binFrameHeader.getBulkData() != null) message.setBulkData(binFrameHeader.getBulkData());\r
+                       } else message.setData(data);\r
+                       \r
+                       _assemblerForMessageID.remove(header.getMessageID());\r
+                       \r
+                       try {\r
+                               handleProtocolMessageReceived(message);\r
+                       } catch (Exception ex) {\r
+                               DebugTool.logError(FailurePropagating_Msg + "onProtocolMessageReceived: " + ex.toString(), ex);\r
+                               handleProtocolError(FailurePropagating_Msg + "onProtocolMessageReceived: ", ex);\r
+                       } // end-catch\r
+               } // end-method\r
+       } // end-class\r
+} // end-class
\ No newline at end of file
index 60714a5..56d5b03 100755 (executable)
@@ -1,42 +1,39 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.protocol.enums;
-
-import java.util.Vector;
-
-import com.smartdevicelink.util.ByteEnumer;
-
-public class FrameData extends ByteEnumer {
-
-       private static Vector theList = new Vector();
-       public static Vector getList() { return theList; } 
-       
-       byte i = 0x00;
-       
-       protected FrameData(byte value, String name) {super(value, name);}
-       public final static FrameData StartSession = new FrameData((byte)0x01, "StartSession");
-       public final static FrameData StartSessionACK = new FrameData((byte)0x02, "StartSessionACK");
-       public final static FrameData StartSessionNACK = new FrameData((byte)0x03, "StartSessionNACK");
-       public final static FrameData EndSession = new FrameData((byte)0x04, "EndSession");
-       
-       public final static FrameData SingleFrame = new FrameData((byte)0x00, "SingleFrame");
-       public final static FrameData FirstFrame = new FrameData((byte)0x00, "FirstFrame");
-       public final static FrameData ConsecutiveFrame = new FrameData((byte)0x00, "ConsecutiveFrame");
-       public final static byte LastFrame = (byte)0x00;
-       
-       static {
-               theList.addElement(StartSession);
-               theList.addElement(StartSessionACK);
-               theList.addElement(StartSessionNACK);
-               theList.addElement(EndSession); 
-       }
-       
-       public static FrameData valueOf(String passedButton) {
-               return (FrameData) get(theList, passedButton);
-       }
-       
-       public static FrameData[] values() {
-               return (FrameData[]) theList.toArray();
-       }
-}
+package com.smartdevicelink.protocol.enums;\r
+\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.util.ByteEnumer;\r
+\r
+public class FrameData extends ByteEnumer {\r
+\r
+       private static Vector theList = new Vector();\r
+       public static Vector getList() { return theList; } \r
+       \r
+       byte i = 0x00;\r
+       \r
+       protected FrameData(byte value, String name) {super(value, name);}\r
+       public final static FrameData StartSession = new FrameData((byte)0x01, "StartSession");\r
+       public final static FrameData StartSessionACK = new FrameData((byte)0x02, "StartSessionACK");\r
+       public final static FrameData StartSessionNACK = new FrameData((byte)0x03, "StartSessionNACK");\r
+       public final static FrameData EndSession = new FrameData((byte)0x04, "EndSession");\r
+       \r
+       public final static FrameData SingleFrame = new FrameData((byte)0x00, "SingleFrame");\r
+       public final static FrameData FirstFrame = new FrameData((byte)0x00, "FirstFrame");\r
+       public final static FrameData ConsecutiveFrame = new FrameData((byte)0x00, "ConsecutiveFrame");\r
+       public final static byte LastFrame = (byte)0x00;\r
+       \r
+       static {\r
+               theList.addElement(StartSession);\r
+               theList.addElement(StartSessionACK);\r
+               theList.addElement(StartSessionNACK);\r
+               theList.addElement(EndSession); \r
+       }\r
+       \r
+       public static FrameData valueOf(String passedButton) {\r
+               return (FrameData) get(theList, passedButton);\r
+       }\r
+       \r
+       public static FrameData[] values() {\r
+               return (FrameData[]) theList.toArray();\r
+       }\r
+}\r
index efae9a7..49860e1 100755 (executable)
@@ -1,36 +1,33 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.protocol.enums;
-
-import java.util.Vector;
-
-import com.smartdevicelink.util.ByteEnumer;
-
-public class FrameDataControlFrameType extends ByteEnumer {
-       private static Vector theList = new Vector();
-       public static Vector getList() { return theList; } 
-
-       private byte _i = 0x00;
-
-       protected FrameDataControlFrameType(byte value, String name) {super(value, name);}
-       public final static FrameDataControlFrameType StartSession = new FrameDataControlFrameType((byte)0x01, "StartSession");
-       public final static FrameDataControlFrameType StartSessionACK = new FrameDataControlFrameType((byte)0x02, "StartSessionACK");
-       public final static FrameDataControlFrameType StartSessionNACK = new FrameDataControlFrameType((byte)0x03, "StartSessionNACK");
-       public final static FrameDataControlFrameType EndSession = new FrameDataControlFrameType((byte)0x04, "EndSession");
-
-       static {
-               theList.addElement(StartSession);
-               theList.addElement(StartSessionACK);
-               theList.addElement(StartSessionNACK);
-               theList.addElement(EndSession); 
-       }
-
-       public static FrameDataControlFrameType valueOf(String passedButton) {
-               return (FrameDataControlFrameType) get(theList, passedButton);
-       } // end-method
-
-       public static FrameDataControlFrameType[] values() {
-               return (FrameDataControlFrameType[]) theList.toArray();
-       } // end-method
-} // end-class
+package com.smartdevicelink.protocol.enums;\r
+\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.util.ByteEnumer;\r
+\r
+public class FrameDataControlFrameType extends ByteEnumer {\r
+       private static Vector theList = new Vector();\r
+       public static Vector getList() { return theList; } \r
+\r
+       private byte _i = 0x00;\r
+\r
+       protected FrameDataControlFrameType(byte value, String name) {super(value, name);}\r
+       public final static FrameDataControlFrameType StartSession = new FrameDataControlFrameType((byte)0x01, "StartSession");\r
+       public final static FrameDataControlFrameType StartSessionACK = new FrameDataControlFrameType((byte)0x02, "StartSessionACK");\r
+       public final static FrameDataControlFrameType StartSessionNACK = new FrameDataControlFrameType((byte)0x03, "StartSessionNACK");\r
+       public final static FrameDataControlFrameType EndSession = new FrameDataControlFrameType((byte)0x04, "EndSession");\r
+\r
+       static {\r
+               theList.addElement(StartSession);\r
+               theList.addElement(StartSessionACK);\r
+               theList.addElement(StartSessionNACK);\r
+               theList.addElement(EndSession); \r
+       }\r
+\r
+       public static FrameDataControlFrameType valueOf(String passedButton) {\r
+               return (FrameDataControlFrameType) get(theList, passedButton);\r
+       } // end-method\r
+\r
+       public static FrameDataControlFrameType[] values() {\r
+               return (FrameDataControlFrameType[]) theList.toArray();\r
+       } // end-method\r
+} // end-class
\ No newline at end of file
index 984dca1..34f9867 100755 (executable)
@@ -1,37 +1,34 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.protocol.enums;
-
-import java.util.Vector;
-
-import com.smartdevicelink.util.ByteEnumer;
-
-public class FrameType extends ByteEnumer {
-
-       private static Vector theList = new Vector();
-       public static Vector getList() { return theList; } 
-       
-       byte i = 0x00;
-       
-       protected FrameType(byte value, String name) {super(value, name);}
-       public final static FrameType Control = new FrameType((byte)0x00, "Control");
-       public final static FrameType Single = new FrameType((byte)0x01, "Single");
-       public final static FrameType First = new FrameType((byte)0x02, "First");
-       public final static FrameType Consecutive = new FrameType((byte)0x03, "Consecutive");
-       
-       static {
-               theList.addElement(Control);
-               theList.addElement(Single);
-               theList.addElement(First);
-               theList.addElement(Consecutive);
-       }
-       
-       public static FrameType valueOf(byte passed) {
-               return (FrameType) get(theList, passed);
-       }
-       
-       public static FrameType[] values() {
-               return (FrameType[]) theList.toArray();
-       }
-}
+package com.smartdevicelink.protocol.enums;\r
+\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.util.ByteEnumer;\r
+\r
+public class FrameType extends ByteEnumer {\r
+\r
+       private static Vector theList = new Vector();\r
+       public static Vector getList() { return theList; } \r
+       \r
+       byte i = 0x00;\r
+       \r
+       protected FrameType(byte value, String name) {super(value, name);}\r
+       public final static FrameType Control = new FrameType((byte)0x00, "Control");\r
+       public final static FrameType Single = new FrameType((byte)0x01, "Single");\r
+       public final static FrameType First = new FrameType((byte)0x02, "First");\r
+       public final static FrameType Consecutive = new FrameType((byte)0x03, "Consecutive");\r
+       \r
+       static {\r
+               theList.addElement(Control);\r
+               theList.addElement(Single);\r
+               theList.addElement(First);\r
+               theList.addElement(Consecutive);\r
+       }\r
+       \r
+       public static FrameType valueOf(byte passed) {\r
+               return (FrameType) get(theList, passed);\r
+       }\r
+       \r
+       public static FrameType[] values() {\r
+               return (FrameType[]) theList.toArray();\r
+       }\r
+}\r
index f602f7e..de92548 100755 (executable)
@@ -1,86 +1,87 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.protocol.enums;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-
-import com.smartdevicelink.proxy.constants.Names;
-
-public class FunctionID {
-       static ArrayList<String> functionID = null;
-       
-       public FunctionID() {
-       }
-       
-       static public String getFunctionName(int i) {
-               if (functionID == null) {
-                       initFunctionIds();
-               }
-               return functionID.get(i);
-       }
-       
-       static public void initFunctionIds() {
-               String [] functionIds = new String[60];
-               functionIds[1] = Names.RegisterAppInterface;
-               functionIds[2] = Names.UnregisterAppInterface;
-               functionIds[3] = Names.SetGlobalProperties;
-               functionIds[4] = Names.ResetGlobalProperties;
-               functionIds[5] = Names.AddCommand;
-               functionIds[6] = Names.DeleteCommand;
-               functionIds[7] = Names.AddSubMenu;
-               functionIds[8] = Names.DeleteSubMenu;
-               functionIds[9] = Names.CreateInteractionChoiceSet;
-               functionIds[10] = Names.PerformInteraction;
-               functionIds[11] = Names.DeleteInteractionChoiceSet;
-               functionIds[12] = Names.Alert;
-               functionIds[13] = Names.Show;
-               functionIds[14] = Names.Speak;
-               functionIds[15] = Names.SetMediaClockTimer;
-               functionIds[16] = Names.EncodedSyncPData;
-               functionIds[17] = Names.DialNumber;
-               functionIds[18] = Names.PerformAudioPassThru;
-               functionIds[19] = Names.EndAudioPassThru;
-               functionIds[20] = Names.SubscribeButton;
-               functionIds[21] = Names.UnsubscribeButton;
-               functionIds[22] = Names.SubscribeVehicleData;
-               functionIds[23] = Names.UnsubscribeVehicleData;
-               functionIds[24] = Names.GetVehicleData;
-               functionIds[25] = Names.ReadDID;
-               functionIds[26] = Names.GetDTCs;
-               functionIds[27] = Names.ScrollableMessage;
-               functionIds[28] = Names.Slider;
-               functionIds[29] = Names.ShowConstantTBT;
-               functionIds[30] = Names.AlertManeuver;
-               functionIds[31] = Names.UpdateTurnList;
-               functionIds[32] = Names.ChangeRegistration;
-               functionIds[33] = Names.GenericResponse;
-               functionIds[34] = Names.PutFile;
-               functionIds[35] = Names.DeleteFile;
-               functionIds[36] = Names.ListFiles;
-               functionIds[37] = Names.SetAppIcon;
-               functionIds[38] = Names.SetDisplayLayout;
-               functionIds[39] = Names.OnHMIStatus;
-               functionIds[40] = Names.OnAppInterfaceUnregistered;
-               functionIds[41] = Names.OnButtonEvent;
-               functionIds[42] = Names.OnButtonPress;
-               functionIds[43] = Names.OnVehicleData;
-               functionIds[44] = Names.OnCommand;
-               functionIds[45] = Names.OnEncodedSyncPData;
-               functionIds[46] = Names.OnTBTClientState;
-               functionIds[47] = Names.OnDriverDistraction;
-               functionIds[48] = Names.OnPermissionsChange;
-               functionIds[49] = Names.OnAudioPassThru;
-               functionIds[50] = Names.OnLanguageChange;       
-               
-               functionID = new ArrayList<String>(Arrays.asList(functionIds));
-       }
-       
-       static public int getFunctionID(String functionName) {
-               if (functionID == null) {
-                       initFunctionIds();
-               }
-               return functionID.indexOf(functionName);
-       }
-}
+package com.smartdevicelink.protocol.enums;\r
+\r
+import java.util.ArrayList;\r
+import java.util.Arrays;\r
+\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+public class FunctionID {\r
+       static ArrayList<String> functionID = null;\r
+       \r
+       public FunctionID() {\r
+       }\r
+       \r
+       static public String getFunctionName(int i) {\r
+               if (functionID == null) {\r
+                       initFunctionIds();\r
+               }\r
+               return functionID.get(i);\r
+       }\r
+       \r
+       static public void initFunctionIds() {\r
+               String [] functionIds = new String[98306];\r
+               functionIds[1] = Names.RegisterAppInterface;\r
+               functionIds[2] = Names.UnregisterAppInterface;\r
+               functionIds[3] = Names.SetGlobalProperties;\r
+               functionIds[4] = Names.ResetGlobalProperties;\r
+               functionIds[5] = Names.AddCommand;\r
+               functionIds[6] = Names.DeleteCommand;\r
+               functionIds[7] = Names.AddSubMenu;\r
+               functionIds[8] = Names.DeleteSubMenu;\r
+               functionIds[9] = Names.CreateInteractionChoiceSet;\r
+               functionIds[10] = Names.PerformInteraction;\r
+               functionIds[11] = Names.DeleteInteractionChoiceSet;\r
+               functionIds[12] = Names.Alert;\r
+               functionIds[13] = Names.Show;\r
+               functionIds[14] = Names.Speak;\r
+               functionIds[15] = Names.SetMediaClockTimer;\r
+               functionIds[16] = Names.PerformAudioPassThru;\r
+               functionIds[17] = Names.EndAudioPassThru;\r
+               functionIds[18] = Names.SubscribeButton;\r
+               functionIds[19] = Names.UnsubscribeButton;\r
+               functionIds[20] = Names.SubscribeVehicleData;\r
+               functionIds[21] = Names.UnsubscribeVehicleData;\r
+               functionIds[22] = Names.GetVehicleData;\r
+               functionIds[23] = Names.ReadDID;\r
+               functionIds[24] = Names.GetDTCs;\r
+               functionIds[25] = Names.ScrollableMessage;\r
+               functionIds[26] = Names.Slider;\r
+               functionIds[27] = Names.ShowConstantTBT;\r
+               functionIds[28] = Names.AlertManeuver;\r
+               functionIds[29] = Names.UpdateTurnList;\r
+               functionIds[30] = Names.ChangeRegistration;\r
+               functionIds[31] = Names.GenericResponse;\r
+               functionIds[32] = Names.PutFile;\r
+               functionIds[33] = Names.DeleteFile;\r
+               functionIds[34] = Names.ListFiles;\r
+               functionIds[35] = Names.SetAppIcon;\r
+               functionIds[36] = Names.SetDisplayLayout;\r
+               \r
+               functionIds[32768] = Names.OnHMIStatus;\r
+               functionIds[32769] = Names.OnAppInterfaceUnregistered;\r
+               functionIds[32770] = Names.OnButtonEvent;\r
+               functionIds[32771] = Names.OnButtonPress;\r
+               functionIds[32772] = Names.OnVehicleData;\r
+               functionIds[32773] = Names.OnCommand;\r
+               functionIds[32774] = Names.OnTBTClientState;\r
+               functionIds[32775] = Names.OnDriverDistraction;\r
+               functionIds[32776] = Names.OnPermissionsChange;\r
+               functionIds[32777] = Names.OnAudioPassThru;\r
+               functionIds[32778] = Names.OnLanguageChange;\r
+\r
+               functionIds[65536] = Names.EncodedSyncPData;\r
+               functionIds[65537] = Names.SyncPData;\r
+               \r
+               functionIds[98304] = Names.OnEncodedSyncPData;\r
+               functionIds[98305] = Names.OnSyncPData;\r
+               \r
+               functionID = new ArrayList<String>(Arrays.asList(functionIds));\r
+       }\r
+       \r
+       static public int getFunctionID(String functionName) {\r
+               if (functionID == null) {\r
+                       initFunctionIds();\r
+               }\r
+               return functionID.indexOf(functionName);\r
+       }\r
+}
\ No newline at end of file
index 9f6aa88..a4fed0f 100755 (executable)
@@ -1,10 +1,11 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.protocol.enums;
-
-public enum MessageType {
-       UNDEFINED,
-       BULK,
-       RPC
-}
+package com.smartdevicelink.protocol.enums;\r
+\r
+public enum MessageType {\r
+//     START_SESSION,\r
+//     START_SESSION_ACK,\r
+//     START_SESSION_NACK,\r
+//     END_SESSION,\r
+       UNDEFINED,\r
+       BULK,\r
+       RPC\r
+}\r
index 34defe5..04d9abe 100755 (executable)
@@ -1,34 +1,31 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.protocol.enums;
-
-import java.util.Vector;
-
-import com.smartdevicelink.util.ByteEnumer;
-
-
-public class SessionType extends ByteEnumer {
-
-       private static Vector theList = new Vector();
-       public static Vector getList() { return theList; } 
-       
-       byte i = 0x00;
-       
-       protected SessionType(byte value, String name) {super(value, name);}
-       public final static SessionType RPC = new SessionType((byte)0x07, "RPC");
-       public final static SessionType Bulk_Data = new SessionType((byte)0xF, "Bulk_Data");
-
-       static {
-               theList.addElement(RPC);
-               theList.addElement(Bulk_Data);
-       }
-       
-       public static SessionType valueOf(byte passedButton) {
-               return (SessionType) get(theList, passedButton);
-       }
-       
-       public static SessionType[] values() {
-               return (SessionType[]) theList.toArray();
-       }
-}
+package com.smartdevicelink.protocol.enums;\r
+\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.util.ByteEnumer;\r
+\r
+\r
+public class SessionType extends ByteEnumer {\r
+\r
+       private static Vector theList = new Vector();\r
+       public static Vector getList() { return theList; } \r
+       \r
+       byte i = 0x00;\r
+       \r
+       protected SessionType(byte value, String name) {super(value, name);}\r
+       public final static SessionType RPC = new SessionType((byte)0x07, "RPC");\r
+       public final static SessionType Bulk_Data = new SessionType((byte)0xF, "Bulk_Data");\r
+\r
+       static {\r
+               theList.addElement(RPC);\r
+               theList.addElement(Bulk_Data);\r
+       }\r
+       \r
+       public static SessionType valueOf(byte passedButton) {\r
+               return (SessionType) get(theList, passedButton);\r
+       }\r
+       \r
+       public static SessionType[] values() {\r
+               return (SessionType[]) theList.toArray();\r
+       }\r
+}\r
index 59180cc..2ef06c3 100755 (executable)
@@ -1,22 +1,19 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy;
-
-import com.smartdevicelink.proxy.interfaces.IProxyListenerBase;
-import com.smartdevicelink.proxy.rpc.OnAppInterfaceUnregistered;
-import com.smartdevicelink.proxy.rpc.RegisterAppInterfaceResponse;
-import com.smartdevicelink.proxy.rpc.UnregisterAppInterfaceResponse;
-
-public interface IProxyListener extends IProxyListenerBase{
-       // Adds Legacy Life-cycle Management call-backs to the IProxyListenerAbstract interface
-       
-       public void onProxyOpened();
-       
-       public void onRegisterAppInterfaceResponse(RegisterAppInterfaceResponse response);
-
-       public void onOnAppInterfaceUnregistered(OnAppInterfaceUnregistered notification);
-       
-       public void onUnregisterAppInterfaceResponse(UnregisterAppInterfaceResponse response);
-       
-}
+package com.smartdevicelink.proxy;\r
+\r
+import com.smartdevicelink.proxy.interfaces.IProxyListenerBase;\r
+import com.smartdevicelink.proxy.rpc.OnAppInterfaceUnregistered;\r
+import com.smartdevicelink.proxy.rpc.RegisterAppInterfaceResponse;\r
+import com.smartdevicelink.proxy.rpc.UnregisterAppInterfaceResponse;\r
+\r
+public interface IProxyListener extends IProxyListenerBase{\r
+       // Adds Legacy Life-cycle Management call-backs to the IProxyListenerAbstract interface\r
+       \r
+       public void onProxyOpened();\r
+       \r
+       public void onRegisterAppInterfaceResponse(RegisterAppInterfaceResponse response);\r
+\r
+       public void onOnAppInterfaceUnregistered(OnAppInterfaceUnregistered notification);\r
+       \r
+       public void onUnregisterAppInterfaceResponse(UnregisterAppInterfaceResponse response);\r
+       \r
+}\r
index dae9dfb..8df1f93 100755 (executable)
@@ -1,71 +1,71 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.protocol.ProtocolMessage;
-import com.smartdevicelink.protocol.enums.FunctionID;
-import com.smartdevicelink.proxy.constants.Names;
-
-public class RPCMessage extends RPCStruct  {
-
-       public RPCMessage(String functionName) {
-               this(functionName, "request");
-       }
-       
-       protected RPCMessage(RPCMessage rpcm) {
-               this(rpcm.store);
-       }
-       
-       protected RPCMessage(RPCStruct rpcs) {
-               this("", "");
-               this.parameters = rpcs.store;
-       }
-       
-       public RPCMessage(String functionName, String messageType) {
-               function = new Hashtable();
-               this.messageType = messageType;
-               store.put(messageType, function);
-               parameters = new Hashtable();
-               function.put(Names.parameters, parameters);
-               function.put(Names.function_name, functionName);
-       }
-
-       public RPCMessage(Hashtable hash) {
+package com.smartdevicelink.proxy;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Iterator;
+\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+public class RPCMessage extends RPCStruct  {\r
+\r
+       public RPCMessage(String functionName) {\r
+               this(functionName, "request");\r
+       }\r
+       \r
+       protected RPCMessage(RPCMessage rpcm) {\r
+               this(rpcm.store);\r
+       }\r
+       \r
+       protected RPCMessage(RPCStruct rpcs) {\r
+               this("", "");\r
+               this.parameters = rpcs.store;\r
+       }\r
+       \r
+       public RPCMessage(String functionName, String messageType) {\r
+               function = new Hashtable();\r
+               this.messageType = messageType;\r
+               store.put(messageType, function);\r
+               parameters = new Hashtable();\r
+               function.put(Names.parameters, parameters);\r
+               function.put(Names.function_name, functionName);\r
+       }\r
+\r
+       public RPCMessage(Hashtable hash) {\r
                store = hash;
-               messageType = (String)hash.keys().nextElement();
-
-               function = (Hashtable)hash.get(messageType);
-               parameters = (Hashtable)function.get(Names.parameters);
-       }
-
-       protected String messageType;
-       protected Hashtable parameters;
-       protected Hashtable function;
-       
-       public String getFunctionName() {
-               return (String)function.get(Names.function_name);
-       }
-       
-       protected void setFunctionName(String functionName) {
-               function.put(Names.function_name, functionName);
-       }
-
-       public String getMessageType() {
-               return messageType;
-       }
-       
-       public void setParameters(String functionName, Object value) {
-               if (value != null) {
-                       parameters.put(functionName, value);
-               } else {
-                       parameters.remove(functionName);
-               }
-       }
-       
-       public Object getParameters(String functionName) {
-               return parameters.get(functionName);
-       }
-}
+               Iterator it = hash.keySet().iterator();
+               String key;
+               while (it.hasNext()) {
+                       key = (String)it.next().toString();
+                       if (key != Names.bulkData) messageType = key;
+               }\r
+               function = (Hashtable)hash.get(messageType);\r
+               parameters = (Hashtable)function.get(Names.parameters);\r
+       }\r
+\r
+       protected String messageType;\r
+       protected Hashtable parameters;\r
+       protected Hashtable function;\r
+       \r
+       public String getFunctionName() {\r
+               return (String)function.get(Names.function_name);\r
+       }\r
+       \r
+       protected void setFunctionName(String functionName) {\r
+               function.put(Names.function_name, functionName);\r
+       }\r
+\r
+       public String getMessageType() {\r
+               return messageType;\r
+       }\r
+       \r
+       public void setParameters(String functionName, Object value) {\r
+               if (value != null) {\r
+                       parameters.put(functionName, value);\r
+               } else {\r
+                       parameters.remove(functionName);\r
+               }\r
+       }\r
+       \r
+       public Object getParameters(String functionName) {\r
+               return parameters.get(functionName);\r
+       }\r
+}\r
index 6380ba0..e3562b6 100755 (executable)
@@ -1,21 +1,21 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy;
-
-import java.util.Hashtable;
-
-public class RPCNotification extends RPCMessage {
-
-       public RPCNotification(String functionName) {
-               super(functionName, "notification");
-       }
-
-       public RPCNotification(Hashtable hash) {
-               super(hash);
-       }
-
-       public RPCNotification(RPCMessage rpcMsg) {
-               super(rpcMsg);
-       }
-} // end-class
+/**\r
+ * \r
+ */\r
+package com.smartdevicelink.proxy;\r
+\r
+import java.util.Hashtable;\r
+\r
+public class RPCNotification extends RPCMessage {\r
+\r
+       public RPCNotification(String functionName) {\r
+               super(functionName, "notification");\r
+       }\r
+\r
+       public RPCNotification(Hashtable hash) {\r
+               super(hash);\r
+       }\r
+\r
+       public RPCNotification(RPCMessage rpcMsg) {\r
+               super(rpcMsg);\r
+       }\r
+} // end-class
\ No newline at end of file
index 803672c..6747879 100755 (executable)
@@ -1,32 +1,32 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.constants.Names;
-
-public class RPCRequest extends RPCMessage {
-
-       public RPCRequest(String functionName) {
-               super(functionName, "request");
-               messageType = Names.request;
-       }
-
-       public RPCRequest(Hashtable hash) {
-               super(hash);
-       }
-
-       public Integer getCorrelationID() {
-               return (Integer)function.get(Names.correlationID);
-       }
-       
-       public void setCorrelationID(Integer correlationID) {
-               if (correlationID != null) {
-            function.put(Names.correlationID, correlationID );
-        } else if (parameters.contains(Names.correlationID)) {
-               function.remove(Names.correlationID);
-        }
-       }
-}
+/**\r
+ * \r
+ */\r
+package com.smartdevicelink.proxy;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+public class RPCRequest extends RPCMessage {\r
+\r
+       public RPCRequest(String functionName) {\r
+               super(functionName, "request");\r
+               messageType = Names.request;\r
+       }\r
+\r
+       public RPCRequest(Hashtable hash) {\r
+               super(hash);\r
+       }\r
+\r
+       public Integer getCorrelationID() {\r
+               return (Integer)function.get(Names.correlationID);\r
+       }\r
+       \r
+       public void setCorrelationID(Integer correlationID) {\r
+               if (correlationID != null) {\r
+            function.put(Names.correlationID, correlationID );\r
+        } else if (parameters.contains(Names.correlationID)) {\r
+               function.remove(Names.correlationID);\r
+        }\r
+       }\r
+}\r
index 529345f..63d90ee 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy;
-
-import java.util.Vector;
-
-import com.smartdevicelink.proxy.rpc.*;
-import com.smartdevicelink.proxy.rpc.enums.*;
-
-public class RPCRequestFactory {
-
-       public static final int NGN_MEDIA_SCREEN_APP_NAME_MAX_LENGTH = 5;
-       public static final int SMARTDEVICELINK_MSG_MAJOR_VERSION = 1;
-       public static final int SMARTDEVICELINK_MSG_MINOR_VERSION = 0;
-
-       public static EncodedSyncPData buildEncodedSyncPData(
-                       Vector<String> data, Integer correlationID) {
-               
-               if(data == null) return null;
-               
-               EncodedSyncPData msg = new EncodedSyncPData();
-               msg.setCorrelationID(correlationID);
-               msg.setData(data);
-               return msg;
-       }
-       
-       public static AddCommand buildAddCommand(Integer commandID,
-                       String menuText, Integer parentID, Integer position,
-                       Vector<String> vrCommands, Integer correlationID) {
-               AddCommand msg = new AddCommand();
-               msg.setCorrelationID(correlationID);
-               msg.setCmdID(commandID);
-               msg.setVrCommands(vrCommands);
-               
-               if(menuText != null || parentID != null || position != null) {
-                       MenuParams menuParams = new MenuParams();
-                       menuParams.setMenuName(menuText);
-                       menuParams.setPosition(position);
-                       menuParams.setParentID(parentID);
-                       msg.setMenuParams(menuParams);
-               }
-               
-               return msg;
-       }
-       
-       public static AddCommand buildAddCommand(Integer commandID,
-                       String menuText, Vector<String> vrCommands, Integer correlationID) {
-               AddCommand msg = buildAddCommand(commandID, menuText, null, null,
-                               vrCommands, correlationID);
-               return msg;
-       }
-       
-       public static AddCommand buildAddCommand(Integer commandID,
-                       Vector<String> vrCommands, Integer correlationID) {
-               AddCommand msg = new AddCommand();
-               msg.setCorrelationID(correlationID);
-               msg.setCmdID(commandID);
-               msg.setVrCommands(vrCommands);
-
-               return msg;
-       }
-
-       public static AddSubMenu buildAddSubMenu(Integer menuID, String menuName,
-                       Integer correlationID) {
-               AddSubMenu msg = buildAddSubMenu(menuID, menuName, null, correlationID);
-               return msg;
-       }
-
-       public static AddSubMenu buildAddSubMenu(Integer menuID, String menuName,
-                       Integer position, Integer correlationID) {
-               AddSubMenu msg = new AddSubMenu();
-               msg.setCorrelationID(correlationID);
-               msg.setMenuName(menuName);
-               msg.setMenuID(menuID);
-               msg.setPosition(position);
-
-               return msg;
-       }
-       
-       public static Alert buildAlert(String ttsText, Boolean playTone,
-                       Integer correlationID) {
-               Vector<TTSChunk> chunks = TTSChunkFactory
-                               .createSimpleTTSChunks(ttsText);
-               Alert msg = buildAlert(chunks, null, null, playTone, null,
-                               correlationID);
-               return msg;
-       }
-       
-       public static Alert buildAlert(String alertText1, String alertText2,
-                       Integer duration, Integer correlationID) {
-               Alert msg = buildAlert((Vector<TTSChunk>) null, alertText1, alertText2,
-                               null, duration, correlationID);
-               return msg;
-       }
-       
-       public static Alert buildAlert(String ttsText, String alertText1,
-                       String alertText2, Boolean playTone, Integer duration,
-                       Integer correlationID) {
-               Vector<TTSChunk> chunks = TTSChunkFactory
-                               .createSimpleTTSChunks(ttsText);
-               Alert msg = buildAlert(chunks, alertText1, alertText2, playTone,
-                               duration, correlationID);
-               return msg;
-       }
-       
-       public static Alert buildAlert(Vector<TTSChunk> chunks, Boolean playTone,
-                       Integer correlationID) {
-               Alert msg = buildAlert(chunks, null, null, playTone, null,
-                               correlationID);
-               return msg;
-       }
-       
-       public static Alert buildAlert(Vector<TTSChunk> ttsChunks,
-                       String alertText1, String alertText2, Boolean playTone,
-                       Integer duration, Integer correlationID) {
-               Alert msg = new Alert();
-               msg.setCorrelationID(correlationID);
-               msg.setAlertText1(alertText1);
-               msg.setAlertText2(alertText2);
-               msg.setDuration(duration);
-               msg.setPlayTone(playTone);
-               msg.setTtsChunks(ttsChunks);
-
-               return msg;
-       }
-       
-       public static CreateInteractionChoiceSet buildCreateInteractionChoiceSet(
-                       Vector<Choice> choiceSet, Integer interactionChoiceSetID,
-                       Integer correlationID) {
-               CreateInteractionChoiceSet msg = new CreateInteractionChoiceSet();
-               msg.setChoiceSet(choiceSet);
-               msg.setInteractionChoiceSetID(interactionChoiceSetID);
-               msg.setCorrelationID(correlationID);
-               return msg;
-       }
-       
-       public static DeleteCommand buildDeleteCommand(Integer commandID,
-                       Integer correlationID) {
-               DeleteCommand msg = new DeleteCommand();
-               msg.setCmdID(commandID);
-               msg.setCorrelationID(correlationID);
-               return msg;
-       }
-       
-       public static DeleteInteractionChoiceSet buildDeleteInteractionChoiceSet(
-                       Integer interactionChoiceSetID, Integer correlationID) {
-               DeleteInteractionChoiceSet msg = new DeleteInteractionChoiceSet();
-               msg.setInteractionChoiceSetID(interactionChoiceSetID);
-               msg.setCorrelationID(correlationID);
-
-               return msg;
-       }
-       
-       public static DeleteSubMenu buildDeleteSubMenu(Integer menuID,
-                       Integer correlationID) {
-               DeleteSubMenu msg = new DeleteSubMenu();
-               msg.setCorrelationID(correlationID);
-               msg.setMenuID(menuID);
-
-               return msg;
-       }
-
-       public static PerformInteraction buildPerformInteraction(
-                       Vector<TTSChunk> initChunks, String displayText,
-                       Vector<Integer> interactionChoiceSetIDList,
-                       Vector<TTSChunk> helpChunks, Vector<TTSChunk> timeoutChunks,
-                       InteractionMode interactionMode, Integer timeout,
-                       Integer correlationID) {
-               PerformInteraction msg = new PerformInteraction();
-               msg.setInitialPrompt(initChunks);
-               msg.setInitialText(displayText);
-               msg.setInteractionChoiceSetIDList(interactionChoiceSetIDList);
-               msg.setInteractionMode(interactionMode);
-               msg.setTimeout(timeout);
-               msg.setHelpPrompt(helpChunks);
-               msg.setTimeoutPrompt(timeoutChunks);
-               msg.setCorrelationID(correlationID);
-               
-               return msg;
-       }
-
-       public static PerformInteraction buildPerformInteraction(
-                       String initPrompt,      String displayText, 
-                       Vector<Integer> interactionChoiceSetIDList,
-                       String helpPrompt, String timeoutPrompt,
-                       InteractionMode interactionMode, Integer timeout,
-                       Integer correlationID) {
-               Vector<TTSChunk> initChunks = TTSChunkFactory
-                               .createSimpleTTSChunks(initPrompt);
-               Vector<TTSChunk> helpChunks = TTSChunkFactory
-                               .createSimpleTTSChunks(helpPrompt);
-               Vector<TTSChunk> timeoutChunks = TTSChunkFactory
-                               .createSimpleTTSChunks(timeoutPrompt);
-               return buildPerformInteraction(initChunks,
-                               displayText, interactionChoiceSetIDList, helpChunks,
-                               timeoutChunks, interactionMode, timeout, correlationID);
-       }
-       
-       public static PerformInteraction buildPerformInteraction(
-                       String initPrompt,      String displayText, 
-                       Integer interactionChoiceSetID,
-                       String helpPrompt, String timeoutPrompt,
-                       InteractionMode interactionMode, Integer timeout,
-                       Integer correlationID) {
-               Vector<Integer> interactionChoiceSetIDs = new Vector<Integer>();
-                       interactionChoiceSetIDs.add(interactionChoiceSetID);
-               
-               return buildPerformInteraction(
-                               initPrompt, displayText, interactionChoiceSetIDs, 
-                               helpPrompt, timeoutPrompt, interactionMode, 
-                               timeout, correlationID);
-       }
-       
-       public static PerformInteraction buildPerformInteraction(String initPrompt,
-                       String displayText, Integer interactionChoiceSetID,
-                       Integer correlationID) {
-
-               return buildPerformInteraction(initPrompt, displayText, 
-                               interactionChoiceSetID, null, null,
-                               InteractionMode.BOTH, null, correlationID);
-       }
-       
-       @Deprecated
-       public static PerformInteraction buildPerformInteraction(
-                       Vector<TTSChunk> initChunks, String displayText,
-                       Vector<Integer> interactionChoiceSetIDList,
-                       Vector<TTSChunk> helpChunks, InteractionMode interactionMode,
-                       Integer timeout, Integer correlationID) {
-               PerformInteraction msg = new PerformInteraction();
-               msg.setInitialPrompt(initChunks);
-               msg.setInitialText(displayText);
-               msg.setInteractionChoiceSetIDList(interactionChoiceSetIDList);
-               msg.setInteractionMode(interactionMode);
-               msg.setTimeout(timeout);
-               msg.setHelpPrompt(helpChunks);
-               msg.setCorrelationID(correlationID);
-               return msg;
-       }
-       
-       @Deprecated
-       public static PerformInteraction buildPerformInteraction(String initPrompt,
-                       String displayText, Vector<Integer> interactionChoiceSetIDList,
-                       String helpPrompt, InteractionMode interactionMode,
-                       Integer timeout, Integer correlationID) {
-               Vector<TTSChunk> initChunks = TTSChunkFactory
-                               .createSimpleTTSChunks(initPrompt);
-               Vector<TTSChunk> helpChunks = TTSChunkFactory
-                               .createSimpleTTSChunks(helpPrompt);
-               PerformInteraction msg = buildPerformInteraction(initChunks,
-                               displayText, interactionChoiceSetIDList, helpChunks,
-                               interactionMode, timeout, correlationID);
-               return msg;
-       }
-       
-       public static RegisterAppInterface buildRegisterAppInterface(String appName) {
-               return buildRegisterAppInterface(appName, false, "");
-       }
-       
-       public static RegisterAppInterface buildRegisterAppInterface(
-                       String appName, Boolean isMediaApp, String autoActivateID) {
-               
-               return buildRegisterAppInterface(null, appName, null, null, isMediaApp, 
-                               null, autoActivateID, null); 
-       }
-       
-       public static RegisterAppInterface buildRegisterAppInterface(
-                       SyncMsgVersion SyncMsgVersion, String appName, String ngnMediaScreenAppName,
-                       Vector<String> vrSynonyms, Boolean isMediaApp, Language languageDesired, 
-                       String autoActivateID, Integer correlationID) {
-               RegisterAppInterface msg = new RegisterAppInterface();
-               
-               if (correlationID == null) {
-                       correlationID = 1;
-               }
-               msg.setCorrelationID(correlationID);
-               
-               if (SyncMsgVersion == null) {
-                       SyncMsgVersion = new SyncMsgVersion();
-                       SyncMsgVersion.setMajorVersion(new Integer(SMARTDEVICELINK_MSG_MAJOR_VERSION));
-                       SyncMsgVersion.setMinorVersion(new Integer(SMARTDEVICELINK_MSG_MINOR_VERSION));
-               } 
-               msg.setSyncMsgVersion(SyncMsgVersion);
-               
-               msg.setAppName(appName);
-               
-               msg.setAutoActivateID(autoActivateID);
-               
-               if (ngnMediaScreenAppName == null) {
-                       ngnMediaScreenAppName = appName;
-               }
-               
-               if (ngnMediaScreenAppName.length() > NGN_MEDIA_SCREEN_APP_NAME_MAX_LENGTH) {
-                       ngnMediaScreenAppName = ngnMediaScreenAppName.substring(0,
-                                       NGN_MEDIA_SCREEN_APP_NAME_MAX_LENGTH);
-               }
-               msg.setNgnMediaScreenAppName(ngnMediaScreenAppName);
-               
-               if (vrSynonyms == null) {
-                       vrSynonyms = new Vector<String>();
-                       vrSynonyms.add(appName);
-               }
-               msg.setVrSynonyms(vrSynonyms);
-               
-               msg.setIsMediaApplication(isMediaApp);
-               
-               if (languageDesired == null) {
-                       languageDesired = Language.EN_US;
-               }
-               msg.setLanguageDesired(languageDesired);
-
-               return msg;
-       }
-       
-       public static SetGlobalProperties buildSetGlobalProperties(
-                       String helpPrompt, String timeoutPrompt, Integer correlationID) {
-               return buildSetGlobalProperties(TTSChunkFactory
-                               .createSimpleTTSChunks(helpPrompt), TTSChunkFactory
-                               .createSimpleTTSChunks(timeoutPrompt), correlationID);
-       }
-       
-       public static SetGlobalProperties buildSetGlobalProperties(
-                       Vector<TTSChunk> helpChunks, Vector<TTSChunk> timeoutChunks,
-                       Integer correlationID) {
-               SetGlobalProperties req = new SetGlobalProperties();
-               req.setCorrelationID(correlationID);
-
-               req.setHelpPrompt(helpChunks);
-               req.setTimeoutPrompt(timeoutChunks);
-
-               return req;
-       }
-
-       public static SetMediaClockTimer buildSetMediaClockTimer(Integer hours,
-                       Integer minutes, Integer seconds, UpdateMode updateMode,
-                       Integer correlationID) {
-
-               SetMediaClockTimer msg = new SetMediaClockTimer();
-               if (hours != null || minutes != null || seconds != null) {
-                       StartTime startTime = new StartTime();
-                       msg.setStartTime(startTime);
-                       startTime.setHours(hours);
-                       startTime.setMinutes(minutes);
-                       startTime.setSeconds(seconds);
-               }
-
-               msg.setUpdateMode(updateMode);
-               msg.setCorrelationID(correlationID);
-
-               return msg;
-       }
-       
-       @Deprecated
-       public static SetMediaClockTimer buildSetMediaClockTimer(
-                       UpdateMode updateMode, Integer correlationID) {
-               Integer hours = null;
-               Integer minutes = null;
-               Integer seconds = null;
-
-               SetMediaClockTimer msg = buildSetMediaClockTimer(hours, minutes,
-                               seconds, updateMode, correlationID);
-               return msg;
-       }
-
-       public static Show buildShow(String mainText1, String mainText2,
-                       String statusBar, String mediaClock, String mediaTrack,
-                       TextAlignment alignment, Integer correlationID) {
-               Show msg = new Show();
-               msg.setCorrelationID(correlationID);
-               msg.setMainField1(mainText1);
-               msg.setMainField2(mainText2);
-               msg.setStatusBar(statusBar);
-               msg.setMediaClock(mediaClock);
-               msg.setMediaTrack(mediaTrack);
-               msg.setAlignment(alignment);
-
-               return msg;
-       }
-       
-       public static Show buildShow(String mainText1, String mainText2,
-                       TextAlignment alignment, Integer correlationID) {
-               Show msg = buildShow(mainText1, mainText2, null, null, null, alignment,
-                               correlationID);
-               return msg;
-       }
-       
-       public static Speak buildSpeak(String ttsText, Integer correlationID) {
-               Speak msg = buildSpeak(TTSChunkFactory.createSimpleTTSChunks(ttsText),
-                               correlationID);
-               return msg;
-       }
-       
-       public static Speak buildSpeak(Vector<TTSChunk> ttsChunks,
-                       Integer correlationID) {
-
-               Speak msg = new Speak();
-               msg.setCorrelationID(correlationID);
-
-               msg.setTtsChunks(ttsChunks);
-
-               return msg;
-       }
-       
-       public static SubscribeButton buildSubscribeButton(ButtonName buttonName,
-                       Integer correlationID) {
-
-               SubscribeButton msg = new SubscribeButton();
-               msg.setCorrelationID(correlationID);
-               msg.setButtonName(buttonName);
-
-               return msg;
-       }
-       
-       public static UnregisterAppInterface buildUnregisterAppInterface(
-                       Integer correlationID) {
-               UnregisterAppInterface msg = new UnregisterAppInterface();
-               msg.setCorrelationID(correlationID);
-
-               return msg;
-       }
-       
-       public static UnsubscribeButton buildUnsubscribeButton(
-                       ButtonName buttonName, Integer correlationID) {
-
-               UnsubscribeButton msg = new UnsubscribeButton();
-               msg.setCorrelationID(correlationID);
-               msg.setButtonName(buttonName);
-
-               return msg;
-       }
-}
+package com.smartdevicelink.proxy;\r
+\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.rpc.AddCommand;\r
+import com.smartdevicelink.proxy.rpc.AddSubMenu;\r
+import com.smartdevicelink.proxy.rpc.Alert;\r
+import com.smartdevicelink.proxy.rpc.AlertManeuver;\r
+import com.smartdevicelink.proxy.rpc.ChangeRegistration;\r
+import com.smartdevicelink.proxy.rpc.Choice;\r
+import com.smartdevicelink.proxy.rpc.CreateInteractionChoiceSet;\r
+import com.smartdevicelink.proxy.rpc.DeleteCommand;\r
+import com.smartdevicelink.proxy.rpc.DeleteFile;\r
+import com.smartdevicelink.proxy.rpc.DeleteInteractionChoiceSet;\r
+import com.smartdevicelink.proxy.rpc.DeleteSubMenu;\r
+import com.smartdevicelink.proxy.rpc.EncodedSyncPData;\r
+import com.smartdevicelink.proxy.rpc.EndAudioPassThru;\r
+import com.smartdevicelink.proxy.rpc.GetDTCs;\r
+import com.smartdevicelink.proxy.rpc.GetVehicleData;\r
+import com.smartdevicelink.proxy.rpc.Image;\r
+import com.smartdevicelink.proxy.rpc.ListFiles;\r
+import com.smartdevicelink.proxy.rpc.MenuParams;\r
+import com.smartdevicelink.proxy.rpc.PerformAudioPassThru;\r
+import com.smartdevicelink.proxy.rpc.PerformInteraction;\r
+import com.smartdevicelink.proxy.rpc.PutFile;\r
+import com.smartdevicelink.proxy.rpc.ReadDID;\r
+import com.smartdevicelink.proxy.rpc.RegisterAppInterface;\r
+import com.smartdevicelink.proxy.rpc.ScrollableMessage;\r
+import com.smartdevicelink.proxy.rpc.SetAppIcon;\r
+import com.smartdevicelink.proxy.rpc.SetDisplayLayout;\r
+import com.smartdevicelink.proxy.rpc.SetGlobalProperties;\r
+import com.smartdevicelink.proxy.rpc.SetMediaClockTimer;\r
+import com.smartdevicelink.proxy.rpc.Show;\r
+import com.smartdevicelink.proxy.rpc.ShowConstantTBT;\r
+import com.smartdevicelink.proxy.rpc.Slider;\r
+import com.smartdevicelink.proxy.rpc.SoftButton;\r
+import com.smartdevicelink.proxy.rpc.Speak;\r
+import com.smartdevicelink.proxy.rpc.StartTime;\r
+import com.smartdevicelink.proxy.rpc.SubscribeButton;\r
+import com.smartdevicelink.proxy.rpc.SubscribeVehicleData;\r
+import com.smartdevicelink.proxy.rpc.smartdevicelinkMsgVersion;\r
+import com.smartdevicelink.proxy.rpc.SyncPData;\r
+import com.smartdevicelink.proxy.rpc.TTSChunk;\r
+import com.smartdevicelink.proxy.rpc.Turn;\r
+import com.smartdevicelink.proxy.rpc.UnregisterAppInterface;\r
+import com.smartdevicelink.proxy.rpc.UnsubscribeButton;\r
+import com.smartdevicelink.proxy.rpc.UnsubscribeVehicleData;\r
+import com.smartdevicelink.proxy.rpc.UpdateTurnList;\r
+import com.smartdevicelink.proxy.rpc.VrHelpItem;\r
+import com.smartdevicelink.proxy.rpc.enums.AppHMIType;\r
+import com.smartdevicelink.proxy.rpc.enums.AudioType;\r
+import com.smartdevicelink.proxy.rpc.enums.BitsPerSample;\r
+import com.smartdevicelink.proxy.rpc.enums.ButtonName;\r
+import com.smartdevicelink.proxy.rpc.enums.FileType;\r
+import com.smartdevicelink.proxy.rpc.enums.ImageType;\r
+import com.smartdevicelink.proxy.rpc.enums.InteractionMode;\r
+import com.smartdevicelink.proxy.rpc.enums.Language;\r
+import com.smartdevicelink.proxy.rpc.enums.SamplingRate;\r
+import com.smartdevicelink.proxy.rpc.enums.TextAlignment;\r
+import com.smartdevicelink.proxy.rpc.enums.UpdateMode;\r
+\r
+public class RPCRequestFactory {\r
+\r
+       public static final int NGN_MEDIA_SCREEN_APP_NAME_MAX_LENGTH = 5;\r
+       public static final int SMARTDEVICELINK_MSG_MAJOR_VERSION = 1;\r
+       public static final int SMARTDEVICELINK_MSG_MINOR_VERSION = 0;\r
+\r
+       public static EncodedSyncPData buildEncodedSyncPData(\r
+                       Vector<String> data, Integer correlationID) {\r
+               \r
+               if(data == null) return null;\r
+               \r
+               EncodedSyncPData msg = new EncodedSyncPData();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setData(data);\r
+               return msg;\r
+       }\r
+       \r
+       public static SyncPData buildSyncPData(\r
+                       byte[] data, Integer correlationID) {\r
+               \r
+               if(data == null) return null;\r
+               \r
+               SyncPData msg = new SyncPData();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setSyncPData(data);\r
+               return msg;\r
+       }\r
+               \r
+\r
+       public static AddCommand buildAddCommand(Integer commandID,\r
+                       String menuText, Integer parentID, Integer position,\r
+                       Vector<String> vrCommands, Image cmdIcon, Integer correlationID) {\r
+               AddCommand msg = new AddCommand();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setCmdID(commandID);\r
+               msg.setVrCommands(vrCommands);\r
+               \r
+               if (cmdIcon != null) msg.setCmdIcon(cmdIcon);\r
+               \r
+               if(menuText != null || parentID != null || position != null) {\r
+                       MenuParams menuParams = new MenuParams();\r
+                       menuParams.setMenuName(menuText);\r
+                       menuParams.setPosition(position);\r
+                       menuParams.setParentID(parentID);\r
+                       msg.setMenuParams(menuParams);\r
+               }\r
+               \r
+               return msg;\r
+       }\r
+       \r
+       public static AddCommand buildAddCommand(Integer commandID,\r
+                       String menuText, Integer parentID, Integer position,\r
+                       Vector<String> vrCommands, String IconValue, ImageType IconType, Integer correlationID) {\r
+               AddCommand msg = new AddCommand();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setCmdID(commandID);\r
+               \r
+               if (vrCommands != null) msg.setVrCommands(vrCommands);\r
+               \r
+               Image cmdIcon = null;\r
+               \r
+               if (IconValue != null && IconType != null)\r
+               {\r
+                       cmdIcon = new Image();\r
+                       cmdIcon.setValue(IconValue);                    \r
+                       cmdIcon.setImageType(IconType);                 \r
+               }                               \r
+               \r
+               if (cmdIcon != null) msg.setCmdIcon(cmdIcon);\r
+               \r
+               if(menuText != null || parentID != null || position != null) {\r
+                       MenuParams menuParams = new MenuParams();\r
+                       menuParams.setMenuName(menuText);\r
+                       menuParams.setPosition(position);\r
+                       menuParams.setParentID(parentID);\r
+                       msg.setMenuParams(menuParams);\r
+               }\r
+               \r
+               return msg;\r
+       }\r
+\r
+               \r
+       public static AddCommand buildAddCommand(Integer commandID,\r
+                       String menuText, Integer parentID, Integer position,\r
+                       Vector<String> vrCommands, Integer correlationID) {\r
+               AddCommand msg = new AddCommand();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setCmdID(commandID);\r
+               msg.setVrCommands(vrCommands);\r
+               \r
+               if(menuText != null || parentID != null || position != null) {\r
+                       MenuParams menuParams = new MenuParams();\r
+                       menuParams.setMenuName(menuText);\r
+                       menuParams.setPosition(position);\r
+                       menuParams.setParentID(parentID);\r
+                       msg.setMenuParams(menuParams);\r
+               }\r
+               \r
+               return msg;\r
+       }\r
+       \r
+       public static AddCommand buildAddCommand(Integer commandID,\r
+                       String menuText, Vector<String> vrCommands, Integer correlationID) {\r
+               AddCommand msg = buildAddCommand(commandID, menuText, null, null,\r
+                               vrCommands, correlationID);\r
+               return msg;\r
+       }\r
+       \r
+       public static AddCommand buildAddCommand(Integer commandID,\r
+                       Vector<String> vrCommands, Integer correlationID) {\r
+               AddCommand msg = new AddCommand();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setCmdID(commandID);\r
+               msg.setVrCommands(vrCommands);\r
+\r
+               return msg;\r
+       }\r
+\r
+       public static AddSubMenu buildAddSubMenu(Integer menuID, String menuName,\r
+                       Integer correlationID) {\r
+               AddSubMenu msg = buildAddSubMenu(menuID, menuName, null, correlationID);\r
+               return msg;\r
+       }\r
+\r
+       public static AddSubMenu buildAddSubMenu(Integer menuID, String menuName,\r
+                       Integer position, Integer correlationID) {\r
+               AddSubMenu msg = new AddSubMenu();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setMenuName(menuName);\r
+               msg.setMenuID(menuID);\r
+               msg.setPosition(position);\r
+\r
+               return msg;\r
+       }\r
+       \r
+\r
+       public static Alert buildAlert(String ttsText, Boolean playTone, Vector<SoftButton> softButtons,\r
+                       Integer correlationID) {\r
+               Vector<TTSChunk> chunks = TTSChunkFactory\r
+                               .createSimpleTTSChunks(ttsText);\r
+               Alert msg = buildAlert(chunks, null, null, null, playTone, null, softButtons,\r
+                               correlationID);\r
+               return msg;\r
+       }\r
+       \r
+       public static Alert buildAlert(String alertText1, String alertText2, String alertText3,\r
+                       Integer duration, Vector<SoftButton> softButtons, Integer correlationID) {\r
+               Alert msg = buildAlert((Vector<TTSChunk>) null, alertText1, alertText2, alertText3,\r
+                               null, duration, softButtons, correlationID);\r
+               return msg;\r
+       }\r
+       \r
+       public static Alert buildAlert(String ttsText, String alertText1,\r
+                       String alertText2, String alertText3, Boolean playTone, Integer duration, Vector<SoftButton> softButtons,\r
+                       Integer correlationID) {\r
+               Vector<TTSChunk> chunks = TTSChunkFactory\r
+                               .createSimpleTTSChunks(ttsText);\r
+               Alert msg = buildAlert(chunks, alertText1, alertText2, alertText3, playTone, \r
+                               duration, softButtons, correlationID);\r
+               return msg;\r
+       }\r
+       \r
+       public static Alert buildAlert(Vector<TTSChunk> chunks, Boolean playTone, Vector<SoftButton> softButtons,\r
+                       Integer correlationID) {\r
+               Alert msg = buildAlert(chunks, null, null, null, playTone, null, softButtons, correlationID);\r
+               return msg;\r
+       }\r
+       \r
+       public static Alert buildAlert(Vector<TTSChunk> ttsChunks,\r
+                       String alertText1, String alertText2, String alertText3, Boolean playTone,\r
+                       Integer duration, Vector<SoftButton> softButtons, Integer correlationID) {\r
+               Alert msg = new Alert();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setAlertText1(alertText1);\r
+               msg.setAlertText2(alertText2);\r
+               msg.setDuration(duration);\r
+               msg.setPlayTone(playTone);\r
+               msg.setTtsChunks(ttsChunks);\r
+               msg.setSoftButtons(softButtons);\r
+\r
+               return msg;\r
+       }\r
+\r
+       \r
+       \r
+       public static Alert buildAlert(String ttsText, Boolean playTone,\r
+                       Integer correlationID) {\r
+               Vector<TTSChunk> chunks = TTSChunkFactory\r
+                               .createSimpleTTSChunks(ttsText);\r
+               Alert msg = buildAlert(chunks, null, null, playTone, null,\r
+                               correlationID);\r
+               return msg;\r
+       }\r
+       \r
+       public static Alert buildAlert(String alertText1, String alertText2,\r
+                       Integer duration, Integer correlationID) {\r
+               Alert msg = buildAlert((Vector<TTSChunk>) null, alertText1, alertText2,\r
+                               null, duration, correlationID);\r
+               return msg;\r
+       }\r
+       \r
+       public static Alert buildAlert(String ttsText, String alertText1,\r
+                       String alertText2, Boolean playTone, Integer duration,\r
+                       Integer correlationID) {\r
+               Vector<TTSChunk> chunks = TTSChunkFactory\r
+                               .createSimpleTTSChunks(ttsText);\r
+               Alert msg = buildAlert(chunks, alertText1, alertText2, playTone,\r
+                               duration, correlationID);\r
+               return msg;\r
+       }\r
+       \r
+       public static Alert buildAlert(Vector<TTSChunk> chunks, Boolean playTone,\r
+                       Integer correlationID) {\r
+               Alert msg = buildAlert(chunks, null, null, playTone, null,\r
+                               correlationID);\r
+               return msg;\r
+       }\r
+       \r
+       public static Alert buildAlert(Vector<TTSChunk> ttsChunks,\r
+                       String alertText1, String alertText2, Boolean playTone,\r
+                       Integer duration, Integer correlationID) {\r
+               Alert msg = new Alert();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setAlertText1(alertText1);\r
+               msg.setAlertText2(alertText2);\r
+               msg.setDuration(duration);\r
+               msg.setPlayTone(playTone);\r
+               msg.setTtsChunks(ttsChunks);\r
+\r
+               return msg;\r
+       }\r
+       \r
+       public static CreateInteractionChoiceSet buildCreateInteractionChoiceSet(\r
+                       Vector<Choice> choiceSet, Integer interactionChoiceSetID,\r
+                       Integer correlationID) {\r
+               CreateInteractionChoiceSet msg = new CreateInteractionChoiceSet();\r
+               msg.setChoiceSet(choiceSet);\r
+               msg.setInteractionChoiceSetID(interactionChoiceSetID);\r
+               msg.setCorrelationID(correlationID);\r
+               return msg;\r
+       }\r
+       \r
+       public static DeleteCommand buildDeleteCommand(Integer commandID,\r
+                       Integer correlationID) {\r
+               DeleteCommand msg = new DeleteCommand();\r
+               msg.setCmdID(commandID);\r
+               msg.setCorrelationID(correlationID);\r
+               return msg;\r
+       }\r
+       \r
+       public static DeleteFile buildDeleteFile(String smartDeviceLinkFileName,\r
+                       Integer correlationID) {\r
+               DeleteFile deleteFile = new DeleteFile();\r
+               deleteFile.setCorrelationID(correlationID);\r
+               deleteFile.setSmartDeviceLinkFileName(smartDeviceLinkFileName);\r
+               return deleteFile;\r
+       }\r
+       \r
+       public static DeleteInteractionChoiceSet buildDeleteInteractionChoiceSet(\r
+                       Integer interactionChoiceSetID, Integer correlationID) {\r
+               DeleteInteractionChoiceSet msg = new DeleteInteractionChoiceSet();\r
+               msg.setInteractionChoiceSetID(interactionChoiceSetID);\r
+               msg.setCorrelationID(correlationID);\r
+\r
+               return msg;\r
+       }\r
+       \r
+       public static DeleteSubMenu buildDeleteSubMenu(Integer menuID,\r
+                       Integer correlationID) {\r
+               DeleteSubMenu msg = new DeleteSubMenu();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setMenuID(menuID);\r
+\r
+               return msg;\r
+       }\r
+       \r
+       public static ListFiles buildListFiles(Integer correlationID) {\r
+               ListFiles listFiles = new ListFiles();\r
+               listFiles.setCorrelationID(correlationID);\r
+               return listFiles;\r
+       }\r
+\r
+       \r
+       public static PerformInteraction buildPerformInteraction(\r
+                       Vector<TTSChunk> initChunks, String displayText,\r
+                       Vector<Integer> interactionChoiceSetIDList,\r
+                       Vector<TTSChunk> helpChunks, Vector<TTSChunk> timeoutChunks,\r
+                       InteractionMode interactionMode, Integer timeout, Vector<VrHelpItem> vrHelp,\r
+                       Integer correlationID) {\r
+               PerformInteraction msg = new PerformInteraction();\r
+               msg.setInitialPrompt(initChunks);\r
+               msg.setInitialText(displayText);\r
+               msg.setInteractionChoiceSetIDList(interactionChoiceSetIDList);\r
+               msg.setInteractionMode(interactionMode);\r
+               msg.setTimeout(timeout);\r
+               msg.setHelpPrompt(helpChunks);\r
+               msg.setTimeoutPrompt(timeoutChunks);\r
+               msg.setVrHelp(vrHelp);\r
+               msg.setCorrelationID(correlationID);\r
+               \r
+               return msg;\r
+       }\r
+\r
+       public static PerformInteraction buildPerformInteraction(\r
+                       String initPrompt,      String displayText, \r
+                       Vector<Integer> interactionChoiceSetIDList,\r
+                       String helpPrompt, String timeoutPrompt,\r
+                       InteractionMode interactionMode, Integer timeout, Vector<VrHelpItem> vrHelp,\r
+                       Integer correlationID) {\r
+               Vector<TTSChunk> initChunks = TTSChunkFactory\r
+                               .createSimpleTTSChunks(initPrompt);\r
+               Vector<TTSChunk> helpChunks = TTSChunkFactory\r
+                               .createSimpleTTSChunks(helpPrompt);\r
+               Vector<TTSChunk> timeoutChunks = TTSChunkFactory\r
+                               .createSimpleTTSChunks(timeoutPrompt);\r
+               return buildPerformInteraction(initChunks,\r
+                               displayText, interactionChoiceSetIDList, helpChunks,\r
+                               timeoutChunks, interactionMode, timeout, vrHelp, correlationID);\r
+       }\r
+       \r
+       public static PerformInteraction buildPerformInteraction(\r
+                       String initPrompt,      String displayText, \r
+                       Integer interactionChoiceSetID,\r
+                       String helpPrompt, String timeoutPrompt,\r
+                       InteractionMode interactionMode, Integer timeout, Vector<VrHelpItem> vrHelp,\r
+                       Integer correlationID) {\r
+               Vector<Integer> interactionChoiceSetIDs = new Vector<Integer>();\r
+                       interactionChoiceSetIDs.add(interactionChoiceSetID);\r
+               \r
+               return buildPerformInteraction(\r
+                               initPrompt, displayText, interactionChoiceSetIDs, \r
+                               helpPrompt, timeoutPrompt, interactionMode, \r
+                               timeout, vrHelp, correlationID);\r
+       }\r
+       \r
+       public static PerformInteraction buildPerformInteraction(String initPrompt,\r
+                       String displayText, Integer interactionChoiceSetID, Vector<VrHelpItem> vrHelp,\r
+                       Integer correlationID) {\r
+\r
+               return buildPerformInteraction(initPrompt, displayText, \r
+                               interactionChoiceSetID, null, null,\r
+                               InteractionMode.BOTH, null, vrHelp, correlationID);\r
+       }\r
+       \r
+       \r
+       public static PerformInteraction buildPerformInteraction(\r
+                       Vector<TTSChunk> initChunks, String displayText,\r
+                       Vector<Integer> interactionChoiceSetIDList,\r
+                       Vector<TTSChunk> helpChunks, Vector<TTSChunk> timeoutChunks,\r
+                       InteractionMode interactionMode, Integer timeout,\r
+                       Integer correlationID) {\r
+               PerformInteraction msg = new PerformInteraction();\r
+               msg.setInitialPrompt(initChunks);\r
+               msg.setInitialText(displayText);\r
+               msg.setInteractionChoiceSetIDList(interactionChoiceSetIDList);\r
+               msg.setInteractionMode(interactionMode);\r
+               msg.setTimeout(timeout);\r
+               msg.setHelpPrompt(helpChunks);\r
+               msg.setTimeoutPrompt(timeoutChunks);\r
+               msg.setCorrelationID(correlationID);\r
+               \r
+               return msg;\r
+       }\r
+\r
+       public static PerformInteraction buildPerformInteraction(\r
+                       String initPrompt,      String displayText, \r
+                       Vector<Integer> interactionChoiceSetIDList,\r
+                       String helpPrompt, String timeoutPrompt,\r
+                       InteractionMode interactionMode, Integer timeout,\r
+                       Integer correlationID) {\r
+               Vector<TTSChunk> initChunks = TTSChunkFactory\r
+                               .createSimpleTTSChunks(initPrompt);\r
+               Vector<TTSChunk> helpChunks = TTSChunkFactory\r
+                               .createSimpleTTSChunks(helpPrompt);\r
+               Vector<TTSChunk> timeoutChunks = TTSChunkFactory\r
+                               .createSimpleTTSChunks(timeoutPrompt);\r
+               return buildPerformInteraction(initChunks,\r
+                               displayText, interactionChoiceSetIDList, helpChunks,\r
+                               timeoutChunks, interactionMode, timeout, correlationID);\r
+       }\r
+       \r
+       public static PerformInteraction buildPerformInteraction(\r
+                       String initPrompt,      String displayText, \r
+                       Integer interactionChoiceSetID,\r
+                       String helpPrompt, String timeoutPrompt,\r
+                       InteractionMode interactionMode, Integer timeout,\r
+                       Integer correlationID) {\r
+               Vector<Integer> interactionChoiceSetIDs = new Vector<Integer>();\r
+                       interactionChoiceSetIDs.add(interactionChoiceSetID);\r
+               \r
+               return buildPerformInteraction(\r
+                               initPrompt, displayText, interactionChoiceSetIDs, \r
+                               helpPrompt, timeoutPrompt, interactionMode, \r
+                               timeout, correlationID);\r
+       }\r
+       \r
+       public static PerformInteraction buildPerformInteraction(String initPrompt,\r
+                       String displayText, Integer interactionChoiceSetID,\r
+                       Integer correlationID) {\r
+\r
+               return buildPerformInteraction(initPrompt, displayText, \r
+                               interactionChoiceSetID, null, null,\r
+                               InteractionMode.BOTH, null, correlationID);\r
+       }\r
+       \r
+       @Deprecated\r
+       public static PerformInteraction buildPerformInteraction(\r
+                       Vector<TTSChunk> initChunks, String displayText,\r
+                       Vector<Integer> interactionChoiceSetIDList,\r
+                       Vector<TTSChunk> helpChunks, InteractionMode interactionMode,\r
+                       Integer timeout, Integer correlationID) {\r
+               PerformInteraction msg = new PerformInteraction();\r
+               msg.setInitialPrompt(initChunks);\r
+               msg.setInitialText(displayText);\r
+               msg.setInteractionChoiceSetIDList(interactionChoiceSetIDList);\r
+               msg.setInteractionMode(interactionMode);\r
+               msg.setTimeout(timeout);\r
+               msg.setHelpPrompt(helpChunks);\r
+               msg.setCorrelationID(correlationID);\r
+               return msg;\r
+       }\r
+       \r
+       @Deprecated\r
+       public static PerformInteraction buildPerformInteraction(String initPrompt,\r
+                       String displayText, Vector<Integer> interactionChoiceSetIDList,\r
+                       String helpPrompt, InteractionMode interactionMode,\r
+                       Integer timeout, Integer correlationID) {\r
+               Vector<TTSChunk> initChunks = TTSChunkFactory\r
+                               .createSimpleTTSChunks(initPrompt);\r
+               Vector<TTSChunk> helpChunks = TTSChunkFactory\r
+                               .createSimpleTTSChunks(helpPrompt);\r
+               PerformInteraction msg = buildPerformInteraction(initChunks,\r
+                               displayText, interactionChoiceSetIDList, helpChunks,\r
+                               interactionMode, timeout, correlationID);\r
+               return msg;\r
+       }\r
+       \r
+       public static PutFile buildPutFile(String smartDeviceLinkFileName, FileType fileType,\r
+                       Boolean persistentFile, byte[] fileData, Integer correlationID) {\r
+               PutFile putFile = new PutFile();\r
+               putFile.setCorrelationID(correlationID);\r
+               putFile.setSmartDeviceLinkFileName(smartDeviceLinkFileName);\r
+               putFile.setFileType(fileType);\r
+               putFile.setPersistentFile(persistentFile);\r
+               putFile.setBulkData(fileData);\r
+               return putFile;\r
+       }\r
+               \r
+       public static RegisterAppInterface buildRegisterAppInterface(String appName, String appID) {\r
+               return buildRegisterAppInterface(appName, false, appID);\r
+       }\r
+               \r
+       public static RegisterAppInterface buildRegisterAppInterface(\r
+                       String appName, Boolean isMediaApp, String appID) {\r
+               \r
+               return buildRegisterAppInterface(null, appName, null, null, null, isMediaApp, \r
+                               null, null, null, appID, null); \r
+       }       \r
+               \r
+       public static RegisterAppInterface buildRegisterAppInterface(\r
+                       smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, String appName, Vector<TTSChunk> ttsName, \r
+                       String ngnMediaScreenAppName, Vector<String> vrSynonyms, Boolean isMediaApp, \r
+                       Language languageDesired, Language hmiDisplayLanguageDesired, Vector<AppHMIType> appType,\r
+                       String appID, Integer correlationID) {\r
+               RegisterAppInterface msg = new RegisterAppInterface();\r
+               \r
+               if (correlationID == null) {\r
+                       correlationID = 1;\r
+               }\r
+               msg.setCorrelationID(correlationID);\r
+               \r
+               if (smartDeviceLinkMsgVersion == null) {\r
+                       smartDeviceLinkMsgVersion = new smartdevicelinkMsgVersion();\r
+                       smartDeviceLinkMsgVersion.setMajorVersion(new Integer(SMARTDEVICELINK_MSG_MAJOR_VERSION));\r
+                       smartDeviceLinkMsgVersion.setMinorVersion(new Integer(SMARTDEVICELINK_MSG_MINOR_VERSION));\r
+               } \r
+               msg.setsmartdevicelinkMsgVersion(smartDeviceLinkMsgVersion);\r
+               \r
+               msg.setAppName(appName);\r
+               \r
+               msg.setTtsName(ttsName);\r
+               \r
+               if (ngnMediaScreenAppName == null) {\r
+                       ngnMediaScreenAppName = appName;\r
+               }\r
+               \r
+               if (ngnMediaScreenAppName.length() > NGN_MEDIA_SCREEN_APP_NAME_MAX_LENGTH) {\r
+                       ngnMediaScreenAppName = ngnMediaScreenAppName.substring(0,\r
+                                       NGN_MEDIA_SCREEN_APP_NAME_MAX_LENGTH);\r
+               }\r
+               msg.setNgnMediaScreenAppName(ngnMediaScreenAppName);\r
+               \r
+               if (vrSynonyms == null) {\r
+                       vrSynonyms = new Vector<String>();\r
+                       vrSynonyms.add(appName);\r
+               }\r
+               msg.setVrSynonyms(vrSynonyms);\r
+               \r
+               msg.setIsMediaApplication(isMediaApp);\r
+               \r
+               if (languageDesired == null) {\r
+                       languageDesired = Language.EN_US;\r
+               }\r
+               msg.setLanguageDesired(languageDesired);\r
+               \r
+               if (hmiDisplayLanguageDesired == null) {\r
+                       hmiDisplayLanguageDesired = Language.EN_US;\r
+               }               \r
+               \r
+               msg.setHmiDisplayLanguageDesired(hmiDisplayLanguageDesired);\r
+               \r
+               msg.setAppHMIType(appType);\r
+               \r
+               msg.setAppID(appID);\r
+\r
+               return msg;\r
+       }\r
+       \r
+       public static SetAppIcon buildSetAppIcon(String smartDeviceLinkFileName,\r
+                       Integer correlationID) {\r
+               SetAppIcon setAppIcon = new SetAppIcon();\r
+               setAppIcon.setCorrelationID(correlationID);\r
+               setAppIcon.setSmartDeviceLinkFileName(smartDeviceLinkFileName);\r
+               return setAppIcon;\r
+       }\r
+       \r
+       public static SetGlobalProperties buildSetGlobalProperties(\r
+                       String helpPrompt, String timeoutPrompt, Integer correlationID) {\r
+               return buildSetGlobalProperties(TTSChunkFactory\r
+                               .createSimpleTTSChunks(helpPrompt), TTSChunkFactory\r
+                               .createSimpleTTSChunks(timeoutPrompt), correlationID);\r
+       }\r
+       \r
+       public static SetGlobalProperties buildSetGlobalProperties(\r
+                       Vector<TTSChunk> helpChunks, Vector<TTSChunk> timeoutChunks,\r
+                       Integer correlationID) {\r
+               SetGlobalProperties req = new SetGlobalProperties();\r
+               req.setCorrelationID(correlationID);\r
+\r
+               req.setHelpPrompt(helpChunks);\r
+               req.setTimeoutPrompt(timeoutChunks);\r
+\r
+               return req;\r
+       }\r
+\r
+       \r
+       public static SetGlobalProperties buildSetGlobalProperties(\r
+                       String helpPrompt, String timeoutPrompt, String vrHelpTitle, \r
+                       Vector<VrHelpItem> vrHelp, Integer correlationID) {\r
+               return buildSetGlobalProperties(TTSChunkFactory\r
+                               .createSimpleTTSChunks(helpPrompt), TTSChunkFactory\r
+                               .createSimpleTTSChunks(timeoutPrompt), vrHelpTitle, vrHelp, correlationID);\r
+       }\r
+\r
+\r
+       public static SetGlobalProperties buildSetGlobalProperties(\r
+                       Vector<TTSChunk> helpChunks, Vector<TTSChunk> timeoutChunks, \r
+                       String vrHelpTitle, Vector<VrHelpItem> vrHelp,\r
+                       Integer correlationID) {\r
+               SetGlobalProperties req = new SetGlobalProperties();\r
+               req.setCorrelationID(correlationID);\r
+\r
+               req.setHelpPrompt(helpChunks);\r
+               req.setTimeoutPrompt(timeoutChunks);\r
+               \r
+               req.setVrHelpTitle(vrHelpTitle);                \r
+               req.setVrHelp(vrHelp);\r
+\r
+               return req;\r
+       }\r
+       \r
+       \r
+       \r
+\r
+       public static SetMediaClockTimer buildSetMediaClockTimer(Integer hours,\r
+                       Integer minutes, Integer seconds, UpdateMode updateMode,\r
+                       Integer correlationID) {\r
+\r
+               SetMediaClockTimer msg = new SetMediaClockTimer();\r
+               if (hours != null || minutes != null || seconds != null) {\r
+                       StartTime startTime = new StartTime();\r
+                       msg.setStartTime(startTime);\r
+                       startTime.setHours(hours);\r
+                       startTime.setMinutes(minutes);\r
+                       startTime.setSeconds(seconds);\r
+               }\r
+\r
+               msg.setUpdateMode(updateMode);\r
+               msg.setCorrelationID(correlationID);\r
+\r
+               return msg;\r
+       }\r
+       \r
+       @Deprecated\r
+       public static SetMediaClockTimer buildSetMediaClockTimer(\r
+                       UpdateMode updateMode, Integer correlationID) {\r
+               Integer hours = null;\r
+               Integer minutes = null;\r
+               Integer seconds = null;\r
+\r
+               SetMediaClockTimer msg = buildSetMediaClockTimer(hours, minutes,\r
+                               seconds, updateMode, correlationID);\r
+               return msg;\r
+       }\r
+       \r
+       public static Show buildShow(String mainText1, String mainText2,\r
+                       String mainText3, String mainText4,\r
+                       String statusBar, String mediaClock, String mediaTrack,\r
+                       Image graphic, Vector<SoftButton> softButtons, Vector <String> customPresets,\r
+                       TextAlignment alignment, Integer correlationID) {\r
+               Show msg = new Show();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setMainField1(mainText1);\r
+               msg.setMainField2(mainText2);\r
+               msg.setStatusBar(statusBar);\r
+               msg.setMediaClock(mediaClock);\r
+               msg.setMediaTrack(mediaTrack);\r
+               msg.setAlignment(alignment);\r
+               msg.setMainField3(mainText3);\r
+               msg.setMainField4(mainText4);\r
+               msg.setGraphic(graphic);\r
+               msg.setSoftButtons(softButtons);\r
+               msg.setCustomPresets(customPresets);            \r
+\r
+               return msg;\r
+       }\r
+       \r
+       public static Show buildShow(String mainText1, String mainText2, String mainText3, String mainText4,\r
+                       TextAlignment alignment, Integer correlationID) {\r
+               Show msg = buildShow(mainText1, mainText2, mainText3, mainText4, null, null, null, null, null, null, alignment,\r
+                               correlationID);\r
+               return msg;\r
+       }\r
+               \r
+       public static Show buildShow(String mainText1, String mainText2,\r
+                       String statusBar, String mediaClock, String mediaTrack,\r
+                       TextAlignment alignment, Integer correlationID) {\r
+               Show msg = new Show();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setMainField1(mainText1);\r
+               msg.setMainField2(mainText2);\r
+               msg.setStatusBar(statusBar);\r
+               msg.setMediaClock(mediaClock);\r
+               msg.setMediaTrack(mediaTrack);\r
+               msg.setAlignment(alignment);\r
+\r
+               return msg;\r
+       }\r
+       \r
+       public static Show buildShow(String mainText1, String mainText2,\r
+                       TextAlignment alignment, Integer correlationID) {\r
+               Show msg = buildShow(mainText1, mainText2, null, null, null, alignment,\r
+                               correlationID);\r
+               return msg;\r
+       }\r
+       \r
+       public static Speak buildSpeak(String ttsText, Integer correlationID) {\r
+               Speak msg = buildSpeak(TTSChunkFactory.createSimpleTTSChunks(ttsText),\r
+                               correlationID);\r
+               return msg;\r
+       }\r
+       \r
+       public static Speak buildSpeak(Vector<TTSChunk> ttsChunks,\r
+                       Integer correlationID) {\r
+\r
+               Speak msg = new Speak();\r
+               msg.setCorrelationID(correlationID);\r
+\r
+               msg.setTtsChunks(ttsChunks);\r
+\r
+               return msg;\r
+       }\r
+       \r
+       public static SubscribeButton buildSubscribeButton(ButtonName buttonName,\r
+                       Integer correlationID) {\r
+\r
+               SubscribeButton msg = new SubscribeButton();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setButtonName(buttonName);\r
+\r
+               return msg;\r
+       }\r
+       \r
+       public static UnregisterAppInterface buildUnregisterAppInterface(\r
+                       Integer correlationID) {\r
+               UnregisterAppInterface msg = new UnregisterAppInterface();\r
+               msg.setCorrelationID(correlationID);\r
+\r
+               return msg;\r
+       }\r
+       \r
+       public static UnsubscribeButton buildUnsubscribeButton(\r
+                       ButtonName buttonName, Integer correlationID) {\r
+\r
+               UnsubscribeButton msg = new UnsubscribeButton();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setButtonName(buttonName);\r
+\r
+               return msg;\r
+       }       \r
+       \r
+       public static SubscribeVehicleData BuildSubscribeVehicleData(boolean gps, boolean speed, boolean rpm, boolean fuelLevel, boolean fuelLevel_State,\r
+                                                                                                                                boolean instantFuelConsumption, boolean externalTemperature, boolean prndl, boolean tirePressure,\r
+                                                                                                                                boolean odometer, boolean beltStatus, boolean bodyInformation, boolean deviceStatus,\r
+                                                                                                                                boolean driverBraking, Integer correlationID) \r
+       {\r
+               SubscribeVehicleData msg = new SubscribeVehicleData();\r
+               msg.setGps(gps);\r
+               msg.setSpeed(speed);\r
+               msg.setRpm(rpm);\r
+               msg.setFuelLevel(fuelLevel);\r
+               msg.setFuelLevel_State(fuelLevel_State);\r
+               msg.setInstantFuelConsumption(instantFuelConsumption);\r
+               msg.setExternalTemperature(externalTemperature);\r
+               msg.setPrndl(prndl);\r
+               msg.setTirePressure(tirePressure);\r
+               msg.setOdometer(odometer);\r
+               msg.setBeltStatus(beltStatus);\r
+               msg.setBodyInformation(bodyInformation);\r
+               msg.setDeviceStatus(deviceStatus);\r
+               msg.setDriverBraking(driverBraking);\r
+               msg.setCorrelationID(correlationID);\r
+               \r
+               return msg;\r
+       }\r
+\r
+       public static UnsubscribeVehicleData BuildUnsubscribeVehicleData(boolean gps, boolean speed, boolean rpm, boolean fuelLevel, boolean fuelLevel_State,\r
+                                                                                                                                        boolean instantFuelConsumption, boolean externalTemperature, boolean prndl, boolean tirePressure,\r
+                                                                                                                                        boolean odometer, boolean beltStatus, boolean bodyInformation, boolean deviceStatus,\r
+                                                                                                                                        boolean driverBraking, Integer correlationID) \r
+       {\r
+               UnsubscribeVehicleData msg = new UnsubscribeVehicleData();\r
+               msg.setGps(gps);\r
+               msg.setSpeed(speed);\r
+               msg.setRpm(rpm);\r
+               msg.setFuelLevel(fuelLevel);\r
+               msg.setFuelLevel_State(fuelLevel_State);\r
+               msg.setInstantFuelConsumption(instantFuelConsumption);\r
+               msg.setExternalTemperature(externalTemperature);\r
+               msg.setPrndl(prndl);\r
+               msg.setTirePressure(tirePressure);\r
+               msg.setOdometer(odometer);\r
+               msg.setBeltStatus(beltStatus);\r
+               msg.setBodyInformation(bodyInformation);\r
+               msg.setDeviceStatus(deviceStatus);\r
+               msg.setDriverBraking(driverBraking);\r
+               msg.setCorrelationID(correlationID);\r
+               \r
+               return msg;             \r
+       }\r
+       \r
+       public static GetVehicleData BuildGetVehicleData(boolean gps, boolean speed, boolean rpm, boolean fuelLevel, boolean fuelLevel_State,\r
+                        boolean instantFuelConsumption, boolean externalTemperature, boolean vin, boolean prndl, boolean tirePressure,\r
+                        boolean odometer, boolean beltStatus, boolean bodyInformation, boolean deviceStatus,\r
+                        boolean driverBraking, Integer correlationID)\r
+       {\r
+               GetVehicleData msg = new GetVehicleData();\r
+               msg.setGps(gps);\r
+               msg.setSpeed(speed);\r
+               msg.setRpm(rpm);\r
+               msg.setFuelLevel(fuelLevel);\r
+               msg.setFuelLevel_State(fuelLevel_State);\r
+               msg.setInstantFuelConsumption(instantFuelConsumption);\r
+               msg.setExternalTemperature(externalTemperature);\r
+               msg.setVin(vin);\r
+               msg.setPrndl(prndl);\r
+               msg.setTirePressure(tirePressure);\r
+               msg.setOdometer(odometer);\r
+               msg.setBeltStatus(beltStatus);\r
+               msg.setBodyInformation(bodyInformation);\r
+               msg.setDeviceStatus(deviceStatus);\r
+               msg.setDriverBraking(driverBraking);\r
+               msg.setCorrelationID(correlationID);\r
+               \r
+               \r
+               return msg;\r
+       }\r
+       \r
+       public static ReadDID BuildReadDID(Integer ecuName, Vector<Integer> didLocation, Integer correlationID)\r
+       {\r
+               ReadDID msg = new ReadDID();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setEcuName(ecuName);\r
+               msg.setDidLocation(didLocation);                \r
+               return msg;\r
+       }\r
+       \r
+       public static GetDTCs BuildGetDTCs(Integer ecuName, Integer correlationID)\r
+       {\r
+               GetDTCs msg = new GetDTCs();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setEcuName(ecuName);\r
+               \r
+               return msg;\r
+       }\r
+       \r
+       public static ScrollableMessage BuildScrollableMessage(String scrollableMessageBody, Integer timeout, Vector<SoftButton> softButtons, Integer correlationID)    \r
+       {\r
+               ScrollableMessage msg = new ScrollableMessage();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setScrollableMessageBody(scrollableMessageBody);\r
+               msg.setTimeout(timeout);\r
+               msg.setSoftButtons(softButtons);\r
+               \r
+               return msg;             \r
+       }\r
+       \r
+       public static Slider BuildSlider(Integer numTicks, Integer position, String sliderHeader, Vector<String> sliderFooter, Integer timeout, Integer correlationID)\r
+       {\r
+               Slider msg = new Slider();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setNumTicks(numTicks);\r
+               msg.setPosition(position);\r
+               msg.setSliderHeader(sliderHeader);\r
+               msg.setSliderFooter(sliderFooter);\r
+               msg.setTimeout(timeout);\r
+               \r
+               return msg;\r
+       }\r
+       \r
+       public static ShowConstantTBT BuildShowConstantTBT(String navigationText1, String navigationText2, String eta, \r
+                                                                                                          String totalDistance, Image turnIcon, Double distanceToManeuver,\r
+                                                                                                          Double distanceToManeuverScale, boolean maneuverComplete,\r
+                                                                                                          Vector <SoftButton> softButtons, Integer correlationID)\r
+       {\r
+               ShowConstantTBT msg = new ShowConstantTBT();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setNavigationText1(navigationText1);\r
+               msg.setNavigationText2(navigationText2);\r
+               msg.setEta(eta);\r
+               msg.setTotalDistance(totalDistance);\r
+               msg.setTurnIcon(turnIcon);\r
+               msg.setDistanceToManeuver(distanceToManeuverScale);\r
+               msg.setDistanceToManeuverScale(distanceToManeuverScale);\r
+               msg.setManeuverComplete(maneuverComplete);\r
+               msg.setSoftButtons(softButtons);\r
+               \r
+               return msg;\r
+       }\r
+       \r
+       public static AlertManeuver BuildAlertManeuver(String ttsText, Vector<SoftButton> softButtons, Integer correlationID)\r
+       {\r
+               Vector<TTSChunk> ttsChunks = TTSChunkFactory\r
+                               .createSimpleTTSChunks(ttsText);\r
+\r
+               AlertManeuver msg = BuildAlertManeuver(ttsChunks, softButtons, correlationID);\r
+               \r
+               return msg;\r
+       }\r
+       \r
+       public static AlertManeuver BuildAlertManeuver(Vector<TTSChunk> ttsChunks, Vector<SoftButton> softButtons, Integer correlationID)\r
+       {\r
+               AlertManeuver msg = new AlertManeuver();                \r
+               msg.setCorrelationID(correlationID);\r
+               msg.setTtsChunks(ttsChunks);\r
+               msg.setSoftButtons(softButtons);                        \r
+               \r
+               return msg;     \r
+       }       \r
+       \r
+       public static UpdateTurnList BuildUpdateTurnList(Vector<Turn> turnList, Vector<SoftButton> softButtons, Integer correlationID)  \r
+       {\r
+               UpdateTurnList msg = new UpdateTurnList();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setTurnList(turnList);\r
+               msg.setSoftButtons(softButtons);                \r
+               \r
+               return msg;\r
+       }\r
+       \r
+       public static ChangeRegistration BuildChangeRegistration(Language language, Language hmiDisplayLanguage, Integer correlationID)\r
+       {\r
+               ChangeRegistration msg = new ChangeRegistration();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setLanguage(language);\r
+               msg.setHmiDisplayLanguage(hmiDisplayLanguage);\r
+               \r
+               return msg;\r
+       }\r
+       \r
+       public static SetDisplayLayout BuildSetDisplayLayout(String displayLayout, Integer correlationID)\r
+       {\r
+               SetDisplayLayout msg = new SetDisplayLayout();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setDisplayLayout(displayLayout);\r
+               \r
+               return msg;\r
+       }\r
+       \r
+       public static PerformAudioPassThru BuildPerformAudioPassThru(String ttsText, String audioPassThruDisplayText1, String audioPassThruDisplayText2,\r
+                                                                                                                 SamplingRate samplingRate, Integer maxDuration, BitsPerSample bitsPerSample,\r
+                                                                                                                 AudioType audioType, Boolean muteAudio, Integer correlationID)\r
+       {\r
+               Vector<TTSChunk> chunks = TTSChunkFactory\r
+                               .createSimpleTTSChunks(ttsText);\r
+               \r
+               PerformAudioPassThru msg = BuildPerformAudioPassThru(chunks, audioPassThruDisplayText1, audioPassThruDisplayText2,\r
+                                                                                                                        samplingRate, maxDuration, bitsPerSample,audioType,  muteAudio, correlationID);\r
+               \r
+               return msg;\r
+       }\r
+       \r
+       public static PerformAudioPassThru BuildPerformAudioPassThru(Vector<TTSChunk> initialPrompt, String audioPassThruDisplayText1, String audioPassThruDisplayText2,\r
+                         SamplingRate samplingRate, Integer maxDuration, BitsPerSample bitsPerSample,\r
+                         AudioType audioType, Boolean muteAudio, Integer correlationID)\r
+       {\r
+               PerformAudioPassThru msg = new PerformAudioPassThru();\r
+               msg.setCorrelationID(correlationID);\r
+               msg.setInitialPrompt(initialPrompt);\r
+               msg.setAudioPassThruDisplayText1(audioPassThruDisplayText1);\r
+               msg.setAudioPassThruDisplayText2(audioPassThruDisplayText2);\r
+               msg.setSamplingRate(samplingRate);\r
+               msg.setMaxDuration(maxDuration);\r
+               msg.setBitsPerSample(bitsPerSample);\r
+               msg.setAudioType(audioType);\r
+               msg.setMuteAudio(muteAudio);\r
+                               \r
+               return msg;\r
+       }\r
+       \r
+       public static EndAudioPassThru BuildEndAudioPassThru(Integer correlationID)\r
+       {\r
+               EndAudioPassThru msg = new EndAudioPassThru();\r
+               msg.setCorrelationID(correlationID);\r
+               \r
+               return msg;\r
+       }\r
+       \r
+}\r
index be3f6fd..b99bd60 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.Result;
-import com.smartdevicelink.util.DebugTool;
-
-public class RPCResponse extends RPCMessage {
-       
-       public RPCResponse(String functionName) {
-               super(functionName, "response");
-       }
-
-       public RPCResponse(Hashtable hash) {
-               super(hash);
-       }
-
-       public RPCResponse(RPCMessage rpcMsg) {
-               super(rpcMsg);
-       }
-
-       public Integer getCorrelationID() {
-               return (Integer)function.get(Names.correlationID);
-       }
-       
-       public void setCorrelationID(Integer correlationID) {
-               if (correlationID != null) {
-            function.put(Names.correlationID, correlationID );
-        } else if (parameters.contains(Names.correlationID)){
-               function.remove(Names.correlationID);
-        }
-       }
-       
-       public Boolean getSuccess() {
-        return (Boolean) parameters.get( Names.success );
-    }
-       
-    public void setSuccess( Boolean success ) {
-        if (success != null) {
-            parameters.put(Names.success, success );
-        }
-    }
-    
-    public Result getResultCode() {
-        Object obj = parameters.get(Names.resultCode);
-        if (obj instanceof Result) {
-            return (Result) obj;
-        } else if (obj instanceof String) {
-            Result theCode = null;
-            try {
-                theCode = Result.valueForString((String) obj);
-            } catch (Exception e) {
-                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.resultCode, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    
-    public void setResultCode( Result resultCode ) {
-        if (resultCode != null) {
-            parameters.put(Names.resultCode, resultCode );
-        }
-    }
-    
-    public String getInfo() {
-        return (String) parameters.get( Names.info );
-    }
-    
-    public void setInfo( String info ) {
-        if (info != null) {
-            parameters.put(Names.info, info );
-        }
-    }
-}
+/**\r
+ * \r
+ */\r
+package com.smartdevicelink.proxy;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.Result;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Result sent by SMARTDEVICELINK after an RPC is processed, consists of four parts: \r
+ * <ul>\r
+ * <li>\r
+ * CorrelationID:\r
+ * <ul>\r
+ * An integer value correlating the response to the corresponding request.\r
+ * </ul>\r
+ * </li> <li>Success:\r
+ * <ul>\r
+ * A Boolean indicating whether the original request was successfully processed.\r
+ * </ul>\r
+ * </li> <li>ResultCode:\r
+ * <ul>\r
+ * \r
+ * The result code provides additional information about a response returning a\r
+ * failed outcome.\r
+ * <br>\r
+ * \r
+ * Any response can have at least one, or possibly more, of the following result\r
+ * code values: SUCCESS, INVALID_DATA, OUT_OF_MEMORY, TOO_MANY_PENDING_REQUESTS,\r
+ * APPLICATION_NOT_REGISTERED, GENERIC_ERROR,REJECTED.\r
+ * <br>\r
+ * \r
+ * Any additional result codes for a given operation can be found in related\r
+ * RPCs\r
+ * <br>\r
+ * </ul>\r
+ * </li> <li>Info:\r
+ * <ul>\r
+ * A string of text representing additional information returned from SMARTDEVICELINK. This\r
+ * could be useful in debugging.\r
+ * </ul>\r
+ * </li>\r
+ * </ul>\r
+ */\r
+public class RPCResponse extends RPCMessage {\r
+       /**\r
+       *<p>Constructs a newly allocated RPCResponse object using function name</p>\r
+       *@param functionName a string that indicates the function's name\r
+       */\r
+       public RPCResponse(String functionName) {\r
+               super(functionName, "response");\r
+       }\r
+       /**\r
+     *<p>Constructs a newly allocated RPCResponse object indicated by the Hashtable parameter</p>\r
+     *@param hash The Hashtable to use\r
+     */   \r
+       public RPCResponse(Hashtable hash) {\r
+               super(hash);\r
+       }\r
+       /**\r
+     *<p>Constructs a newly allocated RPCResponse object using a RPCMessage object</p>\r
+     *@param rpcMsg The {@linkplain RPCMessage} to use\r
+     */   \r
+       public RPCResponse(RPCMessage rpcMsg) {\r
+               super(rpcMsg);\r
+       }\r
+\r
+       /**\r
+        * <p>\r
+        * Returns correlationID the ID of the request\r
+        * </p>\r
+        * \r
+        * @return int  the ID of the request\r
+        */\r
+       public Integer getCorrelationID() {\r
+               return (Integer)function.get(Names.correlationID);\r
+       }\r
+       \r
+       /**\r
+        * <p>\r
+        * Set the correlationID\r
+        * </p>\r
+        * \r
+        * @param correlationID\r
+        *            the ID of the response\r
+        */\r
+       public void setCorrelationID(Integer correlationID) {\r
+               if (correlationID != null) {\r
+            function.put(Names.correlationID, correlationID );\r
+        } else if (parameters.contains(Names.correlationID)){\r
+               function.remove(Names.correlationID);\r
+        }\r
+       }\r
+       /**\r
+        * <p>\r
+        * Returns Success whether the request is successfully processed\r
+        * </p>\r
+        * \r
+        * @return Boolean  the status of whether the request is successfully done\r
+        */\r
+       public Boolean getSuccess() {\r
+        return (Boolean) parameters.get( Names.success );\r
+    }\r
+       /**\r
+        * <p>\r
+        * Set the Success status\r
+        * </p>\r
+        * \r
+        * @param success\r
+        *             whether the request is successfully processed\r
+        */\r
+    public void setSuccess( Boolean success ) {\r
+        if (success != null) {\r
+            parameters.put(Names.success, success );\r
+        }\r
+    }\r
+       /**\r
+        * <p>\r
+        * Returns ResultCode additional information about a response returning a failed outcome\r
+        * </p>\r
+        * \r
+        * @return {@linkplain Result}  the status of whether the request is successfully done\r
+        */\r
+    public Result getResultCode() {\r
+        Object obj = parameters.get(Names.resultCode);\r
+        if (obj instanceof Result) {\r
+            return (Result) obj;\r
+        } else if (obj instanceof String) {\r
+            Result theCode = null;\r
+            try {\r
+                theCode = Result.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.resultCode, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+       /**\r
+        * <p>\r
+        * Set the additional information about a response returning a failed outcome\r
+        * </p>\r
+        * \r
+        * @param resultCode\r
+        *             whether the request is successfully processed\r
+        */\r
+    public void setResultCode( Result resultCode ) {\r
+        if (resultCode != null) {\r
+            parameters.put(Names.resultCode, resultCode );\r
+        }\r
+    }\r
+       /**\r
+        * <p>\r
+        * Returns a string of text representing additional information returned from SMARTDEVICELINK\r
+        * </p>\r
+        * \r
+        * @return String  A string of text representing additional information returned from SMARTDEVICELINK\r
+        */\r
+    public String getInfo() {\r
+        return (String) parameters.get( Names.info );\r
+    }\r
+       /**\r
+        * <p>\r
+        * Set a string of text representing additional information returned from SMARTDEVICELINK\r
+        * </p>\r
+        * \r
+        * @param info\r
+        *             a string of text representing additional information returned from SMARTDEVICELINK\r
+        */\r
+    public void setInfo( String info ) {\r
+        if (info != null) {\r
+            parameters.put(Names.info, info );\r
+        }\r
+    }\r
+}\r
index a91522e..f6c4516 100755 (executable)
@@ -1,54 +1,69 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy;
-
-import java.util.Hashtable;
-
-import org.json.JSONException;
-import org.json.JSONObject;
-
-import com.smartdevicelink.marshal.JsonRPCMarshaller;
-import com.smartdevicelink.proxy.constants.Names;
-
-public class RPCStruct {
-
-       protected Hashtable<String, Object> store = null;
-       
-       public RPCStruct() {
-               store = new Hashtable<String, Object>();
-       }
-       
-       protected RPCStruct(RPCStruct rpcs) {
-               this.store = rpcs.store;
-       }
-       
-       public RPCStruct(Hashtable<String, Object> hashtable) {
-               store = hashtable;
-       }
-       
-       public void deserializeJSON(JSONObject jsonObject) throws JSONException {
-               store = JsonRPCMarshaller.deserializeJSONObject(jsonObject);
-       }
-       
-       // deserializeJSONObject method moved to JsonRPCMarshaller for consistency
-       // Keep reference here for backwards compatibility
-       @Deprecated
-       public static Hashtable<String, Object> deserializeJSONObject(JSONObject jsonObject) 
-                       throws JSONException {
-               return JsonRPCMarshaller.deserializeJSONObject(jsonObject);
-       }
-       
-       public JSONObject serializeJSON() throws JSONException {
-               return JsonRPCMarshaller.serializeHashtable(store);
-       }
-       
-       public JSONObject serializeJSON(byte version) throws JSONException {
-               if (version == 2) {
-                       String messageType = (String)store.keys().nextElement();
-                       Hashtable function = (Hashtable)store.get(messageType);
-                       Hashtable hash = (Hashtable)function.get(Names.parameters);
-                       return JsonRPCMarshaller.serializeHashtable(hash);
-               } else return JsonRPCMarshaller.serializeHashtable(store);
-       }
-}
+package com.smartdevicelink.proxy;\r
+\r
+import java.util.Hashtable;\r
+\r
+import org.json.JSONException;\r
+import org.json.JSONObject;\r
+\r
+import com.smartdevicelink.marshal.JsonRPCMarshaller;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+public class RPCStruct {\r
+       \r
+       private byte[] _bulkData = null;\r
+\r
+       protected Hashtable<String, Object> store = null;\r
+       \r
+       public RPCStruct() {\r
+               store = new Hashtable<String, Object>();\r
+       }\r
+       \r
+       protected RPCStruct(RPCStruct rpcs) {\r
+               this.store = rpcs.store;\r
+       }\r
+       \r
+       public RPCStruct(Hashtable<String, Object> hashtable) {\r
+               store = hashtable;\r
+               //store = (Hashtable<String, Object>) ObjectCopier.copy(hashtable);\r
+       }\r
+       \r
+       public void deserializeJSON(JSONObject jsonObject) throws JSONException {\r
+               store = JsonRPCMarshaller.deserializeJSONObject(jsonObject);\r
+       }\r
+       \r
+       // deserializeJSONObject method moved to JsonRPCMarshaller for consistency\r
+       // Keep reference here for backwards compatibility\r
+       @Deprecated\r
+       public static Hashtable<String, Object> deserializeJSONObject(JSONObject jsonObject) \r
+                       throws JSONException {\r
+               return JsonRPCMarshaller.deserializeJSONObject(jsonObject);\r
+       }\r
+       \r
+       public JSONObject serializeJSON() throws JSONException {\r
+               return JsonRPCMarshaller.serializeHashtable(store);\r
+       }\r
+       \r
+       public JSONObject serializeJSON(byte version) throws JSONException {\r
+               if (version == 2) {\r
+                       String messageType = (String)store.keys().nextElement();\r
+                       Hashtable function = (Hashtable)store.get(messageType);\r
+            Hashtable parameters = (Hashtable)function.get(Names.parameters);
+                       return JsonRPCMarshaller.serializeHashtable(parameters);\r
+                       //Hashtable hashToSend = new Hashtable();\r
+                       //hashToSend.put(Names.parameters, parameters);\r
+                       //return JsonRPCMarshaller.serializeHashtable(hashToSend);\r
+               } else return JsonRPCMarshaller.serializeHashtable(store);\r
+       }\r
+\r
+       public byte[] getBulkData() {\r
+               return this._bulkData;\r
+       }\r
+\r
+       public void setBulkData(byte[] bulkData) {\r
+               if (bulkData != null) {\r
+                       this._bulkData = new byte[bulkData.length];\r
+                       System.arraycopy(bulkData, 0, _bulkData, 0, bulkData.length);\r
+                       //this._bulkData = bulkData;\r
+               }\r
+       }\r
+}\r
index 99c9246..dc19180 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy;
-
-import java.util.Vector;
-
-import com.smartdevicelink.exception.SmartDeviceLinkException;
-import com.smartdevicelink.exception.SmartDeviceLinkExceptionCause;
-import com.smartdevicelink.proxy.rpc.SyncMsgVersion;
-import com.smartdevicelink.proxy.rpc.enums.Language;
-import com.smartdevicelink.trace.SyncTrace;
-
-public class SmartDeviceLinkProxy extends SmartDeviceLinkProxyBase<IProxyListener> {
-       
-       private static final String SMARTDEVICELINK_LIB_TRACE_KEY = "42baba60-eb57-11df-98cf-0800200c9a66";
-       private static final String SMARTDEVICELINK_LIB_PRIVATE_TOKEN = "{DAE1A88C-6C16-4768-ACA5-6F1247EA01C2}";
-
-       /**
-        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SmartDeviceLink. 
-        * 
-        * @param listener - Reference to the object in the App listening to callbacks from SmartDeviceLink. 
-        * @throws SmartDeviceLinkException
-        */
-       public SmartDeviceLinkProxy(IProxyListener listener) throws SmartDeviceLinkException {
-               super(  listener, 
-                               /*application context*/null, 
-                               /*enable advanced lifecycle management*/false, 
-                               /*app name*/ null,
-                               /*ngn media screen app name*/null,
-                               /*vr synonyms*/null,
-                               /*is media app*/ null,
-                               /*SyncMsgVersion*/null,
-                               /*language desired*/null,
-                               /*autoActivateID*/null,
-                               /*callbackToUIThread*/ true);
-               
-               SyncTrace.logProxyEvent("Application constructed SmartDeviceLinkProxy instance passing in: IProxyListener.", SMARTDEVICELINK_LIB_TRACE_KEY);
-       }
-       
-       /**
-        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SmartDeviceLink. 
-        * 
-        * @param listener - Reference to the object in the App listening to callbacks from SmartDeviceLink. 
-        * @param applicationContext - Context of the application. Used to access application specific resources.
-        * @throws SmartDeviceLinkException
-        */
-       public SmartDeviceLinkProxy(IProxyListener listener, SmartDeviceLinkProxyConfigurationResources SmartDeviceLinkProxyConfigurationResources) 
-               throws SmartDeviceLinkException {
-               super(  listener, 
-                               SmartDeviceLinkProxyConfigurationResources, 
-                               /*enable advanced lifecycle management*/false, 
-                               /*app name*/ null,
-                               /*ngn media screen app name*/null,
-                               /*vr synonyms*/null,
-                               /*is media app*/ null,
-                               /*SyncMsgVersion*/null,
-                               /*language desired*/null,
-                               /*autoActivateID*/null,
-                               /*callbackToUIThread*/ true);
-               
-               SyncTrace.logProxyEvent("Application constructed SmartDeviceLinkProxy instance passing in: IProxyListener, SmartDeviceLinkProxyConfigurationResources.", SMARTDEVICELINK_LIB_TRACE_KEY);
-       }
-       
-       /**
-        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SmartDeviceLink.
-        * 
-        * @param listener - Reference to the object in the App listening to callbacks from SmartDeviceLink. 
-        * @param callbackToUIThread - If true, all callbacks will occur on the UI thread.
-        * @throws SmartDeviceLinkException
-        */
-       public SmartDeviceLinkProxy(IProxyListener listener, boolean callbackToUIThread) throws SmartDeviceLinkException {
-               super(  listener,  
-                               /*SmartDeviceLink proxy configuration resources*/null,
-                               /*enable advanced lifecycle management*/false, 
-                               /*app name*/ null,
-                               /*ngn media screen app name*/null,
-                               /*vr synonyms*/null,
-                               /*is media app*/ null,
-                               /*SyncMsgVersion*/null,
-                               /*language desired*/null,
-                               /*autoActivateID*/null,
-                               callbackToUIThread);
-               
-               SyncTrace.logProxyEvent("Application constructed SmartDeviceLinkProxy instance passing in: IProxyListener, callBackToUIThread.", SMARTDEVICELINK_LIB_TRACE_KEY);
-       }
-       
-       /**
-        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SmartDeviceLink.
-        * 
-        * @param listener - Reference to the object in the App listening to callbacks from SmartDeviceLink.
-        * @param applicationContext - Context of the application. Used to access application specific resources. 
-        * @param callbackToUIThread - If true, all callbacks will occur on the UI thread.
-        * @throws SmartDeviceLinkException
-        */
-       public SmartDeviceLinkProxy(IProxyListener listener, SmartDeviceLinkProxyConfigurationResources SmartDeviceLinkProxyConfigurationResources, 
-                       boolean callbackToUIThread) throws SmartDeviceLinkException {
-               super(  listener,  
-                               SmartDeviceLinkProxyConfigurationResources,
-                               /*enable advanced lifecycle management*/false, 
-                               /*app name*/ null,
-                               /*ngn media screen app name*/null,
-                               /*vr synonyms*/null,
-                               /*is media app*/ null,
-                               /*SyncMsgVersion*/null,
-                               /*language desired*/null,
-                               /*autoActivateID*/null,
-                               callbackToUIThread);
-               
-               SyncTrace.logProxyEvent("Application constructed SmartDeviceLinkProxy instance passing in: IProxyListener, callBackToUIThread.", SMARTDEVICELINK_LIB_TRACE_KEY);
-       }
-       
-       
-       
-       
-       /******************** Public Helper Methods *************************/
-       
-       
-       /**
-        *  Sends a RegisterAppInterface RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        *  
-        *  @param SyncMsgVersion
-        *  @param appName
-        *  @param ngnMediaScreenAppName
-        *  @param vrSynonyms
-        *  @param isMediaApp
-        *  @param languageDesired
-        *  @param autoActivateID
-        *  @param correlationID
-        *  
-        *  @throws SmartDeviceLinkException
-        */
-       public void registerAppInterface(
-                       SyncMsgVersion SyncMsgVersion, String appName, String ngnMediaScreenAppName,
-                       Vector<String> vrSynonyms, Boolean isMediaApp, Language languageDesired, 
-                       String autoActivateID, Integer correlationID) 
-                       throws SmartDeviceLinkException {
-               
-               // Test if proxy has been disposed
-               if (_proxyDisposed) {
-                       throw new SmartDeviceLinkException("This SmartDeviceLinkProxy object has been disposed, it is no long capable of sending requests.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);
-               }
-               
-               registerAppInterfacePrivate(
-                               SyncMsgVersion, 
-                               appName,
-                               ngnMediaScreenAppName,
-                               vrSynonyms,
-                               isMediaApp, 
-                               languageDesired,
-                               autoActivateID,
-                               correlationID);
-       }
-       
-       /**
-        * Sends a RegisterAppInterface RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param appName
-        * @param isMediaApp
-        * @param autoActivateID
-        * @throws SmartDeviceLinkException
-        */
-       public void registerAppInterface(
-                       String appName, Boolean isMediaApp, String autoActivateID, Integer correlationID) 
-                       throws SmartDeviceLinkException {
-               
-               registerAppInterface(
-                               /*SyncMsgVersion*/null, 
-                               appName,
-                               /*ngnMediaScreenAppName*/null,
-                               /*vrSynonyms*/null,
-                               isMediaApp, 
-                               /*languageDesired*/null,
-                               autoActivateID,
-                               correlationID);
-       }
-       
-       /**
-        * Sends a RegisterAppInterface RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param appName
-        * @throws SmartDeviceLinkException
-        */
-       public void registerAppInterface(String appName, Integer correlationID) 
-                       throws SmartDeviceLinkException {
-               
-               registerAppInterface(appName, false, "", correlationID);
-       }
-       
-       /**
-        * Sends an UnregisterAppInterface RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void unregisterAppInterface(Integer correlationID) 
-                       throws SmartDeviceLinkException {               
-               // Test if proxy has been disposed
-               if (_proxyDisposed) {
-                       throw new SmartDeviceLinkException("This SmartDeviceLinkProxy object has been disposed, it is no long capable of executing methods.", 
-                                                                               SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);
-               }               
-                               
-               unregisterAppInterfacePrivate(correlationID);
-       }
-       
-       /**
-        * Returns is isConnected state of the SmartDeviceLink transport.
-        * 
-        * @return Boolean isConnected
-        */
-       public Boolean getIsConnected() {
-               return super.getIsConnected();
-       }
-}
+package com.smartdevicelink.proxy;\r
+\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.exception.SmartDeviceLinkException;\r
+import com.smartdevicelink.exception.SmartDeviceLinkExceptionCause;\r
+import com.smartdevicelink.proxy.rpc.smartdevicelinkMsgVersion;\r
+import com.smartdevicelink.proxy.rpc.enums.Language;\r
+import com.smartdevicelink.trace.SmartDeviceLinkTrace;\r
+import com.smartdevicelink.transport.BTTransportConfig;\r
+import com.smartdevicelink.transport.BaseTransportConfig;\r
+import com.smartdevicelink.transport.TransportType;\r
+@Deprecated\r
+public class SmartDeviceLinkProxy extends SmartDeviceLinkProxyBase<IProxyListener> {\r
+       \r
+       private static final String SMARTDEVICELINK_LIB_TRACE_KEY = "42baba60-eb57-11df-98cf-0800200c9a66";\r
+       private static final String SMARTDEVICELINK_LIB_PRIVATE_TOKEN = "{DAE1A88C-6C16-4768-ACA5-6F1247EA01C2}";\r
+\r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK. \r
+        * \r
+        * @param listener - Reference to the object in the App listening to callbacks from SMARTDEVICELINK. \r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       @Deprecated\r
+       public SmartDeviceLinkProxy(IProxyListener listener) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               /*application context*/null, \r
+                               /*enable advanced lifecycle management*/false, \r
+                               /*app name*/ null,\r
+                               /*TTS Name*/null,\r
+                               /*ngn media screen app name*/null,\r
+                               /*vr synonyms*/null,\r
+                               /*is media app*/ null,\r
+                               /*smartDeviceLinkMsgVersion*/null,\r
+                               /*language desired*/null,\r
+                               /*HMI Display Language Desired*/null,\r
+                               /*App Type*/null,\r
+                               /*App ID*/null,\r
+                               /*autoActivateID*/null,\r
+                               /*callbackToUIThread*/ true,\r
+                               new BTTransportConfig());\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxy instance passing in: IProxyListener.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK. \r
+        * \r
+        * @param listener - Reference to the object in the App listening to callbacks from SMARTDEVICELINK. \r
+        * @param smartDeviceLinkProxyConfigurationResources\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       @Deprecated\r
+       public SmartDeviceLinkProxy(IProxyListener listener, SmartDeviceLinkProxyConfigurationResources smartDeviceLinkProxyConfigurationResources) \r
+               throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               smartDeviceLinkProxyConfigurationResources, \r
+                               /*enable advanced lifecycle management*/false, \r
+                               /*app name*/ null,\r
+                               /*TTS Name*/null,\r
+                               /*ngn media screen app name*/null,\r
+                               /*vr synonyms*/null,\r
+                               /*is media app*/ null,\r
+                               /*smartDeviceLinkMsgVersion*/null,\r
+                               /*language desired*/null,\r
+                               /*HMI Display Language Desired*/null,\r
+                               /*App Type*/null,\r
+                               /*App ID*/null,\r
+                               /*autoActivateID*/null,\r
+                               /*callbackToUIThread*/ true,\r
+                               new BTTransportConfig());\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxy instance passing in: IProxyListener, SmartDeviceLinkProxyConfigurationResources.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK.\r
+        * \r
+        * @param listener - Reference to the object in the App listening to callbacks from SMARTDEVICELINK. \r
+        * @param callbackToUIThread - If true, all callbacks will occur on the UI thread.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       @Deprecated\r
+       public SmartDeviceLinkProxy(IProxyListener listener, boolean callbackToUIThread) throws SmartDeviceLinkException {\r
+               super(  listener,  \r
+                               /*smartDeviceLink proxy configuration resources*/null,\r
+                               /*enable advanced lifecycle management*/false, \r
+                               /*app name*/ null,\r
+                               /*TTS Name*/null,\r
+                               /*ngn media screen app name*/null,\r
+                               /*vr synonyms*/null,\r
+                               /*is media app*/ null,\r
+                               /*smartDeviceLinkMsgVersion*/null,\r
+                               /*language desired*/null,\r
+                               /*HMI Display Language Desired*/null,\r
+                               /*App Type*/null,\r
+                               /*App ID*/null,\r
+                               /*autoActivateID*/null,\r
+                               callbackToUIThread,\r
+                               new BTTransportConfig());\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxy instance passing in: IProxyListener, callBackToUIThread.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK.\r
+        * \r
+        * @param listener - Reference to the object in the App listening to callbacks from SMARTDEVICELINK.\r
+        * @param smartDeviceLinkProxyConfigurationResources \r
+        * @param callbackToUIThread - If true, all callbacks will occur on the UI thread.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       @Deprecated\r
+       public SmartDeviceLinkProxy(IProxyListener listener, SmartDeviceLinkProxyConfigurationResources smartDeviceLinkProxyConfigurationResources, \r
+                       boolean callbackToUIThread) throws SmartDeviceLinkException {\r
+               super(  listener,  \r
+                               smartDeviceLinkProxyConfigurationResources,\r
+                               /*enable advanced lifecycle management*/false, \r
+                               /*app name*/ null,\r
+                               /*TTS Name*/null,\r
+                               /*ngn media screen app name*/null,\r
+                               /*vr synonyms*/null,\r
+                               /*is media app*/ null,\r
+                               /*smartDeviceLinkMsgVersion*/null,\r
+                               /*language desired*/null,\r
+                               /*HMI Display Language Desired*/null,\r
+                               /*App Type*/null,\r
+                               /*App ID*/null,\r
+                               /*autoActivateID*/null,\r
+                               callbackToUIThread,\r
+                               new BTTransportConfig());\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxy instance passing in: IProxyListener, callBackToUIThread.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       /********************************************** TRANSPORT SWITCHING SUPPORT *****************************************/\r
+\r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK. \r
+        * \r
+        * @param listener - Reference to the object in the App listening to callbacks from SMARTDEVICELINK.\r
+        * @param transportConfig Initial configuration for transport.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       @Deprecated\r
+       public SmartDeviceLinkProxy(IProxyListener listener, BaseTransportConfig transportConfig) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               /*application context*/null, \r
+                               /*enable advanced lifecycle management*/false, \r
+                               /*app name*/ null,\r
+                               /*TTS Name*/null,\r
+                               /*ngn media screen app name*/null,\r
+                               /*vr synonyms*/null,\r
+                               /*is media app*/ null,\r
+                               /*smartDeviceLinkMsgVersion*/null,\r
+                               /*language desired*/null,\r
+                               /*HMI Display Language Desired*/null,\r
+                               /*App Type*/null,\r
+                               /*App ID*/null,\r
+                               /*autoActivateID*/null,\r
+                               /*callbackToUIThread*/ true,\r
+                               transportConfig);\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxy instance passing in: IProxyListener.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK. \r
+        * \r
+        * @param listener - Reference to the object in the App listening to callbacks from SMARTDEVICELINK. \r
+        * @param smartDeviceLinkProxyConfigurationResources\r
+        * @param transportConfig Initial configuration for transport.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       @Deprecated\r
+       public SmartDeviceLinkProxy(IProxyListener listener, SmartDeviceLinkProxyConfigurationResources smartDeviceLinkProxyConfigurationResources, \r
+                                       BaseTransportConfig transportConfig) \r
+               throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               smartDeviceLinkProxyConfigurationResources, \r
+                               /*enable advanced lifecycle management*/false, \r
+                               /*app name*/ null,\r
+                               /*TTS Name*/null,\r
+                               /*ngn media screen app name*/null,\r
+                               /*vr synonyms*/null,\r
+                               /*is media app*/ null,\r
+                               /*smartDeviceLinkMsgVersion*/null,\r
+                               /*language desired*/null,\r
+                               /*HMI Display Language Desired*/null,\r
+                               /*App Type*/null,\r
+                               /*App ID*/null,\r
+                               /*autoActivateID*/null,\r
+                               /*callbackToUIThread*/ true,\r
+                               transportConfig);\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxy instance passing in: IProxyListener, SmartDeviceLinkProxyConfigurationResources.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK.\r
+        * \r
+        * @param listener - Reference to the object in the App listening to callbacks from SMARTDEVICELINK. \r
+        * @param callbackToUIThread - If true, all callbacks will occur on the UI thread.\r
+        * @param transportConfig Initial configuration for transport.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       @Deprecated\r
+       public SmartDeviceLinkProxy(IProxyListener listener, boolean callbackToUIThread, BaseTransportConfig transportConfig) throws SmartDeviceLinkException {\r
+               super(  listener,  \r
+                               /*smartDeviceLink proxy configuration resources*/null,\r
+                               /*enable advanced lifecycle management*/false, \r
+                               /*app name*/ null,\r
+                               /*TTS Name*/null,\r
+                               /*ngn media screen app name*/null,\r
+                               /*vr synonyms*/null,\r
+                               /*is media app*/ null,\r
+                               /*smartDeviceLinkMsgVersion*/null,\r
+                               /*language desired*/null,\r
+                               /*HMI Display Language Desired*/null,\r
+                               /*App Type*/null,\r
+                               /*App ID*/null,\r
+                               /*autoActivateID*/null,\r
+                               callbackToUIThread,\r
+                               transportConfig);\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxy instance passing in: IProxyListener, callBackToUIThread.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK.\r
+        * \r
+        * @param listener - Reference to the object in the App listening to callbacks from SMARTDEVICELINK.\r
+        * @param smartDeviceLinkProxyConfigurationResources \r
+        * @param callbackToUIThread - If true, all callbacks will occur on the UI thread.\r
+        * @param transportConfig Initial configuration for transport.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       @Deprecated\r
+       public SmartDeviceLinkProxy(IProxyListener listener, SmartDeviceLinkProxyConfigurationResources smartDeviceLinkProxyConfigurationResources, \r
+                       boolean callbackToUIThread, BaseTransportConfig transportConfig) throws SmartDeviceLinkException {\r
+               super(  listener,  \r
+                               smartDeviceLinkProxyConfigurationResources,\r
+                               /*enable advanced lifecycle management*/false, \r
+                               /*app name*/ null,\r
+                               /*TTS Name*/null,\r
+                               /*ngn media screen app name*/null,\r
+                               /*vr synonyms*/null,\r
+                               /*is media app*/ null,\r
+                               /*smartDeviceLinkMsgVersion*/null,\r
+                               /*language desired*/null,\r
+                               /*HMI Display Language Desired*/null,\r
+                               /*App Type*/null,\r
+                               /*App ID*/null,\r
+                               /*autoActivateID*/null,\r
+                               callbackToUIThread,\r
+                               transportConfig);\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxy instance passing in: IProxyListener, callBackToUIThread.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+               \r
+       /******************** Public Helper Methods *************************/\r
+       \r
+       \r
+       /**\r
+        *  Sends a RegisterAppInterface RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        *  \r
+        *  @param smartDeviceLinkMsgVersion\r
+        *  @param appName\r
+        *  @param ngnMediaScreenAppName\r
+        *  @param vrSynonyms\r
+        *  @param isMediaApp\r
+        *  @param languageDesired\r
+        *  @param autoActivateID\r
+        *  @param correlationID\r
+        *  \r
+        *  @throws SmartDeviceLinkException\r
+        */\r
+       @Deprecated\r
+       public void registerAppInterface(\r
+                       smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, String appName, String ngnMediaScreenAppName,\r
+                       Vector<String> vrSynonyms, Boolean isMediaApp, Language languageDesired, Language hmiDisplayLanguageDesired,\r
+                       String appID, String autoActivateID, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               // Test if proxy has been disposed\r
+               if (_proxyDisposed) {\r
+                       throw new SmartDeviceLinkException("This SmartDeviceLinkProxy object has been disposed, it is no long capable of sending requests.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);\r
+               }\r
+               \r
+               registerAppInterfacePrivate(\r
+                               smartDeviceLinkMsgVersion, \r
+                               appName,\r
+                               null,\r
+                               ngnMediaScreenAppName,\r
+                               vrSynonyms,\r
+                               isMediaApp, \r
+                               languageDesired,\r
+                               hmiDisplayLanguageDesired,\r
+                               null,\r
+                               appID,\r
+                               autoActivateID,\r
+                               correlationID);\r
+       }\r
+       \r
+       /**\r
+        * Sends a RegisterAppInterface RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param appName\r
+        * @param isMediaApp\r
+        * @param autoActivateID\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       @Deprecated\r
+       public void registerAppInterface(\r
+                       String appName, Boolean isMediaApp, String appID, String autoActivateID, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               registerAppInterface(\r
+                               /*smartDeviceLinkMsgVersion*/null, \r
+                               appName,\r
+                               /*ngnMediaScreenAppName*/null,\r
+                               /*vrSynonyms*/null,\r
+                               isMediaApp, \r
+                               /*languageDesired*/null,\r
+                               /*hmiDisplayLanguageDesired*/null,\r
+                               appID,\r
+                               autoActivateID,\r
+                               correlationID);\r
+       }\r
+       \r
+       /**\r
+        * Sends a RegisterAppInterface RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param appName\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       @Deprecated\r
+       public void registerAppInterface(String appName, String appID, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               registerAppInterface(appName, false, appID, "", correlationID);\r
+       }\r
+       \r
+       /**\r
+        * Sends an UnregisterAppInterface RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param correlationID\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       @Deprecated\r
+       public void unregisterAppInterface(Integer correlationID) \r
+                       throws SmartDeviceLinkException {               \r
+               // Test if proxy has been disposed\r
+               if (_proxyDisposed) {\r
+                       throw new SmartDeviceLinkException("This SmartDeviceLinkProxy object has been disposed, it is no long capable of executing methods.", \r
+                                                                               SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);\r
+               }               \r
+                               \r
+               unregisterAppInterfacePrivate(correlationID);\r
+       }\r
+       \r
+       /**\r
+        * Returns is isConnected state of the SMARTDEVICELINK transport.\r
+        * \r
+        * @return Boolean isConnected\r
+        */\r
+       @Deprecated\r
+       public Boolean getIsConnected() {\r
+               return super.getIsConnected();\r
+       }\r
+\r
+}\r
index 38b3482..cc4a19a 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy;
-
-import java.util.Vector;
-
-import com.smartdevicelink.exception.SmartDeviceLinkException;
-import com.smartdevicelink.exception.SmartDeviceLinkExceptionCause;
-import com.smartdevicelink.proxy.interfaces.IProxyListenerALM;
-import com.smartdevicelink.proxy.rpc.ButtonCapabilities;
-import com.smartdevicelink.proxy.rpc.DisplayCapabilities;
-import com.smartdevicelink.proxy.rpc.SyncMsgVersion;
-import com.smartdevicelink.proxy.rpc.enums.HmiZoneCapabilities;
-import com.smartdevicelink.proxy.rpc.enums.Language;
-import com.smartdevicelink.proxy.rpc.enums.SpeechCapabilities;
-import com.smartdevicelink.proxy.rpc.enums.SmartDeviceLinkDisconnectedReason;
-import com.smartdevicelink.proxy.rpc.enums.VrCapabilities;
-import com.smartdevicelink.trace.SyncTrace;
-import com.smartdevicelink.transport.BaseTransportConfig;
-
-public class SmartDeviceLinkProxyALM extends SmartDeviceLinkProxyBase<IProxyListenerALM> {
-       
-       private static final String SMARTDEVICELINK_LIB_TRACE_KEY = "42baba60-eb57-11df-98cf-0800200c9a66";
-       private static final String SMARTDEVICELINK_LIB_PRIVATE_TOKEN = "{DAE1A88C-6C16-4768-ACA5-6F1247EA01C2}";
-       
-       /**
-        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SmartDeviceLink
-        * 
-        * Takes advantage of the advanced lifecycle management.
-        * @param listener - Reference to the object in the App listening to callbacks from SmartDeviceLink. 
-        * @param appName - Name of the application displayed on SmartDeviceLink. 
-        * @param isMediaApp - Indicates if the app is a media application.
-        */
-       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, String appName, Boolean isMediaApp) throws SmartDeviceLinkException {
-               super(  listener, 
-                               /*SmartDeviceLink proxy configuration resources*/null, 
-                               /*enable advanced lifecycle management*/true, 
-                               appName,
-                               /*ngn media app*/null,
-                               /*vr synonyms*/null,
-                               /*is media app*/isMediaApp,
-                               /*SyncMsgVersion*/null,
-                               /*language desired*/null,
-                               /*autoActivateID*/null,
-                               /*callbackToUIThread*/ false);
-               
-               SyncTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM instance passing in: IProxyListener, appName, and isMediaApp.", SMARTDEVICELINK_LIB_TRACE_KEY);
-       }
-
-       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, String appName, Boolean isMediaApp,
-                       BaseTransportConfig transportConfig) throws SmartDeviceLinkException {
-               super(  listener, 
-                               /*SmartDeviceLink proxy configuration resources*/null, 
-                               /*enable advanced lifecycle management*/true, 
-                               appName,
-                               /*ngn media app*/null,
-                               /*vr synonyms*/null,
-                               /*is media app*/isMediaApp,
-                               /*SyncMsgVersion*/null,
-                               /*language desired*/null,
-                               /*autoActivateID*/null,
-                               /*callbackToUIThread*/ false,
-                               transportConfig);
-               
-               SyncTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM instance passing in: IProxyListener, appName, and isMediaApp.", SMARTDEVICELINK_LIB_TRACE_KEY);
-       }
-       
-       /**
-        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SmartDeviceLink.
-        * 
-        * Takes advantage of the advanced lifecycle management. 
-        * 
-        * @param listener - Reference to the object in the App listening to callbacks from SmartDeviceLink. 
-        * @param appName - Name of the application displayed on SmartDeviceLink. 
-        * @param ngnMediaScreenAppName - Name of the application displayed on SmartDeviceLink for Navigation equipped 
-        * vehicles. Limited to five characters. 
-        * @param vrSynonyms - A vector of strings, all of which can be used as voice commands to 
-        * @param isMediaApp - Indicates if the app is a media application.
-        * @param SyncMsgVersion - Indicates the version of SmartDeviceLink SmartDeviceLink Messages desired. Must be less than
-        * or equal to the version of SmartDeviceLink SmartDeviceLink running on the vehicle. 
-        * @param languageDesired - Indicates the language desired for the SmartDeviceLink interface.
-        * @param autoActivateID - ID used to re-register previously registered application.
-        * @throws SmartDeviceLinkException
-        */
-       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, String appName, String ngnMediaScreenAppName, 
-                       Vector<String> vrSynonyms, Boolean isMediaApp, SyncMsgVersion SyncMsgVersion, 
-                       Language languageDesired, String autoActivateID) throws SmartDeviceLinkException {
-               super(  listener, 
-                               /*SmartDeviceLink proxy configuration resources*/null, 
-                               /*enable advanced lifecycle management*/true, 
-                               appName,
-                               ngnMediaScreenAppName,
-                               vrSynonyms,
-                               isMediaApp,
-                               SyncMsgVersion,
-                               languageDesired,
-                               autoActivateID,
-                               /*callbackToUIThread*/ false);
-               
-               SyncTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM instance passing in: IProxyListener, appName, ngnMediaScreenAppName, " +
-                               "vrSynonyms, isMediaApp, SyncMsgVersion, languageDesired, and autoActivateID.", SMARTDEVICELINK_LIB_TRACE_KEY);
-       }
-       
-       /**
-        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SmartDeviceLink.
-        * 
-        * Takes advantage of the advanced lifecycle management. 
-        * 
-        * @param listener - Reference to the object in the App listening to callbacks from SmartDeviceLink. 
-        * @param applicationContext - Context of the application. Used to access application specific resources.
-        * @param appName - Name of the application displayed on SmartDeviceLink. 
-        * @param ngnMediaScreenAppName - Name of the application displayed on SmartDeviceLink for Navigation equipped 
-        * vehicles. Limited to five characters. 
-        * @param vrSynonyms - A vector of strings, all of which can be used as voice commands to 
-        * @param isMediaApp - Indicates if the app is a media application.
-        * @param SyncMsgVersion - Indicates the version of SmartDeviceLink SmartDeviceLink Messages desired. Must be less than
-        * or equal to the version of SmartDeviceLink SmartDeviceLink running on the vehicle. 
-        * @param languageDesired - Indicates the language desired for the SmartDeviceLink interface.
-        * @param autoActivateID - ID used to re-register previously registered application.
-        * @throws SmartDeviceLinkException
-        */
-       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, SmartDeviceLinkProxyConfigurationResources SmartDeviceLinkProxyConfigurationResources, 
-                       String appName, String ngnMediaScreenAppName, Vector<String> vrSynonyms, 
-                       Boolean isMediaApp, SyncMsgVersion SyncMsgVersion, Language languageDesired, 
-                       String autoActivateID) throws SmartDeviceLinkException {
-               super(  listener, 
-                               SmartDeviceLinkProxyConfigurationResources, 
-                               /*enable advanced lifecycle management*/true, 
-                               appName,
-                               ngnMediaScreenAppName,
-                               vrSynonyms,
-                               isMediaApp,
-                               SyncMsgVersion,
-                               languageDesired,
-                               autoActivateID,
-                               /*callbackToUIThread*/ false);
-               
-               SyncTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM instance passing in: IProxyListener, SmartDeviceLinkProxyConfigurationResources, " +
-                               "appName, ngnMediaScreenAppName, vrSynonyms, isMediaApp, SyncMsgVersion, languageDesired, and autoActivateID.", SMARTDEVICELINK_LIB_TRACE_KEY);
-       }
-       
-       /**
-        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SmartDeviceLink.
-        * 
-        * Takes advantage of the advanced lifecycle management. 
-        * 
-        * @param listener - Reference to the object in the App listening to callbacks from SmartDeviceLink. 
-        * @param appName - Name of the application displayed on SmartDeviceLink. 
-        * @param ngnMediaScreenAppName - Name of the application displayed on SmartDeviceLink for Navigation equipped 
-        * vehicles. Limited to five characters. 
-        * @param vrSynonyms - A vector of strings, all of which can be used as voice commands to 
-        * @param isMediaApp - Indicates if the app is a media application.
-        * @param SyncMsgVersion - Indicates the version of SmartDeviceLink SmartDeviceLink Messages desired. Must be less than
-        * or equal to the version of SmartDeviceLink SmartDeviceLink running on the vehicle. 
-        * @param languageDesired - Indicates the language desired for the SmartDeviceLink interface.
-        * @param autoActivateID - ID used to re-register previously registered application.
-        * @param callbackToUIThread - If true, all callbacks will occur on the UI thread.
-        * @throws SmartDeviceLinkException
-        */
-       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, String appName, String ngnMediaScreenAppName, 
-                       Vector<String> vrSynonyms, Boolean isMediaApp, SyncMsgVersion SyncMsgVersion, 
-                       Language languageDesired, String autoActivateID, boolean callbackToUIThread) throws SmartDeviceLinkException {
-               super(  listener, 
-                               /*SmartDeviceLink proxy configuration resources*/null,
-                               /*enable advanced lifecycle management*/true, 
-                               appName,
-                               ngnMediaScreenAppName,
-                               vrSynonyms,
-                               isMediaApp,
-                               SyncMsgVersion,
-                               languageDesired,
-                               autoActivateID,
-                               callbackToUIThread);
-               
-               SyncTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM instance passing in: IProxyListener, " +
-                               "appName, ngnMediaScreenAppName, vrSynonyms, isMediaApp, SyncMsgVersion, languageDesired, autoActivateID, " +
-                               "and callbackToUIThread", SMARTDEVICELINK_LIB_TRACE_KEY);
-       }
-       
-       /**
-        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SmartDeviceLink.
-        * 
-        * Takes advantage of the advanced lifecycle management. 
-        * 
-        * @param listener - Reference to the object in the App listening to callbacks from SmartDeviceLink. 
-        * @param applicationContext - Context of the application. Used to access application specific resources.
-        * @param appName - Name of the application displayed on SmartDeviceLink. 
-        * @param ngnMediaScreenAppName - Name of the application displayed on SmartDeviceLink for Navigation equipped 
-        * vehicles. Limited to five characters. 
-        * @param vrSynonyms - A vector of strings, all of which can be used as voice commands to 
-        * @param isMediaApp - Indicates if the app is a media application.
-        * @param SyncMsgVersion - Indicates the version of SmartDeviceLink SmartDeviceLink Messages desired. Must be less than
-        * or equal to the version of SmartDeviceLink SmartDeviceLink running on the vehicle. 
-        * @param languageDesired - Indicates the language desired for the SmartDeviceLink interface.
-        * @param autoActivateID - ID used to re-register previously registered application.
-        * @param callbackToUIThread - If true, all callbacks will occur on the UI thread.
-        * @throws SmartDeviceLinkException
-        */
-       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, SmartDeviceLinkProxyConfigurationResources SmartDeviceLinkProxyConfigurationResources, 
-                       String appName, String ngnMediaScreenAppName, Vector<String> vrSynonyms, Boolean isMediaApp, 
-                       SyncMsgVersion SyncMsgVersion, Language languageDesired, String autoActivateID, 
-                       boolean callbackToUIThread) throws SmartDeviceLinkException {
-               super(  listener, 
-                               SmartDeviceLinkProxyConfigurationResources,
-                               /*enable advanced lifecycle management*/true, 
-                               appName,
-                               ngnMediaScreenAppName,
-                               vrSynonyms,
-                               isMediaApp,
-                               SyncMsgVersion,
-                               languageDesired,
-                               autoActivateID,
-                               callbackToUIThread);
-               
-               SyncTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM instance passing in: IProxyListener, SmartDeviceLinkProxyConfigurationResources, " +
-                               "appName, ngnMediaScreenAppName, vrSynonyms, isMediaApp, SyncMsgVersion, languageDesired, autoActivateID, " +
-                               "and callbackToUIThread", SMARTDEVICELINK_LIB_TRACE_KEY);
-       }
-       
-       // Allow applications using ALM to reset the proxy (dispose and reinstantiate)
-       /**
-        * Disconnects the application from SmartDeviceLink, then recreates the transport such that
-        * the next time a SmartDeviceLink unit discovers applications, this application will be
-        * available.
-        */
-       public void resetProxy() throws SmartDeviceLinkException {
-               super.cycleProxy(SmartDeviceLinkDisconnectedReason.APPLICATION_REQUESTED_DISCONNECT);
-       }
-       
-       /********* Getters for values returned by RegisterAppInterfaceResponse **********/
-       
-       /**
-        * Gets autoActivateId set when application interface is registered.
-        * 
-        * @return autoActivateId 
-        * @throws SmartDeviceLinkException
-        */
-       public String getAutoActivateId() throws SmartDeviceLinkException {
-               // Test if proxy has been disposed
-               if (_proxyDisposed) {
-                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);
-               }
-               
-               // Test SmartDeviceLink availability 
-               if (!_appInterfaceRegisterd) {
-                       throw new SmartDeviceLinkException("SmartDeviceLink is not connected. Unable to get the autoActivateId.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);
-               }
-               return _autoActivateIdReturned;
-       }
-       
-       /**
-        * Gets buttonCapabilities set when application interface is registered.
-        * 
-        * @return buttonCapabilities
-        * @throws SmartDeviceLinkException
-        */
-       public Vector<ButtonCapabilities> getButtonCapabilities() throws SmartDeviceLinkException{
-               // Test if proxy has been disposed
-               if (_proxyDisposed) {
-                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);
-               }
-               
-               // Test SmartDeviceLink availability 
-               if (!_appInterfaceRegisterd) {
-                       throw new SmartDeviceLinkException("SmartDeviceLink is unavailable. Unable to get the buttonCapabilities.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);
-               }
-               return _buttonCapabilities;
-       }
-       
-       /**
-        * Gets displayCapabilities set when application interface is registered.
-        * 
-        * @return displayCapabilities
-        * @throws SmartDeviceLinkException
-        */
-       public DisplayCapabilities getDisplayCapabilities() throws SmartDeviceLinkException {
-               // Test if proxy has been disposed
-               if (_proxyDisposed) {
-                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);
-               }
-               
-               // Test SmartDeviceLink availability 
-               if (!_appInterfaceRegisterd) {
-                       throw new SmartDeviceLinkException("SmartDeviceLink is unavailable. Unable to get the displayCapabilities.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);
-               }
-               return _displayCapabilities;
-       }
-       
-       /**
-        * Gets hmiZoneCapabilities set when application interface is registered.
-        * 
-        * @return hmiZoneCapabilities
-        * @throws SmartDeviceLinkException
-        */
-       public Vector<HmiZoneCapabilities> getHmiZoneCapabilities() throws SmartDeviceLinkException {
-               // Test if proxy has been disposed
-               if (_proxyDisposed) {
-                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);
-               }
-               
-               // Test SmartDeviceLink availability 
-               if (!_appInterfaceRegisterd) {
-                       throw new SmartDeviceLinkException("SmartDeviceLink is unavailable. Unable to get the hmiZoneCapabilities.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);
-               }
-               return _hmiZoneCapabilities;
-       }
-       
-       /**
-        * Gets speechCapabilities set when application interface is registered.
-        * 
-        * @return speechCapabilities
-        * @throws SmartDeviceLinkException
-        */
-       public Vector<SpeechCapabilities> getSpeechCapabilities() throws SmartDeviceLinkException {
-               // Test if proxy has been disposed
-               if (_proxyDisposed) {
-                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);
-               }
-               
-               // Test SmartDeviceLink availability 
-               if (!_appInterfaceRegisterd) {
-                       throw new SmartDeviceLinkException("SmartDeviceLink is unavailable. Unable to get the speechCapabilities.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);
-               }
-               
-               return _speechCapabilities;
-       }
-       
-       /**
-        * Gets SmartDeviceLinkLanguage set when application interface is registered.
-        * 
-        * @return SmartDeviceLinkLanguage
-        * @throws SmartDeviceLinkException
-        */
-       public Language getSmartDeviceLinkLanguage() throws SmartDeviceLinkException {
-               // Test if proxy has been disposed
-               if (_proxyDisposed) {
-                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);
-               }
-               
-               // Test SmartDeviceLink availability 
-               if (!_appInterfaceRegisterd) {
-                       throw new SmartDeviceLinkException("SmartDeviceLink is unavailable. Unable to get the SmartDeviceLinkLanguage.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);
-               }
-               return _SmartDeviceLinkLanguage;
-       }
-       
-       /**
-        * Gets SyncMsgVersion set when application interface is registered.
-        * 
-        * @return SyncMsgVersion
-        * @throws SmartDeviceLinkException
-        */
-       public SyncMsgVersion getSyncMsgVersion() throws SmartDeviceLinkException {
-               // Test if proxy has been disposed
-               if (_proxyDisposed) {
-                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);
-               }
-               
-               // Test SmartDeviceLink availability 
-               if (!_appInterfaceRegisterd) {
-                       throw new SmartDeviceLinkException("SmartDeviceLink is unavailable. Unable to get the SyncMsgVersion.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);
-               }
-               return _SyncMsgVersion;
-       }
-       
-       /**
-        * Gets vrCapabilities set when application interface is registered.
-        * 
-        * @return vrCapabilities
-        * @throws SmartDeviceLinkException
-        */
-       public Vector<VrCapabilities> getVrCapabilities() throws SmartDeviceLinkException {
-               // Test if proxy has been disposed
-               if (_proxyDisposed) {
-                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);
-               }
-               
-               // Test SmartDeviceLink availability 
-               if (!_appInterfaceRegisterd) {
-                       throw new SmartDeviceLinkException("SmartDeviceLink is unavailable. Unable to get the vrCapabilities.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);
-               }
-               return _vrCapabilities;
-       }
-}
+package com.smartdevicelink.proxy;\r
+\r
+import java.util.Vector;\r
+\r
+import android.app.Service;\r
+\r
+import com.smartdevicelink.exception.SmartDeviceLinkException;\r
+import com.smartdevicelink.exception.SmartDeviceLinkExceptionCause;\r
+import com.smartdevicelink.proxy.Version;\r
+import com.smartdevicelink.proxy.interfaces.IProxyListenerALM;\r
+import com.smartdevicelink.proxy.rpc.ButtonCapabilities;\r
+import com.smartdevicelink.proxy.rpc.DisplayCapabilities;\r
+import com.smartdevicelink.proxy.rpc.PresetBankCapabilities;\r
+import com.smartdevicelink.proxy.rpc.SoftButtonCapabilities;\r
+import com.smartdevicelink.proxy.rpc.smartdevicelinkMsgVersion;\r
+import com.smartdevicelink.proxy.rpc.TTSChunk;\r
+import com.smartdevicelink.proxy.rpc.VehicleType;\r
+import com.smartdevicelink.proxy.rpc.enums.AppHMIType;\r
+import com.smartdevicelink.proxy.rpc.enums.HmiZoneCapabilities;\r
+import com.smartdevicelink.proxy.rpc.enums.Language;\r
+import com.smartdevicelink.proxy.rpc.enums.SpeechCapabilities;\r
+import com.smartdevicelink.proxy.rpc.enums.SmartDeviceLinkDisconnectedReason;\r
+import com.smartdevicelink.proxy.rpc.enums.VrCapabilities;\r
+import com.smartdevicelink.trace.SmartDeviceLinkTrace;\r
+import com.smartdevicelink.transport.BTTransportConfig;\r
+import com.smartdevicelink.transport.BaseTransportConfig;\r
+import com.smartdevicelink.transport.TransportType;\r
+\r
+public class SmartDeviceLinkProxyALM extends SmartDeviceLinkProxyBase<IProxyListenerALM> {\r
+       \r
+       private static final String SMARTDEVICELINK_LIB_TRACE_KEY = "42baba60-eb57-11df-98cf-0800200c9a66";\r
+       private static final String SMARTDEVICELINK_LIB_PRIVATE_TOKEN = "{DAE1A88C-6C16-4768-ACA5-6F1247EA01C2}";\r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK\r
+        * \r
+        * Takes advantage of the advanced lifecycle management.\r
+        * @param listener - Reference to the object in the App listening to callbacks from SMARTDEVICELINK. \r
+        * @param appName - Name of the application displayed on SMARTDEVICELINK. \r
+        * @param isMediaApp - Indicates if the app is a media application.\r
+        */\r
+       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, String appName, Boolean isMediaApp, \r
+                       Language languageDesired, Language hmiDisplayLanguageDesired, String appID) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               /*smartDeviceLink proxy configuration resources*/null, \r
+                               /*enable advanced lifecycle management*/true, \r
+                               appName,\r
+                               /*TTS Name*/null,\r
+                               /*ngn media app*/null,\r
+                               /*vr synonyms*/null,\r
+                               /*is media app*/isMediaApp,\r
+                               /*smartDeviceLinkMsgVersion*/null,\r
+                               /*language desired*/languageDesired,\r
+                               /*HMI Display Language Desired*/hmiDisplayLanguageDesired,\r
+                               /*App Type*/null,\r
+                               /*App ID*/appID,\r
+                               /*autoActivateID*/null,\r
+                               /*callbackToUIThread*/ false,\r
+                               new BTTransportConfig());\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using legacy constructor for BT transport) instance passing in: IProxyListener, appName, and isMediaApp.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK.\r
+        * \r
+        * Takes advantage of the advanced lifecycle management. \r
+        * \r
+        * @param listener - Reference to the object in the App listening to callbacks from SMARTDEVICELINK. \r
+        * @param appName - Name of the application displayed on SMARTDEVICELINK. \r
+        * @param ngnMediaScreenAppName - Name of the application displayed on SMARTDEVICELINK for Navigation equipped \r
+        * vehicles. Limited to five characters. \r
+        * @param vrSynonyms - A vector of strings, all of which can be used as voice commands to \r
+        * @param isMediaApp - Indicates if the app is a media application.\r
+        * @param smartDeviceLinkMsgVersion - Indicates the version of SMARTDEVICELINK SmartDeviceLink Messages desired. Must be less than\r
+        * or equal to the version of SMARTDEVICELINK SmartDeviceLink running on the vehicle. \r
+        * @param languageDesired - Indicates the language desired for the SMARTDEVICELINK interface.\r
+        * @param autoActivateID - ID used to re-register previously registered application.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, String appName, String ngnMediaScreenAppName, \r
+                       Vector<String> vrSynonyms, Boolean isMediaApp, smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, \r
+                       Language languageDesired, Language hmiDisplayLanguageDesired, String appID, \r
+                       String autoActivateID) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               /*smartDeviceLink proxy configuration resources*/null, \r
+                               /*enable advanced lifecycle management*/true, \r
+                               appName,\r
+                               /*TTS Name*/null,\r
+                               ngnMediaScreenAppName,\r
+                               vrSynonyms,\r
+                               isMediaApp,\r
+                               smartDeviceLinkMsgVersion,\r
+                               languageDesired,\r
+                               /*HMI Display Language Desired*/hmiDisplayLanguageDesired,\r
+                               /*App Type*/null,\r
+                               /*App ID*/appID,\r
+                               autoActivateID,\r
+                               /*callbackToUIThread*/ false,\r
+                               new BTTransportConfig());\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using legacy constructor for BT transport) instance passing in: IProxyListener, appName, ngnMediaScreenAppName, " +\r
+                               "vrSynonyms, isMediaApp, smartDeviceLinkMsgVersion, languageDesired, and autoActivateID.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK.\r
+        * \r
+        * Takes advantage of the advanced lifecycle management. \r
+        * \r
+        * @param listener - Reference to the object in the App listening to callbacks from SMARTDEVICELINK. \r
+        * @param appName - Name of the application displayed on SMARTDEVICELINK. \r
+        * @param ngnMediaScreenAppName - Name of the application displayed on SMARTDEVICELINK for Navigation equipped \r
+        * vehicles. Limited to five characters. \r
+        * @param vrSynonyms - A vector of strings, all of which can be used as voice commands to \r
+        * @param isMediaApp - Indicates if the app is a media application.\r
+        * @param smartDeviceLinkMsgVersion - Indicates the version of SMARTDEVICELINK SmartDeviceLink Messages desired. Must be less than\r
+        * or equal to the version of SMARTDEVICELINK SmartDeviceLink running on the vehicle. \r
+        * @param languageDesired - Indicates the language desired for the SMARTDEVICELINK interface.\r
+        * @param autoActivateID - ID used to re-register previously registered application.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, SmartDeviceLinkProxyConfigurationResources smartDeviceLinkProxyConfigurationResources, \r
+                       String appName, String ngnMediaScreenAppName, Vector<String> vrSynonyms, \r
+                       Boolean isMediaApp, smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, Language languageDesired, \r
+                       Language hmiDisplayLanguageDesired, String appID, String autoActivateID) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               smartDeviceLinkProxyConfigurationResources, \r
+                               /*enable advanced lifecycle management*/true, \r
+                               appName,\r
+                               /*TTS Name*/null,\r
+                               ngnMediaScreenAppName,\r
+                               vrSynonyms,\r
+                               isMediaApp,\r
+                               smartDeviceLinkMsgVersion,\r
+                               languageDesired,\r
+                               /*HMI Display Language Desired*/hmiDisplayLanguageDesired,\r
+                               /*App Type*/null,\r
+                               /*App ID*/appID,\r
+                               autoActivateID,\r
+                               /*callbackToUIThread*/ false,\r
+                               new BTTransportConfig());\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using legacy constructor for BT transport) instance passing in: IProxyListener, smartDeviceLinkProxyConfigurationResources, " +\r
+                               "appName, ngnMediaScreenAppName, vrSynonyms, isMediaApp, smartDeviceLinkMsgVersion, languageDesired, and autoActivateID.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK.\r
+        * \r
+        * Takes advantage of the advanced lifecycle management. \r
+        * \r
+        * @param listener - Reference to the object in the App listening to callbacks from SMARTDEVICELINK. \r
+        * @param appName - Name of the application displayed on SMARTDEVICELINK. \r
+        * @param ngnMediaScreenAppName - Name of the application displayed on SMARTDEVICELINK for Navigation equipped \r
+        * vehicles. Limited to five characters. \r
+        * @param vrSynonyms - A vector of strings, all of which can be used as voice commands to \r
+        * @param isMediaApp - Indicates if the app is a media application.\r
+        * @param smartDeviceLinkMsgVersion - Indicates the version of SMARTDEVICELINK SmartDeviceLink Messages desired. Must be less than\r
+        * or equal to the version of SMARTDEVICELINK SmartDeviceLink running on the vehicle. \r
+        * @param languageDesired - Indicates the language desired for the SMARTDEVICELINK interface.\r
+        * @param autoActivateID - ID used to re-register previously registered application.\r
+        * @param callbackToUIThread - If true, all callbacks will occur on the UI thread.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, String appName, String ngnMediaScreenAppName, \r
+                       Vector<String> vrSynonyms, Boolean isMediaApp, smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, \r
+                       Language languageDesired, Language hmiDisplayLanguageDesired, String appID, \r
+                       String autoActivateID, boolean callbackToUIThread) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               /*smartDeviceLink proxy configuration resources*/null,\r
+                               /*enable advanced lifecycle management*/true, \r
+                               appName,\r
+                               /*TTS Name*/null,\r
+                               ngnMediaScreenAppName,\r
+                               vrSynonyms,\r
+                               isMediaApp,\r
+                               smartDeviceLinkMsgVersion,\r
+                               languageDesired,\r
+                               /*HMI Display Language Desired*/hmiDisplayLanguageDesired,\r
+                               /*App Type*/null,\r
+                               /*App ID*/appID,\r
+                               autoActivateID,\r
+                               callbackToUIThread,\r
+                               new BTTransportConfig());\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using legacy constructor for BT transport) instance passing in: IProxyListener, " +\r
+                               "appName, ngnMediaScreenAppName, vrSynonyms, isMediaApp, smartDeviceLinkMsgVersion, languageDesired, autoActivateID, " +\r
+                               "and callbackToUIThread", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK.\r
+        * \r
+        * Takes advantage of the advanced lifecycle management. \r
+        * \r
+        * @param listener - Reference to the object in the App listening to callbacks from SMARTDEVICELINK. \r
+        * @param appName - Name of the application displayed on SMARTDEVICELINK. \r
+        * @param ngnMediaScreenAppName - Name of the application displayed on SMARTDEVICELINK for Navigation equipped \r
+        * vehicles. Limited to five characters. \r
+        * @param vrSynonyms - A vector of strings, all of which can be used as voice commands to \r
+        * @param isMediaApp - Indicates if the app is a media application.\r
+        * @param smartDeviceLinkMsgVersion - Indicates the version of SMARTDEVICELINK SmartDeviceLink Messages desired. Must be less than\r
+        * or equal to the version of SMARTDEVICELINK SmartDeviceLink running on the vehicle. \r
+        * @param languageDesired - Indicates the language desired for the SMARTDEVICELINK interface.\r
+        * @param autoActivateID - ID used to re-register previously registered application.\r
+        * @param callbackToUIThread - If true, all callbacks will occur on the UI thread.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, SmartDeviceLinkProxyConfigurationResources smartDeviceLinkProxyConfigurationResources, \r
+                       String appName, String ngnMediaScreenAppName, Vector<String> vrSynonyms, Boolean isMediaApp, \r
+                       smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, Language languageDesired, Language hmiDisplayLanguageDesired, \r
+                       String appID, String autoActivateID, \r
+                       boolean callbackToUIThread) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               smartDeviceLinkProxyConfigurationResources,\r
+                               /*enable advanced lifecycle management*/true, \r
+                               appName,\r
+                               /*TTS Name*/null,\r
+                               ngnMediaScreenAppName,\r
+                               vrSynonyms,\r
+                               isMediaApp,\r
+                               smartDeviceLinkMsgVersion,\r
+                               languageDesired,\r
+                               /*HMI Display Language Desired*/hmiDisplayLanguageDesired,\r
+                               /*App Type*/null,\r
+                               /*App ID*/appID,\r
+                               autoActivateID,\r
+                               callbackToUIThread,\r
+                               new BTTransportConfig());\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using legacy constructor for BT transport) instance passing in: IProxyListener, smartDeviceLinkProxyConfigurationResources, " +\r
+                               "appName, ngnMediaScreenAppName, vrSynonyms, isMediaApp, smartDeviceLinkMsgVersion, languageDesired, autoActivateID, " +\r
+                               "and callbackToUIThread", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, SmartDeviceLinkProxyConfigurationResources smartDeviceLinkProxyConfigurationResources, \r
+                       String appName, String ngnMediaScreenAppName, Vector<String> vrSynonyms, Boolean isMediaApp, \r
+                       smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, Language languageDesired, Language hmiDisplayLanguageDesired, \r
+                       String appID, String autoActivateID, boolean callbackToUIThread, boolean preRegister) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               smartDeviceLinkProxyConfigurationResources,\r
+                               /*enable advanced lifecycle management*/true, \r
+                               appName,\r
+                               /*TTS Name*/null,\r
+                               ngnMediaScreenAppName,\r
+                               vrSynonyms,\r
+                               isMediaApp,\r
+                               smartDeviceLinkMsgVersion,\r
+                               languageDesired,\r
+                               /*HMI Display Language Desired*/hmiDisplayLanguageDesired,\r
+                               /*App Type*/null,\r
+                               /*App ID*/appID,\r
+                               autoActivateID,\r
+                               callbackToUIThread,\r
+                               preRegister,\r
+                               new BTTransportConfig());\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using legacy constructor for BT transport) instance passing in: IProxyListener, smartDeviceLinkProxyConfigurationResources, " +\r
+                               "appName, ngnMediaScreenAppName, vrSynonyms, isMediaApp, smartDeviceLinkMsgVersion, languageDesired, autoActivateID, " +\r
+                               "callbackToUIThread and version", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       /********************************************** TRANSPORT SWITCHING SUPPORT *****************************************/\r
+\r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK via specified transport.\r
+        * \r
+        * Takes advantage of the advanced lifecycle management.\r
+        * \r
+        * @param listener Reference to the object in the App listening to callbacks from SMARTDEVICELINK. \r
+        * @param appName Name of the application displayed on SMARTDEVICELINK. \r
+        * @param isMediaApp Indicates if the app is a media application.\r
+        * @param transportConfig Initial configuration for transport.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, String appName, Boolean isMediaApp, \r
+                       Language languageDesired, Language hmiDisplayLanguageDesired, String appID,\r
+                       BaseTransportConfig transportConfig) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               /*smartDeviceLink proxy configuration resources*/null, \r
+                               /*enable advanced lifecycle management*/true, \r
+                               appName,\r
+                               /*TTS Name*/null,\r
+                               /*ngn media app*/null,\r
+                               /*vr synonyms*/null,\r
+                               /*is media app*/isMediaApp,\r
+                               /*smartDeviceLinkMsgVersion*/null,\r
+                               /*language desired*/languageDesired,\r
+                               /*HMI Display Language Desired*/hmiDisplayLanguageDesired,\r
+                               /*App Type*/null,\r
+                               /*App ID*/appID,\r
+                               /*autoActivateID*/null,\r
+                               /*callbackToUIThread*/ false,\r
+                               transportConfig);\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using new constructor with specified transport) instance passing in: IProxyListener, appName, and isMediaApp.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK via specified transport.\r
+        * \r
+        * Takes advantage of the advanced lifecycle management. \r
+        * \r
+        * @param listener Reference to the object in the App listening to callbacks from SMARTDEVICELINK. \r
+        * @param appName Name of the application displayed on SMARTDEVICELINK. \r
+        * @param ngnMediaScreenAppName Name of the application displayed on SMARTDEVICELINK for Navigation equipped \r
+        * vehicles. Limited to five characters. \r
+        * @param vrSynonyms A vector of strings, all of which can be used as voice commands to \r
+        * @param isMediaApp Indicates if the app is a media application.\r
+        * @param smartDeviceLinkMsgVersion Indicates the version of SMARTDEVICELINK SmartDeviceLink Messages desired. Must be less than\r
+        * or equal to the version of SMARTDEVICELINK SmartDeviceLink running on the vehicle. \r
+        * @param languageDesired Indicates the language desired for the SMARTDEVICELINK interface.\r
+        * @param autoActivateID ID used to re-register previously registered application.\r
+        * @param transportConfig Initial configuration for transport. \r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, String appName, String ngnMediaScreenAppName, \r
+                       Vector<String> vrSynonyms, Boolean isMediaApp, smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, \r
+                       Language languageDesired, Language hmiDisplayLanguageDesired, String appID, \r
+                       String autoActivateID, TransportType transportType, BaseTransportConfig transportConfig) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               /*smartDeviceLink proxy configuration resources*/null, \r
+                               /*enable advanced lifecycle management*/true, \r
+                               appName,\r
+                               /*TTS Name*/null,\r
+                               ngnMediaScreenAppName,\r
+                               vrSynonyms,\r
+                               isMediaApp,\r
+                               smartDeviceLinkMsgVersion,\r
+                               languageDesired,\r
+                               /*HMI Display Language Desired*/hmiDisplayLanguageDesired,\r
+                               /*App Type*/null,\r
+                               /*App ID*/appID,\r
+                               autoActivateID,\r
+                               /*callbackToUIThread*/ false,\r
+                               transportConfig);\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using new constructor with specified transport) instance passing in: IProxyListener, appName, ngnMediaScreenAppName, " +\r
+                               "vrSynonyms, isMediaApp, smartDeviceLinkMsgVersion, languageDesired, and autoActivateID.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK via specified transport.\r
+        * \r
+        * Takes advantage of the advanced lifecycle management. \r
+        * \r
+        * @param listener Reference to the object in the App listening to callbacks from SMARTDEVICELINK. \r
+        * @param appName Name of the application displayed on SMARTDEVICELINK. \r
+        * @param ngnMediaScreenAppName Name of the application displayed on SMARTDEVICELINK for Navigation equipped \r
+        * vehicles. Limited to five characters. \r
+        * @param vrSynonyms A vector of strings, all of which can be used as voice commands to \r
+        * @param isMediaApp Indicates if the app is a media application.\r
+        * @param smartDeviceLinkMsgVersion Indicates the version of SMARTDEVICELINK SmartDeviceLink Messages desired. Must be less than\r
+        * or equal to the version of SMARTDEVICELINK SmartDeviceLink running on the vehicle. \r
+        * @param languageDesired Indicates the language desired for the SMARTDEVICELINK interface.\r
+        * @param autoActivateID ID used to re-register previously registered application.\r
+        * @param transportConfig Initial configuration for transport. \r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, SmartDeviceLinkProxyConfigurationResources smartDeviceLinkProxyConfigurationResources, \r
+                       String appName, String ngnMediaScreenAppName, Vector<String> vrSynonyms, \r
+                       Boolean isMediaApp, smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, Language languageDesired, \r
+                       Language hmiDisplayLanguageDesired, String appID, String autoActivateID,\r
+                       BaseTransportConfig transportConfig) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               smartDeviceLinkProxyConfigurationResources, \r
+                               /*enable advanced lifecycle management*/true, \r
+                               appName,\r
+                               /*TTS Name*/null,\r
+                               ngnMediaScreenAppName,\r
+                               vrSynonyms,\r
+                               isMediaApp,\r
+                               smartDeviceLinkMsgVersion,\r
+                               languageDesired,\r
+                               /*HMI Display Language Desired*/hmiDisplayLanguageDesired,\r
+                               /*App Type*/null,\r
+                               /*App ID*/appID,\r
+                               autoActivateID,\r
+                               /*callbackToUIThread*/ false,\r
+                               transportConfig);\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using new constructor with specified transport) instance passing in: IProxyListener, smartDeviceLinkProxyConfigurationResources, " +\r
+                               "appName, ngnMediaScreenAppName, vrSynonyms, isMediaApp, smartDeviceLinkMsgVersion, languageDesired, and autoActivateID.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK via specified transport.\r
+        * \r
+        * Takes advantage of the advanced lifecycle management. \r
+        * \r
+        * @param listener Reference to the object in the App listening to callbacks from SMARTDEVICELINK. \r
+        * @param appName Name of the application displayed on SMARTDEVICELINK. \r
+        * @param ngnMediaScreenAppName Name of the application displayed on SMARTDEVICELINK for Navigation equipped \r
+        * vehicles. Limited to five characters. \r
+        * @param vrSynonyms A vector of strings, all of which can be used as voice commands to \r
+        * @param isMediaApp Indicates if the app is a media application.\r
+        * @param smartDeviceLinkMsgVersion Indicates the version of SMARTDEVICELINK SmartDeviceLink Messages desired. Must be less than\r
+        * or equal to the version of SMARTDEVICELINK SmartDeviceLink running on the vehicle. \r
+        * @param languageDesired Indicates the language desired for the SMARTDEVICELINK interface.\r
+        * @param autoActivateID ID used to re-register previously registered application.\r
+        * @param callbackToUIThread If true, all callbacks will occur on the UI thread.\r
+        * @param transportConfig Initial configuration for transport. \r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, String appName, String ngnMediaScreenAppName, \r
+                       Vector<String> vrSynonyms, Boolean isMediaApp, smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, \r
+                       Language languageDesired, Language hmiDisplayLanguageDesired, String appID, \r
+                       String autoActivateID, boolean callbackToUIThread, \r
+                       BaseTransportConfig transportConfig) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               /*smartDeviceLink proxy configuration resources*/null,\r
+                               /*enable advanced lifecycle management*/true, \r
+                               appName,\r
+                               /*TTS Name*/null,\r
+                               ngnMediaScreenAppName,\r
+                               vrSynonyms,\r
+                               isMediaApp,\r
+                               smartDeviceLinkMsgVersion,\r
+                               languageDesired,\r
+                               /*HMI Display Language Desired*/hmiDisplayLanguageDesired,\r
+                               /*App Type*/null,\r
+                               /*App ID*/appID,\r
+                               autoActivateID,\r
+                               callbackToUIThread,\r
+                               transportConfig);\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using new constructor with specified transport) instance passing in: IProxyListener, " +\r
+                               "appName, ngnMediaScreenAppName, vrSynonyms, isMediaApp, smartDeviceLinkMsgVersion, languageDesired, autoActivateID, " +\r
+                               "and callbackToUIThread", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK via specified transport.\r
+        * \r
+        * Takes advantage of the advanced lifecycle management. \r
+        * \r
+        * @param listener Reference to the object in the App listening to callbacks from SMARTDEVICELINK. \r
+        * @param appName Name of the application displayed on SMARTDEVICELINK. \r
+        * @param ngnMediaScreenAppName Name of the application displayed on SMARTDEVICELINK for Navigation equipped \r
+        * vehicles. Limited to five characters.\r
+        * @param vrSynonyms A vector of strings, all of which can be used as voice commands too\r
+        * @param isMediaApp Indicates if the app is a media application.\r
+        * @param smartDeviceLinkMsgVersion Indicates the version of SMARTDEVICELINK SmartDeviceLink Messages desired. Must be less than\r
+        * or equal to the version of SMARTDEVICELINK SmartDeviceLink running on the vehicle. \r
+        * @param languageDesired Indicates the language desired for the SMARTDEVICELINK interface.\r
+        * @param autoActivateID ID used to re-register previously registered application.\r
+        * @param callbackToUIThread If true, all callbacks will occur on the UI thread.\r
+        * @param transportConfig Initial configuration for transport. \r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, SmartDeviceLinkProxyConfigurationResources smartDeviceLinkProxyConfigurationResources, \r
+                       String appName, String ngnMediaScreenAppName, Vector<String> vrSynonyms, Boolean isMediaApp, \r
+                       smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, Language languageDesired, Language hmiDisplayLanguageDesired, \r
+                       String appID, String autoActivateID, \r
+                       boolean callbackToUIThread, BaseTransportConfig transportConfig) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               smartDeviceLinkProxyConfigurationResources,\r
+                               /*enable advanced lifecycle management*/true, \r
+                               appName,\r
+                               /*TTS Name*/null,\r
+                               ngnMediaScreenAppName,\r
+                               vrSynonyms,\r
+                               isMediaApp,\r
+                               smartDeviceLinkMsgVersion,\r
+                               languageDesired,\r
+                               /*HMI Display Language Desired*/hmiDisplayLanguageDesired,\r
+                               /*App Type*/null,\r
+                               /*App ID*/appID,\r
+                               autoActivateID,\r
+                               callbackToUIThread,\r
+                               transportConfig);\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using new constructor with specified transport) instance passing in: IProxyListener, smartDeviceLinkProxyConfigurationResources, " +\r
+                               "appName, ngnMediaScreenAppName, vrSynonyms, isMediaApp, smartDeviceLinkMsgVersion, languageDesired, autoActivateID, " +\r
+                               "and callbackToUIThread", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+\r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK via specified transport.\r
+        * \r
+        * Takes advantage of the advanced lifecycle management. \r
+        * \r
+        * @param listener Reference to the object in the App listening to callbacks from SMARTDEVICELINK.\r
+        * @param smartDeviceLinkProxyConfigurationResources Proxy configuration resources.\r
+        * @param appName Name of the application displayed on SMARTDEVICELINK.\r
+        * @param ngnMediaScreenAppName Name of the application displayed on SMARTDEVICELINK for Navigation equipped \r
+        * vehicles. Limited to five characters.\r
+        * @param vrSynonyms A vector of strings, all of which can be used as voice commands too\r
+        * @param isMediaApp Indicates if the app is a media application.\r
+        * @param smartDeviceLinkMsgVersion Indicates the version of SMARTDEVICELINK SmartDeviceLink Messages desired. Must be less than\r
+        * or equal to the version of SMARTDEVICELINK SmartDeviceLink running on the vehicle.\r
+        * @param languageDesired Indicates the language desired for the SMARTDEVICELINK interface.\r
+        * @param hmiDisplayLanguageDesired Desired language in HMI.\r
+        * @param appID Identifier of the client application.\r
+        * @param autoActivateID ID used to re-register previously registered application.\r
+        * @param callbackToUIThread If true, all callbacks will occur on the UI thread.\r
+        * @param preRegister Flag that indicates that client should be pre-registred or not\r
+        * @param transportConfig Initial configuration for transport. \r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, SmartDeviceLinkProxyConfigurationResources smartDeviceLinkProxyConfigurationResources, \r
+                       String appName, String ngnMediaScreenAppName, Vector<String> vrSynonyms, Boolean isMediaApp, \r
+                       smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, Language languageDesired, Language hmiDisplayLanguageDesired, \r
+                       String appID, String autoActivateID, boolean callbackToUIThread, boolean preRegister,\r
+                       BaseTransportConfig transportConfig) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               smartDeviceLinkProxyConfigurationResources,\r
+                               /*enable advanced lifecycle management*/true, \r
+                               appName,\r
+                               /*TTS Name*/null,\r
+                               ngnMediaScreenAppName,\r
+                               vrSynonyms,\r
+                               isMediaApp,\r
+                               smartDeviceLinkMsgVersion,\r
+                               languageDesired,\r
+                               /*HMI Display Language Desired*/hmiDisplayLanguageDesired,\r
+                               /*App Type*/null,\r
+                               /*App ID*/appID,\r
+                               autoActivateID,\r
+                               callbackToUIThread,\r
+                               preRegister,\r
+                               transportConfig);\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using new constructor with specified transport) instance passing in: IProxyListener, smartDeviceLinkProxyConfigurationResources, " +\r
+                               "appName, ngnMediaScreenAppName, vrSynonyms, isMediaApp, smartDeviceLinkMsgVersion, languageDesired, autoActivateID, " +\r
+                               "callbackToUIThread and version", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+\r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK via specified transport.\r
+        * \r
+        * Takes advantage of the advanced lifecycle management. \r
+        * \r
+        * @param listener Reference to the object in the App listening to callbacks from SMARTDEVICELINK.\r
+        * @param appName Name of the application displayed on SMARTDEVICELINK.\r
+        * @param isMediaApp Indicates if the app is a media application.\r
+        * @param languageDesired Indicates the language desired for the SMARTDEVICELINK interface.\r
+        * @param hmiDisplayLanguageDesired Desired language in HMI.\r
+        * @param appID Identifier of the client application.\r
+        * @param callbackToUIThread If true, all callbacks will occur on the UI thread.\r
+        * @param preRegister Flag that indicates that client should be pre-registred or not\r
+        * @throws SmartDeviceLinkException\r
+        */     \r
+       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, String appName, Boolean isMediaApp,Language languageDesired, Language hmiDisplayLanguageDesired,\r
+                                               String appID, boolean callbackToUIThread, boolean preRegister) throws SmartDeviceLinkException \r
+       {\r
+               super(  listener, \r
+                       /*smartDeviceLinkProxyConfigurationResources*/null,\r
+                       /*enable advanced lifecycle management*/true, \r
+                       appName,\r
+                       /*ttsName*/null,\r
+                       /*ngnMediaScreenAppName*/null,\r
+                       /*vrSynonyms*/null,\r
+                       isMediaApp,\r
+                       /*smartDeviceLinkMsgVersion*/null,\r
+                       languageDesired,\r
+                       hmiDisplayLanguageDesired,\r
+                       /*App Type*/null,\r
+                       /*App ID*/appID,\r
+                       /*autoActivateID*/null,\r
+                       callbackToUIThread,\r
+                       preRegister,\r
+                       new BTTransportConfig());\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using legacy constructor for BT transport) instance passing in: IProxyListener, " +\r
+                       "appName, isMediaApp, languageDesired, hmiDisplayLanguageDesired" + "callbackToUIThread and version", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK via specified transport.\r
+        * \r
+        * Takes advantage of the advanced lifecycle management. \r
+        * \r
+        * @param listener Reference to the object in the App listening to callbacks from SMARTDEVICELINK.\r
+        * @param appName Name of the application displayed on SMARTDEVICELINK.\r
+        * @param isMediaApp Indicates if the app is a media application.\r
+        * @param appID Identifier of the client application.\r
+        * @throws SmartDeviceLinkException\r
+        */             \r
+       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, String appName, Boolean isMediaApp,String appID) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               /*smartDeviceLinkProxyConfigurationResources*/null,\r
+                               /*enable advanced lifecycle management*/true, \r
+                               appName,\r
+                               /*ttsName*/null,\r
+                               /*ngnMediaScreenAppName*/null,\r
+                               /*vrSynonyms*/null,\r
+                               isMediaApp,\r
+                               /*smartDeviceLinkMsgVersion*/null,\r
+                               /*languageDesired*/null,\r
+                               /*hmiDisplayLanguageDesired*/null,\r
+                               /*App Type*/null,\r
+                               /*App ID*/appID,\r
+                               /*autoActivateID*/null,\r
+                               false,\r
+                               false,\r
+                               new BTTransportConfig());\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using legacy constructor for BT transport) instance passing in: IProxyListener, " +\r
+                               "appName, isMediaApp, appID", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+\r
+       \r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK via specified transport.\r
+        * \r
+        * Takes advantage of the advanced lifecycle management. \r
+        * \r
+        * @param listener Reference to the object in the App listening to callbacks from SMARTDEVICELINK.\r
+        * @param appName Name of the application displayed on SMARTDEVICELINK.\r
+        * @param isMediaApp Indicates if the app is a media application.\r
+        * @param appID Identifier of the client application.\r
+        * @param callbackToUIThread If true, all callbacks will occur on the UI thread.\r
+        * @param preRegister Flag that indicates that client should be pre-registred or not\r
+        * @throws SmartDeviceLinkException\r
+        */             \r
+       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, String appName, Boolean isMediaApp,String appID, \r
+                                                boolean callbackToUIThread, boolean preRegister) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               /*smartDeviceLinkProxyConfigurationResources*/null,\r
+                               /*enable advanced lifecycle management*/true, \r
+                               appName,\r
+                               /*ttsName*/null,\r
+                               /*ngnMediaScreenAppName*/null,\r
+                               /*vrSynonyms*/null,\r
+                               isMediaApp,\r
+                               /*smartDeviceLinkMsgVersion*/null,\r
+                               /*languageDesired*/null,\r
+                               /*hmiDisplayLanguageDesired*/null,\r
+                               /*App Type*/null,\r
+                               /*App ID*/appID,\r
+                               /*autoActivateID*/null,\r
+                               callbackToUIThread,\r
+                               preRegister,\r
+                               new BTTransportConfig());\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using legacy constructor for BT transport) instance passing in: IProxyListener, " +\r
+                               "appName, isMediaApp, " + "callbackToUIThread and version", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+\r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK via specified transport.\r
+        * \r
+        * Takes advantage of the advanced lifecycle management. \r
+        * @param appService Reference to the apps service object. \r
+        * @param listener Reference to the object in the App listening to callbacks from SMARTDEVICELINK.\r
+        * @param smartDeviceLinkProxyConfigurationResources Proxy configuration resources.\r
+        * @param appName Name of the application displayed on SMARTDEVICELINK.\r
+        * @param ttsName TTS name.\r
+        * @param ngnMediaScreenAppName Name of the application displayed on SMARTDEVICELINK for Navigation equipped \r
+        * vehicles. Limited to five characters.\r
+        * @param vrSynonyms A vector of strings, all of which can be used as voice commands too\r
+        * @param isMediaApp Indicates if the app is a media application.\r
+        * @param smartDeviceLinkMsgVersion Indicates the version of SMARTDEVICELINK SmartDeviceLink Messages desired. Must be less than\r
+        * or equal to the version of SMARTDEVICELINK SmartDeviceLink running on the vehicle.\r
+        * @param languageDesired Indicates the language desired for the SMARTDEVICELINK interface.\r
+        * @param hmiDisplayLanguageDesired Desired language in HMI.\r
+        * @param appID Identifier of the client application.\r
+        * @param autoActivateID ID used to re-register previously registered application.\r
+        * @param callbackToUIThread If true, all callbacks will occur on the UI thread.\r
+        * @param preRegister Flag that indicates that client should be pre-registred or not\r
+        * @throws SmartDeviceLinkException\r
+        */     \r
+       public SmartDeviceLinkProxyALM(Service appService, IProxyListenerALM listener, SmartDeviceLinkProxyConfigurationResources smartDeviceLinkProxyConfigurationResources, \r
+                       String appName, Vector<TTSChunk> ttsName, String ngnMediaScreenAppName, Vector<String> vrSynonyms, Boolean isMediaApp, \r
+                       smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, Language languageDesired, Language hmiDisplayLanguageDesired, \r
+                       String appID, String autoActivateID, boolean callbackToUIThread, boolean preRegister) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               smartDeviceLinkProxyConfigurationResources,\r
+                               /*enable advanced lifecycle management*/true, \r
+                               appName,\r
+                               ttsName,\r
+                               ngnMediaScreenAppName,\r
+                               vrSynonyms,\r
+                               isMediaApp,\r
+                               smartDeviceLinkMsgVersion,\r
+                               languageDesired,\r
+                               /*HMI Display Language Desired*/hmiDisplayLanguageDesired,\r
+                               /*App Type*/null,\r
+                               /*App ID*/appID,\r
+                               autoActivateID,\r
+                               callbackToUIThread,\r
+                               preRegister,\r
+                               new BTTransportConfig());\r
+               \r
+                               this.setAppService(appService);\r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using legacy constructor for BT transport) instance passing in: IProxyListener, smartDeviceLinkProxyConfigurationResources, " +\r
+                               "appName, ngnMediaScreenAppName, vrSynonyms, isMediaApp, smartDeviceLinkMsgVersion, languageDesired, autoActivateID, " +\r
+                               "callbackToUIThread and version", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       \r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK via specified transport.\r
+        * \r
+        * Takes advantage of the advanced lifecycle management. \r
+        * \r
+        * @param listener Reference to the object in the App listening to callbacks from SMARTDEVICELINK.\r
+        * @param smartDeviceLinkProxyConfigurationResources Proxy configuration resources.\r
+        * @param appName Name of the application displayed on SMARTDEVICELINK.\r
+        * @param ttsName TTS name.\r
+        * @param ngnMediaScreenAppName Name of the application displayed on SMARTDEVICELINK for Navigation equipped \r
+        * vehicles. Limited to five characters.\r
+        * @param vrSynonyms A vector of strings, all of which can be used as voice commands too\r
+        * @param isMediaApp Indicates if the app is a media application.\r
+        * @param smartDeviceLinkMsgVersion Indicates the version of SMARTDEVICELINK SmartDeviceLink Messages desired. Must be less than\r
+        * or equal to the version of SMARTDEVICELINK SmartDeviceLink running on the vehicle.\r
+        * @param languageDesired Indicates the language desired for the SMARTDEVICELINK interface.\r
+        * @param hmiDisplayLanguageDesired Desired language in HMI.\r
+        * @param appID Identifier of the client application.\r
+        * @param autoActivateID ID used to re-register previously registered application.\r
+        * @param callbackToUIThread If true, all callbacks will occur on the UI thread.\r
+        * @param preRegister Flag that indicates that client should be pre-registred or not\r
+        * @throws SmartDeviceLinkException\r
+        */     \r
+       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, SmartDeviceLinkProxyConfigurationResources smartDeviceLinkProxyConfigurationResources, \r
+                       String appName, Vector<TTSChunk> ttsName, String ngnMediaScreenAppName, Vector<String> vrSynonyms, Boolean isMediaApp, \r
+                       smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, Language languageDesired, Language hmiDisplayLanguageDesired, \r
+                       String appID, String autoActivateID, boolean callbackToUIThread, boolean preRegister) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               smartDeviceLinkProxyConfigurationResources,\r
+                               /*enable advanced lifecycle management*/true, \r
+                               appName,\r
+                               ttsName,\r
+                               ngnMediaScreenAppName,\r
+                               vrSynonyms,\r
+                               isMediaApp,\r
+                               smartDeviceLinkMsgVersion,\r
+                               languageDesired,\r
+                               /*HMI Display Language Desired*/hmiDisplayLanguageDesired,\r
+                               /*App Type*/null,\r
+                               /*App ID*/appID,\r
+                               autoActivateID,\r
+                               callbackToUIThread,\r
+                               preRegister,\r
+                               new BTTransportConfig());\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using legacy constructor for BT transport) instance passing in: IProxyListener, smartDeviceLinkProxyConfigurationResources, " +\r
+                               "appName, ngnMediaScreenAppName, vrSynonyms, isMediaApp, smartDeviceLinkMsgVersion, languageDesired, autoActivateID, " +\r
+                               "callbackToUIThread and version", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+\r
+               \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK via specified transport.\r
+        * \r
+        * Takes advantage of the advanced lifecycle management. \r
+        * \r
+        * @param listener Reference to the object in the App listening to callbacks from SMARTDEVICELINK.\r
+        * @param smartDeviceLinkProxyConfigurationResources Proxy configuration resources.\r
+        * @param appName Name of the application displayed on SMARTDEVICELINK.\r
+        * @param ttsName TTS name.\r
+        * @param ngnMediaScreenAppName Name of the application displayed on SMARTDEVICELINK for Navigation equipped \r
+        * vehicles. Limited to five characters.\r
+        * @param vrSynonyms A vector of strings, all of which can be used as voice commands too\r
+        * @param isMediaApp Indicates if the app is a media application.\r
+        * @param smartDeviceLinkMsgVersion Indicates the version of SMARTDEVICELINK SmartDeviceLink Messages desired. Must be less than\r
+        * or equal to the version of SMARTDEVICELINK SmartDeviceLink running on the vehicle.\r
+        * @param languageDesired Indicates the language desired for the SMARTDEVICELINK interface.\r
+        * @param hmiDisplayLanguageDesired Desired language in HMI.\r
+        * @param appID Identifier of the client application.\r
+        * @param autoActivateID ID used to re-register previously registered application.\r
+        * @param callbackToUIThread If true, all callbacks will occur on the UI thread.\r
+        * @param preRegister Flag that indicates that client should be pre-registred or not\r
+        * @param transportConfig Initial configuration for transport. \r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, SmartDeviceLinkProxyConfigurationResources smartDeviceLinkProxyConfigurationResources, \r
+                       String appName, Vector<TTSChunk> ttsName, String ngnMediaScreenAppName, Vector<String> vrSynonyms, Boolean isMediaApp, \r
+                       smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, Language languageDesired, Language hmiDisplayLanguageDesired, \r
+                       String appID, String autoActivateID, boolean callbackToUIThread, boolean preRegister,\r
+                       BaseTransportConfig transportConfig) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               smartDeviceLinkProxyConfigurationResources,\r
+                               /*enable advanced lifecycle management*/true, \r
+                               appName,\r
+                               ttsName,\r
+                               ngnMediaScreenAppName,\r
+                               vrSynonyms,\r
+                               isMediaApp,\r
+                               smartDeviceLinkMsgVersion,\r
+                               languageDesired,\r
+                               /*HMI Display Language Desired*/hmiDisplayLanguageDesired,\r
+                               /*App Type*/null,\r
+                               /*App ID*/appID,\r
+                               autoActivateID,\r
+                               callbackToUIThread,\r
+                               preRegister,\r
+                               transportConfig);\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using new constructor with specified transport) instance passing in: IProxyListener, smartDeviceLinkProxyConfigurationResources, " +\r
+                               "appName, ngnMediaScreenAppName, vrSynonyms, isMediaApp, smartDeviceLinkMsgVersion, languageDesired, autoActivateID, " +\r
+                               "callbackToUIThread and version", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }               \r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK via specified transport.\r
+        * \r
+        * Takes advantage of the advanced lifecycle management. \r
+        * \r
+        * @param listener Reference to the object in the App listening to callbacks from SMARTDEVICELINK.\r
+        * @param smartDeviceLinkProxyConfigurationResources Proxy configuration resources.\r
+        * @param appName Name of the application displayed on SMARTDEVICELINK.\r
+        * @param ttsName TTS name.\r
+        * @param ngnMediaScreenAppName Name of the application displayed on SMARTDEVICELINK for Navigation equipped \r
+        * vehicles. Limited to five characters.\r
+        * @param vrSynonyms A vector of strings, all of which can be used as voice commands too\r
+        * @param isMediaApp Indicates if the app is a media application.\r
+        * @param smartDeviceLinkMsgVersion Indicates the version of SMARTDEVICELINK SmartDeviceLink Messages desired. Must be less than\r
+        * or equal to the version of SMARTDEVICELINK SmartDeviceLink running on the vehicle.\r
+        * @param languageDesired Indicates the language desired for the SMARTDEVICELINK interface.\r
+        * @param hmiDisplayLanguageDesired Desired language in HMI. \r
+        * @param appType Type of application. \r
+        * @param appID Identifier of the client application.\r
+        * @param autoActivateID ID used to re-register previously registered application.\r
+        * @param callbackToUIThread If true, all callbacks will occur on the UI thread.\r
+        * @param preRegister Flag that indicates that client should be pre-registred or not\r
+        * @throws SmartDeviceLinkException\r
+        */     \r
+       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, SmartDeviceLinkProxyConfigurationResources smartDeviceLinkProxyConfigurationResources, \r
+                       String appName, Vector<TTSChunk> ttsName, String ngnMediaScreenAppName, Vector<String> vrSynonyms, Boolean isMediaApp, \r
+                       smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, Language languageDesired, Language hmiDisplayLanguageDesired, \r
+                       Vector<AppHMIType> appType, String appID, String autoActivateID, boolean callbackToUIThread, boolean preRegister) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               smartDeviceLinkProxyConfigurationResources,\r
+                               /*enable advanced lifecycle management*/true, \r
+                               appName,\r
+                               ttsName,\r
+                               ngnMediaScreenAppName,\r
+                               vrSynonyms,\r
+                               isMediaApp,\r
+                               smartDeviceLinkMsgVersion,\r
+                               languageDesired,\r
+                               /*HMI Display Language Desired*/hmiDisplayLanguageDesired,\r
+                               /*App Type*/appType,\r
+                               /*App ID*/appID,\r
+                               autoActivateID,\r
+                               callbackToUIThread,\r
+                               preRegister,\r
+                               new BTTransportConfig());\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using legacy constructor for BT transport) instance passing in: IProxyListener, smartDeviceLinkProxyConfigurationResources, " +\r
+                               "appName, ngnMediaScreenAppName, vrSynonyms, isMediaApp, smartDeviceLinkMsgVersion, languageDesired, appType, appID, autoActivateID, " +\r
+                               "callbackToUIThread and version", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }       \r
+       \r
+       /**\r
+        * Constructor for the SmartDeviceLinkProxy object, the proxy for communicating between the App and SMARTDEVICELINK via specified transport.\r
+        * \r
+        * Takes advantage of the advanced lifecycle management. \r
+        * \r
+        * @param listener Reference to the object in the App listening to callbacks from SMARTDEVICELINK.\r
+        * @param smartDeviceLinkProxyConfigurationResources Proxy configuration resources.\r
+        * @param appName Name of the application displayed on SMARTDEVICELINK.\r
+        * @param ttsName TTS name.\r
+        * @param ngnMediaScreenAppName Name of the application displayed on SMARTDEVICELINK for Navigation equipped \r
+        * vehicles. Limited to five characters.\r
+        * @param vrSynonyms A vector of strings, all of which can be used as voice commands too\r
+        * @param isMediaApp Indicates if the app is a media application.\r
+        * @param smartDeviceLinkMsgVersion Indicates the version of SMARTDEVICELINK SmartDeviceLink Messages desired. Must be less than\r
+        * or equal to the version of SMARTDEVICELINK SmartDeviceLink running on the vehicle.\r
+        * @param languageDesired Indicates the language desired for the SMARTDEVICELINK interface.\r
+        * @param hmiDisplayLanguageDesired Desired language in HMI.\r
+        * @param appType Type of application.\r
+        * @param appID Identifier of the client application.\r
+        * @param autoActivateID ID used to re-register previously registered application.\r
+        * @param callbackToUIThread If true, all callbacks will occur on the UI thread.\r
+        * @param preRegister Flag that indicates that client should be pre-registred or not\r
+        * @param transportConfig Initial configuration for transport. \r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public SmartDeviceLinkProxyALM(IProxyListenerALM listener, SmartDeviceLinkProxyConfigurationResources smartDeviceLinkProxyConfigurationResources, \r
+                       String appName, Vector<TTSChunk> ttsName, String ngnMediaScreenAppName, Vector<String> vrSynonyms, Boolean isMediaApp, \r
+                       smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, Language languageDesired, Language hmiDisplayLanguageDesired, Vector<AppHMIType> appType, \r
+                       String appID, String autoActivateID, boolean callbackToUIThread, boolean preRegister,\r
+                       BaseTransportConfig transportConfig) throws SmartDeviceLinkException {\r
+               super(  listener, \r
+                               smartDeviceLinkProxyConfigurationResources,\r
+                               /*enable advanced lifecycle management*/true, \r
+                               appName,\r
+                               ttsName,\r
+                               ngnMediaScreenAppName,\r
+                               vrSynonyms,\r
+                               isMediaApp,\r
+                               smartDeviceLinkMsgVersion,\r
+                               languageDesired,\r
+                               /*HMI Display Language Desired*/hmiDisplayLanguageDesired,\r
+                               /*App Type*/appType,\r
+                               /*App ID*/appID,\r
+                               autoActivateID,\r
+                               callbackToUIThread,\r
+                               preRegister,\r
+                               transportConfig);\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application constructed SmartDeviceLinkProxyALM (using new constructor with specified transport) instance passing in: IProxyListener, smartDeviceLinkProxyConfigurationResources, " +\r
+                               "appName, ngnMediaScreenAppName, vrSynonyms, isMediaApp, smartDeviceLinkMsgVersion, languageDesired, appType, appID, autoActivateID, " +\r
+                               "callbackToUIThread and version", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }       \r
+       /***************************************** END OF TRANSPORT SWITCHING SUPPORT ***************************************/\r
+       \r
+       // Allow applications using ALM to reset the proxy (dispose and reinstantiate)\r
+       /**\r
+        * Disconnects the application from SMARTDEVICELINK, then recreates the transport such that\r
+        * the next time a SMARTDEVICELINK unit discovers applications, this application will be\r
+        * available.\r
+        */\r
+       public void resetProxy() throws SmartDeviceLinkException {\r
+               super.cycleProxy(SmartDeviceLinkDisconnectedReason.APPLICATION_REQUESTED_DISCONNECT);\r
+       }\r
+       \r
+       /********* Getters for values returned by RegisterAppInterfaceResponse **********/\r
+       \r
+       /**\r
+        * Gets buttonCapabilities set when application interface is registered.\r
+        * \r
+        * @return buttonCapabilities\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public Vector<ButtonCapabilities> getButtonCapabilities() throws SmartDeviceLinkException{\r
+               // Test if proxy has been disposed\r
+               if (_proxyDisposed) {\r
+                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);\r
+               }\r
+               \r
+               // Test SMARTDEVICELINK availability \r
+               if (!_appInterfaceRegisterd) {\r
+                       throw new SmartDeviceLinkException("SMARTDEVICELINK is unavailable. Unable to get the buttonCapabilities.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);\r
+               }\r
+               return _buttonCapabilities;\r
+       }\r
+       \r
+       /**\r
+        * Gets getSoftButtonCapabilities set when application interface is registered.\r
+        * \r
+        * @return softButtonCapabilities \r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public Vector<SoftButtonCapabilities> getSoftButtonCapabilities() throws SmartDeviceLinkException {\r
+               // Test if proxy has been disposed\r
+               if (_proxyDisposed) {\r
+                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);\r
+               }\r
+               \r
+               // Test SMARTDEVICELINK availability \r
+               if (!_appInterfaceRegisterd) {\r
+                       throw new SmartDeviceLinkException("SMARTDEVICELINK is not connected. Unable to get the softButtonCapabilities.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);\r
+               }\r
+               return _softButtonCapabilities;\r
+       }\r
+       \r
+       /**\r
+        * Gets getPresetBankCapabilities set when application interface is registered.\r
+        * \r
+        * @return presetBankCapabilities \r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public PresetBankCapabilities getPresetBankCapabilities() throws SmartDeviceLinkException {\r
+               // Test if proxy has been disposed\r
+               if (_proxyDisposed) {\r
+                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);\r
+               }\r
+               \r
+               // Test SMARTDEVICELINK availability \r
+               if (!_appInterfaceRegisterd) {\r
+                       throw new SmartDeviceLinkException("SMARTDEVICELINK is not connected. Unable to get the presetBankCapabilities.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);\r
+               }\r
+               return _presetBankCapabilities;\r
+       }\r
+       \r
+       /**\r
+        * Gets the current version information of the proxy.\r
+        * \r
+        * @return String\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public String getProxyVersionInfo() throws SmartDeviceLinkException {\r
+               // Test if proxy has been disposed\r
+               if (_proxyDisposed) {\r
+                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);\r
+               }               \r
+\r
+               if (Version.VERSION != null)\r
+                               return  Version.VERSION;\r
+               \r
+               return null;\r
+       }\r
+\r
+       \r
+       \r
+       /**\r
+        * Gets displayCapabilities set when application interface is registered.\r
+        * \r
+        * @return displayCapabilities\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public DisplayCapabilities getDisplayCapabilities() throws SmartDeviceLinkException {\r
+               // Test if proxy has been disposed\r
+               if (_proxyDisposed) {\r
+                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);\r
+               }\r
+               \r
+               // Test SMARTDEVICELINK availability \r
+               if (!_appInterfaceRegisterd) {\r
+                       throw new SmartDeviceLinkException("SMARTDEVICELINK is unavailable. Unable to get the displayCapabilities.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);\r
+               }\r
+               return _displayCapabilities;\r
+       }\r
+       \r
+       /**\r
+        * Gets hmiZoneCapabilities set when application interface is registered.\r
+        * \r
+        * @return hmiZoneCapabilities\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public Vector<HmiZoneCapabilities> getHmiZoneCapabilities() throws SmartDeviceLinkException {\r
+               // Test if proxy has been disposed\r
+               if (_proxyDisposed) {\r
+                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);\r
+               }\r
+               \r
+               // Test SMARTDEVICELINK availability \r
+               if (!_appInterfaceRegisterd) {\r
+                       throw new SmartDeviceLinkException("SMARTDEVICELINK is unavailable. Unable to get the hmiZoneCapabilities.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);\r
+               }\r
+               return _hmiZoneCapabilities;\r
+       }\r
+       \r
+       /**\r
+        * Gets speechCapabilities set when application interface is registered.\r
+        * \r
+        * @return speechCapabilities\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public Vector<SpeechCapabilities> getSpeechCapabilities() throws SmartDeviceLinkException {\r
+               // Test if proxy has been disposed\r
+               if (_proxyDisposed) {\r
+                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);\r
+               }\r
+               \r
+               // Test SMARTDEVICELINK availability \r
+               if (!_appInterfaceRegisterd) {\r
+                       throw new SmartDeviceLinkException("SMARTDEVICELINK is unavailable. Unable to get the speechCapabilities.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);\r
+               }\r
+               \r
+               return _speechCapabilities;\r
+       }\r
+       \r
+       /**\r
+        * Gets smartDeviceLinkLanguage set when application interface is registered.\r
+        * \r
+        * @return smartDeviceLinkLanguage\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public Language getSmartDeviceLinkLanguage() throws SmartDeviceLinkException {\r
+               // Test if proxy has been disposed\r
+               if (_proxyDisposed) {\r
+                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);\r
+               }\r
+               \r
+               // Test SMARTDEVICELINK availability \r
+               if (!_appInterfaceRegisterd) {\r
+                       throw new SmartDeviceLinkException("SMARTDEVICELINK is unavailable. Unable to get the smartDeviceLinkLanguage.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);\r
+               }\r
+               return _smartDeviceLinkLanguage;\r
+       }\r
+       \r
+       /**\r
+        * Gets getHmiDisplayLanguage set when application interface is registered.\r
+        * \r
+        * @return hmiDisplayLanguage \r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public Language getHmiDisplayLanguage() throws SmartDeviceLinkException {\r
+               // Test if proxy has been disposed\r
+               if (_proxyDisposed) {\r
+                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);\r
+               }\r
+               \r
+               // Test SMARTDEVICELINK availability \r
+               if (!_appInterfaceRegisterd) {\r
+                       throw new SmartDeviceLinkException("SMARTDEVICELINK is not connected. Unable to get the hmiDisplayLanguage.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);\r
+               }\r
+               return _hmiDisplayLanguage;\r
+       }\r
+       \r
+       /**\r
+        * Gets smartDeviceLinkMsgVersion set when application interface is registered.\r
+        * \r
+        * @return smartDeviceLinkMsgVersion\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public smartdevicelinkMsgVersion getsmartdevicelinkMsgVersion() throws SmartDeviceLinkException {\r
+               // Test if proxy has been disposed\r
+               if (_proxyDisposed) {\r
+                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);\r
+               }\r
+               \r
+               // Test SMARTDEVICELINK availability \r
+               if (!_appInterfaceRegisterd) {\r
+                       throw new SmartDeviceLinkException("SMARTDEVICELINK is unavailable. Unable to get the smartDeviceLinkMsgVersion.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);\r
+               }\r
+               return _smartDeviceLinkMsgVersion;\r
+       }\r
+       \r
+       /**\r
+        * Gets vrCapabilities set when application interface is registered.\r
+        * \r
+        * @return vrCapabilities\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public Vector<VrCapabilities> getVrCapabilities() throws SmartDeviceLinkException {\r
+               // Test if proxy has been disposed\r
+               if (_proxyDisposed) {\r
+                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);\r
+               }\r
+               \r
+               // Test SMARTDEVICELINK availability \r
+               if (!_appInterfaceRegisterd) {\r
+                       throw new SmartDeviceLinkException("SMARTDEVICELINK is unavailable. Unable to get the vrCapabilities.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);\r
+               }\r
+               return _vrCapabilities;\r
+       }\r
+       \r
+       /**\r
+        * Gets getVehicleType set when application interface is registered.\r
+        * \r
+        * @return vehicleType \r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public VehicleType getVehicleType() throws SmartDeviceLinkException {\r
+               // Test if proxy has been disposed\r
+               if (_proxyDisposed) {\r
+                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);\r
+               }\r
+               \r
+               // Test SMARTDEVICELINK availability \r
+               if (!_appInterfaceRegisterd) {\r
+                       throw new SmartDeviceLinkException("SMARTDEVICELINK is not connected. Unable to get the vehicleType.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);\r
+               }\r
+               return _vehicleType;\r
+       }\r
+}\r
index fb7ef93..40b4d3b 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy;
-
-import java.util.Hashtable;
-import java.util.Vector;
-
-import android.os.Handler;
-import android.os.Looper;
-import android.telephony.TelephonyManager;
-
-import com.smartdevicelink.exception.SmartDeviceLinkException;
-import com.smartdevicelink.exception.SmartDeviceLinkExceptionCause;
-import com.smartdevicelink.marshal.JsonRPCMarshaller;
-import com.smartdevicelink.messageDispatcher.IDispatchingStrategy;
-import com.smartdevicelink.messageDispatcher.IncomingProtocolMessageComparitor;
-import com.smartdevicelink.messageDispatcher.InternalProxyMessageComparitor;
-import com.smartdevicelink.messageDispatcher.OutgoingProtocolMessageComparitor;
-import com.smartdevicelink.messageDispatcher.ProxyMessageDispatcher;
-import com.smartdevicelink.protocol.ProtocolMessage;
-import com.smartdevicelink.protocol.enums.FunctionID;
-import com.smartdevicelink.protocol.enums.MessageType;
-import com.smartdevicelink.protocol.enums.SessionType;
-import com.smartdevicelink.proxy.callbacks.InternalProxyMessage;
-import com.smartdevicelink.proxy.callbacks.OnProxyClosed;
-import com.smartdevicelink.proxy.callbacks.OnError;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.interfaces.IProxyListenerBase;
-import com.smartdevicelink.proxy.rpc.AddCommand;
-import com.smartdevicelink.proxy.rpc.AddCommandResponse;
-import com.smartdevicelink.proxy.rpc.AddSubMenu;
-import com.smartdevicelink.proxy.rpc.AddSubMenuResponse;
-import com.smartdevicelink.proxy.rpc.Alert;
-import com.smartdevicelink.proxy.rpc.AlertResponse;
-import com.smartdevicelink.proxy.rpc.ButtonCapabilities;
-import com.smartdevicelink.proxy.rpc.Choice;
-import com.smartdevicelink.proxy.rpc.CreateInteractionChoiceSet;
-import com.smartdevicelink.proxy.rpc.CreateInteractionChoiceSetResponse;
-import com.smartdevicelink.proxy.rpc.DeleteCommand;
-import com.smartdevicelink.proxy.rpc.DeleteCommandResponse;
-import com.smartdevicelink.proxy.rpc.DeleteInteractionChoiceSet;
-import com.smartdevicelink.proxy.rpc.DeleteInteractionChoiceSetResponse;
-import com.smartdevicelink.proxy.rpc.DeleteSubMenu;
-import com.smartdevicelink.proxy.rpc.DeleteSubMenuResponse;
-import com.smartdevicelink.proxy.rpc.DisplayCapabilities;
-import com.smartdevicelink.proxy.rpc.EncodedSyncPData;
-import com.smartdevicelink.proxy.rpc.EncodedSyncPDataResponse;
-import com.smartdevicelink.proxy.rpc.GenericResponse;
-import com.smartdevicelink.proxy.rpc.OnAppInterfaceUnregistered;
-import com.smartdevicelink.proxy.rpc.OnButtonEvent;
-import com.smartdevicelink.proxy.rpc.OnButtonPress;
-import com.smartdevicelink.proxy.rpc.OnCommand;
-import com.smartdevicelink.proxy.rpc.OnDriverDistraction;
-import com.smartdevicelink.proxy.rpc.OnEncodedSyncPData;
-import com.smartdevicelink.proxy.rpc.OnHMIStatus;
-import com.smartdevicelink.proxy.rpc.OnPermissionsChange;
-import com.smartdevicelink.proxy.rpc.OnTBTClientState;
-import com.smartdevicelink.proxy.rpc.PerformInteraction;
-import com.smartdevicelink.proxy.rpc.PerformInteractionResponse;
-import com.smartdevicelink.proxy.rpc.RegisterAppInterface;
-import com.smartdevicelink.proxy.rpc.RegisterAppInterfaceResponse;
-import com.smartdevicelink.proxy.rpc.ResetGlobalProperties;
-import com.smartdevicelink.proxy.rpc.ResetGlobalPropertiesResponse;
-import com.smartdevicelink.proxy.rpc.SetGlobalProperties;
-import com.smartdevicelink.proxy.rpc.SetGlobalPropertiesResponse;
-import com.smartdevicelink.proxy.rpc.SetMediaClockTimer;
-import com.smartdevicelink.proxy.rpc.SetMediaClockTimerResponse;
-import com.smartdevicelink.proxy.rpc.Show;
-import com.smartdevicelink.proxy.rpc.ShowResponse;
-import com.smartdevicelink.proxy.rpc.Speak;
-import com.smartdevicelink.proxy.rpc.SpeakResponse;
-import com.smartdevicelink.proxy.rpc.SubscribeButton;
-import com.smartdevicelink.proxy.rpc.SubscribeButtonResponse;
-import com.smartdevicelink.proxy.rpc.SyncMsgVersion;
-import com.smartdevicelink.proxy.rpc.TTSChunk;
-import com.smartdevicelink.proxy.rpc.UnregisterAppInterface;
-import com.smartdevicelink.proxy.rpc.UnregisterAppInterfaceResponse;
-import com.smartdevicelink.proxy.rpc.UnsubscribeButton;
-import com.smartdevicelink.proxy.rpc.UnsubscribeButtonResponse;
-import com.smartdevicelink.proxy.rpc.enums.AudioStreamingState;
-import com.smartdevicelink.proxy.rpc.enums.ButtonName;
-import com.smartdevicelink.proxy.rpc.enums.GlobalProperty;
-import com.smartdevicelink.proxy.rpc.enums.HMILevel;
-import com.smartdevicelink.proxy.rpc.enums.HmiZoneCapabilities;
-import com.smartdevicelink.proxy.rpc.enums.InteractionMode;
-import com.smartdevicelink.proxy.rpc.enums.Language;
-import com.smartdevicelink.proxy.rpc.enums.SpeechCapabilities;
-import com.smartdevicelink.proxy.rpc.enums.SmartDeviceLinkConnectionState;
-import com.smartdevicelink.proxy.rpc.enums.SmartDeviceLinkDisconnectedReason;
-import com.smartdevicelink.proxy.rpc.enums.SmartDeviceLinkInterfaceAvailability;
-import com.smartdevicelink.proxy.rpc.enums.SystemContext;
-import com.smartdevicelink.proxy.rpc.enums.TextAlignment;
-import com.smartdevicelink.proxy.rpc.enums.UpdateMode;
-import com.smartdevicelink.proxy.rpc.enums.VrCapabilities;
-import com.smartdevicelink.syncConnection.ISmartDeviceLinkConnectionListener;
-import com.smartdevicelink.syncConnection.SmartDeviceLinkConnection;
-import com.smartdevicelink.trace.TraceDeviceInfo;
-import com.smartdevicelink.trace.SyncTrace;
-import com.smartdevicelink.trace.enums.InterfaceActivityDirection;
-import com.smartdevicelink.transport.BTTransportConfig;
-import com.smartdevicelink.transport.BaseTransportConfig;
-import com.smartdevicelink.transport.SiphonServer;
-import com.smartdevicelink.transport.TransportType;
-import com.smartdevicelink.util.DebugTool;
-
-public abstract class SmartDeviceLinkProxyBase<proxyListenerType extends IProxyListenerBase> {
-       // Used for calls to Android Log class.
-       public static final String TAG = "SmartDeviceLinkProxy";
-       private static final String SMARTDEVICELINK_LIB_TRACE_KEY = "42baba60-eb57-11df-98cf-0800200c9a66";
-       private SmartDeviceLinkConnection _SmartDeviceLinkConnection;
-       private proxyListenerType _proxyListener = null;
-       
-       // Protected Correlation IDs
-       private final int       REGISTER_APP_INTERFACE_CORRELATION_ID = 65529,
-                                               UNREGISTER_APP_INTERFACE_CORRELATION_ID = 65530;
-       
-       // SmartDeviceLinkhronization Objects
-       private static final Object CONNECTION_REFERENCE_LOCK = new Object(),
-                                                               INCOMING_MESSAGE_QUEUE_THREAD_LOCK = new Object(),
-                                                               OUTGOING_MESSAGE_QUEUE_THREAD_LOCK = new Object(),
-                                                               INTERNAL_MESSAGE_QUEUE_THREAD_LOCK = new Object(),
-                                                               APP_INTERFACE_REGISTERED_LOCK = new Object();
-       
-       // RPC Session ID
-       private byte _rpcSessionID = 0;
-       
-       // Device Info for logging
-       private TraceDeviceInfo _traceDeviceInterrogator = null;
-               
-       // Declare Queuing Threads
-       private ProxyMessageDispatcher<ProtocolMessage> _incomingProxyMessageDispatcher;
-       private ProxyMessageDispatcher<ProtocolMessage> _outgoingProxyMessageDispatcher;
-       private ProxyMessageDispatcher<InternalProxyMessage> _internalProxyMessageDispatcher;
-       
-       // Flag indicating if callbacks should be called from UIThread
-       private Boolean _callbackToUIThread = false;
-       // UI Handler
-       private Handler _mainUIHandler = null; 
-       
-       // SmartDeviceLinkProxy Advanced Lifecycle Management
-       protected Boolean _advancedLifecycleManagementEnabled = false;
-       // Parameters passed to the constructor from the app to register an app interface
-       private String _applicationName = null;
-       private String _ngnMediaScreenAppName = null;
-       private Boolean _isMediaApp = null;
-       private Language _SmartDeviceLinkLanguageDesired = null;
-       private String _autoActivateIdDesired = null;
-       private SyncMsgVersion _SyncMsgVersionRequest = null;
-       private Vector<String> _vrSynonyms = null;
-
-       private BaseTransportConfig _transportConfig = null;
-       // Proxy State Variables
-       protected Boolean _appInterfaceRegisterd = false;
-       protected Boolean _haveReceivedFirstFocusLevel = false;
-       protected Boolean _haveReceivedFirstFocusLevelFull = false;
-       protected Boolean _proxyDisposed = false;
-       protected SmartDeviceLinkConnectionState _SmartDeviceLinkConnectionState = null;
-       protected SmartDeviceLinkInterfaceAvailability _SmartDeviceLinkIntefaceAvailablity = null;
-       protected HMILevel _hmiLevel = null;
-       private HMILevel _priorHmiLevel = null;
-       protected AudioStreamingState _audioStreamingState = null;
-       private AudioStreamingState _priorAudioStreamingState = null;
-       protected SystemContext _systemContext = null;
-       // Variables set by RegisterAppInterfaceResponse
-       protected SyncMsgVersion _SyncMsgVersion = null;
-       protected String _autoActivateIdReturned = null;
-       protected Language _SmartDeviceLinkLanguage = null;
-       protected DisplayCapabilities _displayCapabilities = null;
-       protected Vector<ButtonCapabilities> _buttonCapabilities = null;
-       protected Vector<HmiZoneCapabilities> _hmiZoneCapabilities = null;
-       protected Vector<SpeechCapabilities> _speechCapabilities = null;
-       protected Vector<VrCapabilities> _vrCapabilities = null;
-       protected Boolean firstTimeFull = true;
-       
-       protected byte _protocolVersion = 1;
-       
-       // Interface broker
-       private SmartDeviceLinkInterfaceBroker _interfaceBroker = null;
-       
-       // Private Class to Interface with SmartDeviceLinkConnection
-       private class SmartDeviceLinkInterfaceBroker implements ISmartDeviceLinkConnectionListener {
-               
-               @Override
-               public void onTransportDisconnected(String info) {
-                       // proxyOnTransportDisconnect is called to alert the proxy that a requested
-                       // disconnect has completed
-                       
-                       if (_advancedLifecycleManagementEnabled) {
-                               // If ALM, nothing is required to be done here
-                       } else {
-                               // If original model, notify app the proxy is closed so it will delete and reinstanciate 
-                               notifyProxyClosed(info, new SmartDeviceLinkException("Transport disconnected.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE));
-                       }
-               }
-
-               @Override
-               public void onTransportError(String info, Exception e) {
-                       DebugTool.logError("Transport failure: " + info, e);
-                       
-                       if (_advancedLifecycleManagementEnabled) {                      
-                               // Cycle the proxy
-                               cycleProxy(SmartDeviceLinkDisconnectedReason.TRANSPORT_ERROR);
-                       } else {
-                               notifyProxyClosed(info, e);
-                       }
-               }
-
-               @Override
-               public void onProtocolMessageReceived(ProtocolMessage msg) {
-                       try {if (msg.getData().length > 0) queueIncomingMessage(msg);}
-                       catch (Exception e) {}
-                       try {if (msg.getBulkData().length > 0) queueIncomingMessage(msg);}
-                       catch (Exception e) {}
-               }
-
-               @Override
-               public void onProtocolSessionStarted(SessionType sessionType,
-                               byte sessionID, byte version, String correlationID) {
-                       if (_protocolVersion == 1) {
-                               if (version == 2) setProtocolVersion(version);
-                       }
-                       if (sessionType.eq(SessionType.RPC)) {                  
-                               startRPCProtocolSession(sessionID, correlationID);
-                       } else if (_protocolVersion == 2) {
-                               //If version 2 then don't need to specify a Session Type
-                               startRPCProtocolSession(sessionID, correlationID);
-                       }  else {
-                               // Handle other protocol session types here
-                       }
-               }
-
-               @Override
-               public void onProtocolSessionEnded(SessionType sessionType,
-                               byte sessionID, String correlationID) {
-                       // How to handle protocol session ended?
-                               // How should protocol session management occur? 
-               }
-
-               @Override
-               public void onProtocolError(String info, Exception e) {
-                       passErrorToProxyListener(info, e);
-               }
-       }
-
-       protected SmartDeviceLinkProxyBase(proxyListenerType listener, SmartDeviceLinkProxyConfigurationResources SmartDeviceLinkProxyConfigurationResources, 
-                       boolean enableAdvancedLifecycleManagement, String appName, String ngnMediaScreenAppName, 
-                       Vector<String> vrSynonyms, Boolean isMediaApp, SyncMsgVersion SyncMsgVersion, 
-                       Language languageDesired, String autoActivateID, boolean callbackToUIThread,
-                       BaseTransportConfig transportConfig) 
-                       throws SmartDeviceLinkException {
-               
-               _interfaceBroker = new SmartDeviceLinkInterfaceBroker();
-               
-               _callbackToUIThread = callbackToUIThread;
-               
-               if (_callbackToUIThread) {
-                       _mainUIHandler = new Handler(Looper.getMainLooper());
-               }
-               
-               // Set variables for Advanced Lifecycle Management
-               _advancedLifecycleManagementEnabled = enableAdvancedLifecycleManagement;
-               _applicationName = appName;
-               _ngnMediaScreenAppName = ngnMediaScreenAppName;
-               _isMediaApp = isMediaApp;
-               _SyncMsgVersionRequest = SyncMsgVersion;
-               _vrSynonyms = vrSynonyms; 
-               _SmartDeviceLinkLanguageDesired = languageDesired;
-               _autoActivateIdDesired = autoActivateID;
-               _transportConfig = transportConfig;
-               
-               // Test conditions to invalidate the proxy
-               if (listener == null) {
-                       throw new IllegalArgumentException("IProxyListener listener must be provided to instantiate SmartDeviceLinkProxy object.");
-               }
-               if (_advancedLifecycleManagementEnabled) {
-                       if (_applicationName == null ) {
-                               throw new IllegalArgumentException("To use SmartDeviceLinkProxyALM, an application name, appName, must be provided");
-                       }
-                       if (_applicationName.length() < 1 || _applicationName.length() > 100) {
-                               throw new IllegalArgumentException("A provided application name, appName, must be between 1 and 100 characters in length.");
-                       }
-                       if (_isMediaApp == null) {
-                               throw new IllegalArgumentException("isMediaApp must not be null when using SmartDeviceLinkProxyALM.");
-                       }
-               }
-               
-               _proxyListener = listener;
-               
-               // Get information from SmartDeviceLinkProxyConfigurationResources
-               TelephonyManager telephonyManager = null;
-               if (SmartDeviceLinkProxyConfigurationResources != null) {
-                       telephonyManager = SmartDeviceLinkProxyConfigurationResources.getTelephonyManager();
-               } 
-               
-               // Use the telephonyManager to get and log phone info
-               if (telephonyManager != null) {
-                       // Following is not quite thread-safe (because m_traceLogger could test null twice),
-                       // so we need to fix this, but vulnerability (i.e. two instances of listener) is
-                       // likely harmless.
-                       if (_traceDeviceInterrogator == null) {
-                               _traceDeviceInterrogator = new TraceDeviceInfo(SmartDeviceLinkProxyConfigurationResources.getTelephonyManager());
-                       } // end-if
-               } // end-if
-               
-               // Setup Internal ProxyMessage Dispatcher
-               synchronized(INTERNAL_MESSAGE_QUEUE_THREAD_LOCK) {
-                       // Ensure internalProxyMessageDispatcher is null
-                       if (_internalProxyMessageDispatcher != null) {
-                               _internalProxyMessageDispatcher.dispose();
-                               _internalProxyMessageDispatcher = null;
-                       }
-                       
-                       _internalProxyMessageDispatcher = new ProxyMessageDispatcher<InternalProxyMessage>("INTERNAL_MESSAGE_DISPATCHER",
-                                       new InternalProxyMessageComparitor(),
-                                       new IDispatchingStrategy<InternalProxyMessage>() {
-
-                                               @Override
-                                               public void dispatch(InternalProxyMessage message) {
-                                                       dispatchInternalMessage((InternalProxyMessage)message);
-                                               }
-       
-                                               @Override
-                                               public void handleDispatchingError(String info, Exception ex) {
-                                                       handleErrorsFromInternalMessageDispatcher(info, ex);
-                                               }
-       
-                                               @Override
-                                               public void handleQueueingError(String info, Exception ex) {
-                                                       handleErrorsFromInternalMessageDispatcher(info, ex);
-                                               }                       
-                       });
-               }
-               
-               // Setup Incoming ProxyMessage Dispatcher
-               synchronized(INCOMING_MESSAGE_QUEUE_THREAD_LOCK) {
-                       // Ensure incomingProxyMessageDispatcher is null
-                       if (_incomingProxyMessageDispatcher != null) {
-                               _incomingProxyMessageDispatcher.dispose();
-                               _incomingProxyMessageDispatcher = null;
-                       }
-                       
-                       _incomingProxyMessageDispatcher = new ProxyMessageDispatcher<ProtocolMessage>("INCOMING_MESSAGE_DISPATCHER",
-                                       new IncomingProtocolMessageComparitor(),
-                                       new IDispatchingStrategy<ProtocolMessage>() {
-                                               @Override
-                                               public void dispatch(ProtocolMessage message) {
-                                                       dispatchIncomingMessage((ProtocolMessage)message);
-                                               }
-       
-                                               @Override
-                                               public void handleDispatchingError(String info, Exception ex) {
-                                                       handleErrorsFromIncomingMessageDispatcher(info, ex);
-                                               }
-       
-                                               @Override
-                                               public void handleQueueingError(String info, Exception ex) {
-                                                       handleErrorsFromIncomingMessageDispatcher(info, ex);
-                                               }                       
-                       });
-               }
-               
-               // Setup Outgoing ProxyMessage Dispatcher
-               synchronized(OUTGOING_MESSAGE_QUEUE_THREAD_LOCK) {
-                       // Ensure outgoingProxyMessageDispatcher is null
-                       if (_outgoingProxyMessageDispatcher != null) {
-                               _outgoingProxyMessageDispatcher.dispose();
-                               _outgoingProxyMessageDispatcher = null;
-                       }
-                       
-                       _outgoingProxyMessageDispatcher = new ProxyMessageDispatcher<ProtocolMessage>("OUTGOING_MESSAGE_DISPATCHER",
-                                       new OutgoingProtocolMessageComparitor(),
-                                       new IDispatchingStrategy<ProtocolMessage>() {
-                                               @Override
-                                               public void dispatch(ProtocolMessage message) {
-                                                       dispatchOutgoingMessage((ProtocolMessage)message);
-                                               }
-       
-                                               @Override
-                                               public void handleDispatchingError(String info, Exception ex) {
-                                                       handleErrorsFromOutgoingMessageDispatcher(info, ex);
-                                               }
-       
-                                               @Override
-                                               public void handleQueueingError(String info, Exception ex) {
-                                                       handleErrorsFromOutgoingMessageDispatcher(info, ex);
-                                               }
-                       });
-               }
-               
-               // Initialize the proxy
-               try {
-                       initializeProxy();
-               } catch (SmartDeviceLinkException e) {
-                       // Couldn't initialize the proxy 
-                       // Dispose threads and then rethrow exception
-                       
-                       if (_internalProxyMessageDispatcher != null) {
-                               _internalProxyMessageDispatcher.dispose();
-                               _internalProxyMessageDispatcher = null;
-                       }
-                       if (_incomingProxyMessageDispatcher != null) {
-                               _incomingProxyMessageDispatcher.dispose();
-                               _incomingProxyMessageDispatcher = null;
-                       }
-                       if (_outgoingProxyMessageDispatcher != null) {
-                               _outgoingProxyMessageDispatcher.dispose();
-                               _outgoingProxyMessageDispatcher = null;
-                       }
-                       throw e;
-               } 
-               
-               // Trace that ctor has fired
-               SyncTrace.logProxyEvent("SmartDeviceLinkProxy Created, instanceID=" + this.toString(), SMARTDEVICELINK_LIB_TRACE_KEY);
-       }
-       
-       protected SmartDeviceLinkProxyBase(proxyListenerType listener, SmartDeviceLinkProxyConfigurationResources SmartDeviceLinkProxyConfigurationResources, 
-                       boolean enableAdvancedLifecycleManagement, String appName, String ngnMediaScreenAppName, 
-                       Vector<String> vrSynonyms, Boolean isMediaApp, SyncMsgVersion SyncMsgVersion, 
-                       Language languageDesired, String autoActivateID, boolean callbackToUIThread) 
-                       throws SmartDeviceLinkException {
-               
-               _interfaceBroker = new SmartDeviceLinkInterfaceBroker();
-               
-               _callbackToUIThread = callbackToUIThread;
-               
-               if (_callbackToUIThread) {
-                       _mainUIHandler = new Handler(Looper.getMainLooper());
-               }
-               
-               // Set variables for Advanced Lifecycle Management
-               _advancedLifecycleManagementEnabled = enableAdvancedLifecycleManagement;
-               _applicationName = appName;
-               _ngnMediaScreenAppName = ngnMediaScreenAppName;
-               _isMediaApp = isMediaApp;
-               _SyncMsgVersionRequest = SyncMsgVersion;
-               _vrSynonyms = vrSynonyms; 
-               _SmartDeviceLinkLanguageDesired = languageDesired;
-               _autoActivateIdDesired = autoActivateID;
-               _transportConfig = new BTTransportConfig();
-               
-               // Test conditions to invalidate the proxy
-               if (listener == null) {
-                       throw new IllegalArgumentException("IProxyListener listener must be provided to instantiate SmartDeviceLinkProxy object.");
-               }
-               if (_advancedLifecycleManagementEnabled) {
-                       if (_applicationName == null ) {
-                               throw new IllegalArgumentException("To use SmartDeviceLinkProxyALM, an application name, appName, must be provided");
-                       }
-                       if (_applicationName.length() < 1 || _applicationName.length() > 100) {
-                               throw new IllegalArgumentException("A provided application name, appName, must be between 1 and 100 characters in length.");
-                       }
-                       if (_isMediaApp == null) {
-                               throw new IllegalArgumentException("isMediaApp must not be null when using SmartDeviceLinkProxyALM.");
-                       }
-               }
-               
-               _proxyListener = listener;
-               
-               // Get information from SmartDeviceLinkProxyConfigurationResources
-               TelephonyManager telephonyManager = null;
-               if (SmartDeviceLinkProxyConfigurationResources != null) {
-                       telephonyManager = SmartDeviceLinkProxyConfigurationResources.getTelephonyManager();
-               } 
-               
-               // Use the telephonyManager to get and log phone info
-               if (telephonyManager != null) {
-                       // Following is not quite thread-safe (because m_traceLogger could test null twice),
-                       // so we need to fix this, but vulnerability (i.e. two instances of listener) is
-                       // likely harmless.
-                       if (_traceDeviceInterrogator == null) {
-                               _traceDeviceInterrogator = new TraceDeviceInfo(SmartDeviceLinkProxyConfigurationResources.getTelephonyManager());
-                       } // end-if
-               } // end-if
-               
-               // Setup Internal ProxyMessage Dispatcher
-               synchronized(INTERNAL_MESSAGE_QUEUE_THREAD_LOCK) {
-                       // Ensure internalProxyMessageDispatcher is null
-                       if (_internalProxyMessageDispatcher != null) {
-                               _internalProxyMessageDispatcher.dispose();
-                               _internalProxyMessageDispatcher = null;
-                       }
-                       
-                       _internalProxyMessageDispatcher = new ProxyMessageDispatcher<InternalProxyMessage>("INTERNAL_MESSAGE_DISPATCHER",
-                                       new InternalProxyMessageComparitor(),
-                                       new IDispatchingStrategy<InternalProxyMessage>() {
-
-                                               @Override
-                                               public void dispatch(InternalProxyMessage message) {
-                                                       dispatchInternalMessage((InternalProxyMessage)message);
-                                               }
-       
-                                               @Override
-                                               public void handleDispatchingError(String info, Exception ex) {
-                                                       handleErrorsFromInternalMessageDispatcher(info, ex);
-                                               }
-       
-                                               @Override
-                                               public void handleQueueingError(String info, Exception ex) {
-                                                       handleErrorsFromInternalMessageDispatcher(info, ex);
-                                               }                       
-                       });
-               }
-               
-               // Setup Incoming ProxyMessage Dispatcher
-               synchronized(INCOMING_MESSAGE_QUEUE_THREAD_LOCK) {
-                       // Ensure incomingProxyMessageDispatcher is null
-                       if (_incomingProxyMessageDispatcher != null) {
-                               _incomingProxyMessageDispatcher.dispose();
-                               _incomingProxyMessageDispatcher = null;
-                       }
-                       
-                       _incomingProxyMessageDispatcher = new ProxyMessageDispatcher<ProtocolMessage>("INCOMING_MESSAGE_DISPATCHER",
-                                       new IncomingProtocolMessageComparitor(),
-                                       new IDispatchingStrategy<ProtocolMessage>() {
-                                               @Override
-                                               public void dispatch(ProtocolMessage message) {
-                                                       dispatchIncomingMessage((ProtocolMessage)message);
-                                               }
-       
-                                               @Override
-                                               public void handleDispatchingError(String info, Exception ex) {
-                                                       handleErrorsFromIncomingMessageDispatcher(info, ex);
-                                               }
-       
-                                               @Override
-                                               public void handleQueueingError(String info, Exception ex) {
-                                                       handleErrorsFromIncomingMessageDispatcher(info, ex);
-                                               }                       
-                       });
-               }
-               
-               // Setup Outgoing ProxyMessage Dispatcher
-               synchronized(OUTGOING_MESSAGE_QUEUE_THREAD_LOCK) {
-                       // Ensure outgoingProxyMessageDispatcher is null
-                       if (_outgoingProxyMessageDispatcher != null) {
-                               _outgoingProxyMessageDispatcher.dispose();
-                               _outgoingProxyMessageDispatcher = null;
-                       }
-                       
-                       _outgoingProxyMessageDispatcher = new ProxyMessageDispatcher<ProtocolMessage>("OUTGOING_MESSAGE_DISPATCHER",
-                                       new OutgoingProtocolMessageComparitor(),
-                                       new IDispatchingStrategy<ProtocolMessage>() {
-                                               @Override
-                                               public void dispatch(ProtocolMessage message) {
-                                                       dispatchOutgoingMessage((ProtocolMessage)message);
-                                               }
-       
-                                               @Override
-                                               public void handleDispatchingError(String info, Exception ex) {
-                                                       handleErrorsFromOutgoingMessageDispatcher(info, ex);
-                                               }
-       
-                                               @Override
-                                               public void handleQueueingError(String info, Exception ex) {
-                                                       handleErrorsFromOutgoingMessageDispatcher(info, ex);
-                                               }
-                       });
-               }
-               
-               // Initialize the proxy
-               try {
-                       initializeProxy();
-               } catch (SmartDeviceLinkException e) {
-                       // Couldn't initialize the proxy 
-                       // Dispose threads and then rethrow exception
-                       
-                       if (_internalProxyMessageDispatcher != null) {
-                               _internalProxyMessageDispatcher.dispose();
-                               _internalProxyMessageDispatcher = null;
-                       }
-                       if (_incomingProxyMessageDispatcher != null) {
-                               _incomingProxyMessageDispatcher.dispose();
-                               _incomingProxyMessageDispatcher = null;
-                       }
-                       if (_outgoingProxyMessageDispatcher != null) {
-                               _outgoingProxyMessageDispatcher.dispose();
-                               _outgoingProxyMessageDispatcher = null;
-                       }
-                       throw e;
-               } 
-               
-               // Trace that ctor has fired
-               SyncTrace.logProxyEvent("SmartDeviceLinkProxy Created, instanceID=" + this.toString(), SMARTDEVICELINK_LIB_TRACE_KEY);
-       }
-
-       // Test correlationID
-       private boolean isCorrelationIDProtected(Integer correlationID) {
-               if (correlationID != null && 
-                               (REGISTER_APP_INTERFACE_CORRELATION_ID == correlationID
-                                               || UNREGISTER_APP_INTERFACE_CORRELATION_ID == correlationID)) {
-                       return true;
-               }
-               
-               return false;
-       }
-       
-       // Protected isConnected method to allow legacy proxy to poll isConnected state
-       public Boolean getIsConnected() {
-               return _SmartDeviceLinkConnection.getIsConnected();
-       }
-       
-       
-       // Function to initialize new proxy connection
-       private void initializeProxy() throws SmartDeviceLinkException {                
-               // Reset all of the flags and state variables
-               _haveReceivedFirstFocusLevel = false;
-               _haveReceivedFirstFocusLevelFull = false;
-               _SmartDeviceLinkIntefaceAvailablity = SmartDeviceLinkInterfaceAvailability.SMARTDEVICELINK_INTERFACE_UNAVAILABLE;
-               
-               // Setup SmartDeviceLinkConnection
-               synchronized(CONNECTION_REFERENCE_LOCK) {
-                       if (_SmartDeviceLinkConnection != null) {
-                               _SmartDeviceLinkConnection.closeConnection(_rpcSessionID);
-                               _SmartDeviceLinkConnection = null;
-                       }
-                       _SmartDeviceLinkConnection = new SmartDeviceLinkConnection(_interfaceBroker, _transportConfig);
-               }
-               
-               synchronized(CONNECTION_REFERENCE_LOCK) {
-                       if (_SmartDeviceLinkConnection != null) {
-                               _SmartDeviceLinkConnection.startTransport();
-                       }
-               }
-       }
-       
-       // Public method to enable the siphon transport
-       public static void enableSiphonDebug() {
-               SiphonServer.enableSiphonServer();
-       }
-       
-       // Public method to disable the Siphon Trace Server
-       public static void disableSiphonDebug() {
-               SiphonServer.disableSiphonServer();
-       }       
-       
-       // Public method to enable the Debug Tool
-       public static void enableDebugTool() {
-               DebugTool.enableDebugTool();
-       }
-       
-       // Public method to disable the Debug Tool
-       public static void disableDebugTool() {
-               DebugTool.disableDebugTool();
-       }       
-
-       @Deprecated
-       public void close() throws SmartDeviceLinkException {
-               dispose();
-       }
-       
-       private void cleanProxy(SmartDeviceLinkDisconnectedReason disconnectedReason) throws SmartDeviceLinkException {
-               try {
-                       
-                       // ALM Specific Cleanup
-                       if (_advancedLifecycleManagementEnabled) {
-                               _SmartDeviceLinkConnectionState = SmartDeviceLinkConnectionState.SMARTDEVICELINK_DISCONNECTED;
-                               
-                               firstTimeFull = true;
-                       
-                               // Should we wait for the interface to be unregistered?
-                               Boolean waitForInterfaceUnregistered = false;
-                               // Unregister app interface
-                               synchronized(CONNECTION_REFERENCE_LOCK) {
-                                       if (_appInterfaceRegisterd == true && _SmartDeviceLinkConnection != null && _SmartDeviceLinkConnection.getIsConnected()) {
-                                               waitForInterfaceUnregistered = true;
-                                               unregisterAppInterfacePrivate(UNREGISTER_APP_INTERFACE_CORRELATION_ID);
-                                       }
-                               }
-                               
-                               // Wait for the app interface to be unregistered
-                               if (waitForInterfaceUnregistered) {
-                                       synchronized(APP_INTERFACE_REGISTERED_LOCK) {
-                                               try {
-                                                       APP_INTERFACE_REGISTERED_LOCK.wait(1000);
-                                               } catch (InterruptedException e) {
-                                                       // Do nothing
-                                               }
-                                       }
-                               }
-                       }
-                       
-                       // Clean up SmartDeviceLink Connection
-                       synchronized(CONNECTION_REFERENCE_LOCK) {
-                               if (_SmartDeviceLinkConnection != null) {
-                                       _SmartDeviceLinkConnection.closeConnection(_rpcSessionID);
-                                       _SmartDeviceLinkConnection = null;
-                               }
-                       }
-               } catch (SmartDeviceLinkException e) {
-                       throw e;
-               } finally {
-                       SyncTrace.logProxyEvent("SmartDeviceLinkProxy cleaned.", SMARTDEVICELINK_LIB_TRACE_KEY);
-               }
-       }
-       
-       /**
-        * Terminates the App's Interface Registration, closes the transport connection, ends the protocol session, and frees any resources used by the proxy.
-        */
-       public void dispose() throws SmartDeviceLinkException
-       {               
-               if (_proxyDisposed) {
-                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);
-               }
-               
-               _proxyDisposed = true;
-               
-               SyncTrace.logProxyEvent("Application called dispose() method.", SMARTDEVICELINK_LIB_TRACE_KEY);
-               
-               try{
-                       // Clean the proxy
-                       cleanProxy(SmartDeviceLinkDisconnectedReason.APPLICATION_REQUESTED_DISCONNECT);
-               
-                       // Close IncomingProxyMessageDispatcher thread
-                       synchronized(INCOMING_MESSAGE_QUEUE_THREAD_LOCK) {
-                               if (_incomingProxyMessageDispatcher != null) {
-                                       _incomingProxyMessageDispatcher.dispose();
-                                       _incomingProxyMessageDispatcher = null;
-                               }
-                       }
-                       
-                       // Close OutgoingProxyMessageDispatcher thread
-                       synchronized(OUTGOING_MESSAGE_QUEUE_THREAD_LOCK) {
-                               if (_outgoingProxyMessageDispatcher != null) {
-                                       _outgoingProxyMessageDispatcher.dispose();
-                                       _outgoingProxyMessageDispatcher = null;
-                               }
-                       }
-                       
-                       // Close InternalProxyMessageDispatcher thread
-                       synchronized(INTERNAL_MESSAGE_QUEUE_THREAD_LOCK) {
-                               if (_internalProxyMessageDispatcher != null) {
-                                       _internalProxyMessageDispatcher.dispose();
-                                       _internalProxyMessageDispatcher = null;
-                               }
-                       }
-                       
-                       _traceDeviceInterrogator = null;
-               } catch (SmartDeviceLinkException e) {
-                       throw e;
-               } finally {
-                       SyncTrace.logProxyEvent("SmartDeviceLinkProxy disposed.", SMARTDEVICELINK_LIB_TRACE_KEY);
-               }
-       } // end-method
-
-       // Method to cycle the proxy, only called in ALM
-       protected void cycleProxy(SmartDeviceLinkDisconnectedReason disconnectedReason) {               
-               try{
-                       cleanProxy(disconnectedReason);
-                       initializeProxy();      
-                       notifyProxyClosed("SmartDeviceLink Proxy Cycled", new SmartDeviceLinkException("SmartDeviceLink Proxy Cycled", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_CYCLED));
-               } catch (SmartDeviceLinkException e) {
-                       switch(e.getSmartDeviceLinkExceptionCause()) {
-                       case BLUETOOTH_DISABLED:
-                               notifyProxyClosed("Bluetooth is disabled. Bluetooth must be enabled to connect to SmartDeviceLink. Reattempt a connection once Bluetooth is enabled.", 
-                                               new SmartDeviceLinkException("Bluetooth is disabled. Bluetooth must be enabled to connect to SmartDeviceLink. Reattempt a connection once Bluetooth is enabled.", SmartDeviceLinkExceptionCause.BLUETOOTH_DISABLED));
-                               break;
-                       case BLUETOOTH_ADAPTER_NULL:
-                               notifyProxyClosed("Cannot locate a Bluetooth adapater. A SmartDeviceLink connection is impossible on this device until a Bluetooth adapter is added.", 
-                                               new SmartDeviceLinkException("Cannot locate a Bluetooth adapater. A SmartDeviceLink connection is impossible on this device until a Bluetooth adapter is added.", SmartDeviceLinkExceptionCause.HEARTBEAT_PAST_DUE));
-                               break;
-                       default :
-                               notifyProxyClosed("Cycling the proxy failed.", e);
-                               break;
-                       }
-               } catch (Exception e) { 
-                       notifyProxyClosed("Cycling the proxy failed.", e);
-               }
-       }
-
-       
-       
-       /************* Functions used by the Message Dispatching Queues ****************/
-       private void dispatchIncomingMessage(ProtocolMessage message) {
-               try{
-                       // Dispatching logic
-                       if (message.getSessionType().equals(SessionType.RPC)) {
-                               try {
-                                       if (_protocolVersion == 1) {
-                                               if (message.getVersion() == 2) setProtocolVersion(message.getVersion());
-                                       }
-                                       
-                                       Hashtable hash = new Hashtable();
-                                       if (_protocolVersion == 2) {
-                                               Hashtable hashTemp = new Hashtable();
-                                               hashTemp.put(Names.correlationID, message.getCorrID());
-                                               if (message.getJsonSize() > 0) {
-                                                       final Hashtable<String, Object> mhash = JsonRPCMarshaller.unmarshall(message.getData());
-                                                       hashTemp.put(Names.parameters, mhash);
-                                               }
-                                               FunctionID functionID = new FunctionID();
-                                               hashTemp.put(Names.function_name, functionID.getFunctionName(message.getFunctionID()));
-                                               if (message.getRPCType() == 0x00) {
-                                                       hash.put(Names.request, hashTemp);
-                                               } else if (message.getRPCType() == 0x01) {
-                                                       hash.put(Names.response, hashTemp);
-                                               } else if (message.getRPCType() == 0x02) {
-                                                       hash.put(Names.notification, hashTemp);
-                                               }
-                                               if (message.getBulkData() != null) hash.put(Names.bulkData, message.getBulkData());
-                                       } else {
-                                               final Hashtable<String, Object> mhash = JsonRPCMarshaller.unmarshall(message.getData());
-                                               hash = mhash;
-                                       }
-                                       handleRPCMessage(hash);                                                 
-                               } catch (final Exception excp) {
-                                       DebugTool.logError("Failure handling protocol message: " + excp.toString(), excp);
-                                       passErrorToProxyListener("Error handing incoming protocol message.", excp);
-                               } // end-catch
-                       } else {
-                               // Handle other protocol message types here
-                       }
-               } catch (final Exception e) {
-                       // Pass error to application through listener 
-                       DebugTool.logError("Error handing proxy event.", e);
-                       passErrorToProxyListener("Error handing incoming protocol message.", e);
-               }
-       }
-       
-       private void setProtocolVersion(byte version) {
-               this._protocolVersion = version;
-       }
-
-       private void handleErrorsFromIncomingMessageDispatcher(String info, Exception e) {
-               passErrorToProxyListener(info, e);
-       }
-       
-       private void dispatchOutgoingMessage(ProtocolMessage message) {
-               synchronized(CONNECTION_REFERENCE_LOCK) {
-                       if (_SmartDeviceLinkConnection != null) {
-                               _SmartDeviceLinkConnection.sendMessage(message);
-                       }
-               }               
-               SyncTrace.logProxyEvent("SmartDeviceLinkProxy sending Protocol Message: " + message.toString(), SMARTDEVICELINK_LIB_TRACE_KEY);
-       }
-       
-       private void handleErrorsFromOutgoingMessageDispatcher(String info, Exception e) {
-               passErrorToProxyListener(info, e);
-       }
-       
-       void dispatchInternalMessage(final InternalProxyMessage message) {
-               try{
-                       if (message.getFunctionName().equals(Names.OnProxyError)) {
-                               final OnError msg = (OnError)message;                   
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onError(msg.getInfo(), msg.getException());
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onError(msg.getInfo(), msg.getException());
-                               }
-                       /**************Start Legacy Specific Call-backs************/
-                       } else if (message.getFunctionName().equals(Names.OnProxyOpened)) {
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       ((IProxyListener)_proxyListener).onProxyOpened();
-                                               }
-                                       });
-                               } else {
-                                       ((IProxyListener)_proxyListener).onProxyOpened();
-                               }
-                       } else if (message.getFunctionName().equals(Names.OnProxyClosed)) {
-                               final OnProxyClosed msg = (OnProxyClosed)message;
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onProxyClosed(msg.getInfo(), msg.getException());
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onProxyClosed(msg.getInfo(), msg.getException());
-                               }
-                       /****************End Legacy Specific Call-backs************/
-                       } else {
-                               // Diagnostics
-                               SyncTrace.logProxyEvent("Unknown RPC Message encountered. Check for an updated version of the SmartDeviceLink Proxy.", SMARTDEVICELINK_LIB_TRACE_KEY);
-                               DebugTool.logError("Unknown RPC Message encountered. Check for an updated version of the SmartDeviceLink Proxy.");
-                       }
-                       
-               SyncTrace.logProxyEvent("Proxy fired callback: " + message.getFunctionName(), SMARTDEVICELINK_LIB_TRACE_KEY);
-               } catch(final Exception e) {
-                       // Pass error to application through listener 
-                       DebugTool.logError("Error handing proxy event.", e);
-                       if (_callbackToUIThread) {
-                               // Run in UI thread
-                               _mainUIHandler.post(new Runnable() {
-                                       @Override
-                                       public void run() {
-                                               _proxyListener.onError("Error handing proxy event.", e);
-                                       }
-                               });
-                       } else {
-                               _proxyListener.onError("Error handing proxy event.", e);
-                       }
-               }
-       }
-       
-       private void handleErrorsFromInternalMessageDispatcher(String info, Exception e) {
-               DebugTool.logError(info, e);
-               // This error cannot be passed to the user, as it indicates an error
-               // in the communication between the proxy and the application.
-               
-               DebugTool.logError("InternalMessageDispatcher failed.", e);
-               
-               // Note, this is the only place where the _proxyListener should be referenced aSmartDeviceLinkhronously,
-               // with an error on the internalMessageDispatcher, we have no other reliable way of 
-               // communicating with the application.
-               notifyProxyClosed("Proxy callback dispatcher is down. Proxy instance is invalid.", e);
-               _proxyListener.onError("Proxy callback dispatcher is down. Proxy instance is invalid.", e);
-       }
-       /************* END Functions used by the Message Dispatching Queues ****************/
-       
-
-       // Private sendPRCRequest method. All RPCRequests are funneled through this method after
-               // error checking. 
-       private void sendRPCRequestPrivate(RPCRequest request) throws SmartDeviceLinkException {
-               SyncTrace.logRPCEvent(InterfaceActivityDirection.Transmit, request, SMARTDEVICELINK_LIB_TRACE_KEY);
-               
-               byte[] msgBytes = JsonRPCMarshaller.marshall(request, _protocolVersion);
-               
-               ProtocolMessage pm = new ProtocolMessage();
-               pm.setData(msgBytes);
-               pm.setSessionID(_rpcSessionID);
-               pm.setMessageType(MessageType.RPC);
-               pm.setSessionType(SessionType.RPC);
-               FunctionID functionID = new FunctionID();
-               pm.setFunctionID(functionID.getFunctionID(request.getFunctionName()));
-               pm.setCorrID(request.getCorrelationID());
-               
-               // Queue this outgoing message
-               synchronized(OUTGOING_MESSAGE_QUEUE_THREAD_LOCK) {
-                       if (_outgoingProxyMessageDispatcher != null) {
-                               _outgoingProxyMessageDispatcher.queueMessage(pm);
-                       }
-               }
-       }
-       
-       private void handleRPCMessage(Hashtable hash) {
-               RPCMessage rpcMsg = new RPCMessage(hash);
-               String functionName = rpcMsg.getFunctionName();
-               String messageType = rpcMsg.getMessageType();
-               
-               if (messageType.equals(Names.response)) {                       
-                       SyncTrace.logRPCEvent(InterfaceActivityDirection.Receive, new RPCResponse(rpcMsg), SMARTDEVICELINK_LIB_TRACE_KEY);
-
-                       // Check to ensure response is not from an internal message (reserved correlation ID)
-                       if (isCorrelationIDProtected((new RPCResponse(hash)).getCorrelationID())) {
-                               // This is a response generated from an internal message, it can be trapped here
-                               // The app should not receive a response for a request it did not send
-                               if ((new RPCResponse(hash)).getCorrelationID() == REGISTER_APP_INTERFACE_CORRELATION_ID 
-                                               && _advancedLifecycleManagementEnabled 
-                                               && functionName.equals(Names.RegisterAppInterface)) {
-                                       final RegisterAppInterfaceResponse msg = new RegisterAppInterfaceResponse(hash);
-                                       if (msg.getSuccess()) {
-                                               _appInterfaceRegisterd = true;
-                                       }
-                                       
-                                       _autoActivateIdReturned = msg.getAutoActivateID();
-                                       _buttonCapabilities = msg.getButtonCapabilities();
-                                       _displayCapabilities = msg.getDisplayCapabilities();
-                                       _hmiZoneCapabilities = msg.getHmiZoneCapabilities();
-                                       _speechCapabilities = msg.getSpeechCapabilities();
-                                       _SmartDeviceLinkLanguage = msg.getLanguage();
-                                       _SyncMsgVersion = msg.getSyncMsgVersion();
-                                       _vrCapabilities = msg.getVrCapabilities();
-                                       
-                                       // Send onSmartDeviceLinkConnected message in ALM
-                                       _SmartDeviceLinkConnectionState = SmartDeviceLinkConnectionState.SMARTDEVICELINK_CONNECTED;
-                                       
-                                       // If registerAppInterface failed, exit with OnProxyUnusable
-                                       if (!msg.getSuccess()) {
-                                               notifyProxyClosed("Unable to register app interface. Review values passed to the SmartDeviceLinkProxy constructor. RegisterAppInterface result code: ", 
-                                                               new SmartDeviceLinkException("Unable to register app interface. Review values passed to the SmartDeviceLinkProxy constructor. RegisterAppInterface result code: " + msg.getResultCode(), SmartDeviceLinkExceptionCause.SMARTDEVICELINK_REGISTRATION_ERROR));
-                                       }
-                               }
-                               return;
-                       }
-                       
-                       if (functionName.equals(Names.RegisterAppInterface)) {
-                               final RegisterAppInterfaceResponse msg = new RegisterAppInterfaceResponse(hash);
-                               if (msg.getSuccess()) {
-                                       _appInterfaceRegisterd = true;
-                               }
-                               
-                               _autoActivateIdReturned = msg.getAutoActivateID();
-                               _buttonCapabilities = msg.getButtonCapabilities();
-                               _displayCapabilities = msg.getDisplayCapabilities();
-                               _hmiZoneCapabilities = msg.getHmiZoneCapabilities();
-                               _speechCapabilities = msg.getSpeechCapabilities();
-                               _SmartDeviceLinkLanguage = msg.getLanguage();
-                               _SyncMsgVersion = msg.getSyncMsgVersion();
-                               _vrCapabilities = msg.getVrCapabilities();
-                               
-                               // RegisterAppInterface
-                               if (_advancedLifecycleManagementEnabled) {
-                                       
-                                       // Send onSmartDeviceLinkConnected message in ALM
-                                       _SmartDeviceLinkConnectionState = SmartDeviceLinkConnectionState.SMARTDEVICELINK_CONNECTED;
-                                       
-                                       // If registerAppInterface failed, exit with OnProxyUnusable
-                                       if (!msg.getSuccess()) {
-                                               notifyProxyClosed("Unable to register app interface. Review values passed to the SmartDeviceLinkProxy constructor. RegisterAppInterface result code: ", 
-                                                               new SmartDeviceLinkException("Unable to register app interface. Review values passed to the SmartDeviceLinkProxy constructor. RegisterAppInterface result code: " + msg.getResultCode(), SmartDeviceLinkExceptionCause.SMARTDEVICELINK_REGISTRATION_ERROR));
-                                       }
-                               } else {        
-                                       if (_callbackToUIThread) {
-                                               // Run in UI thread
-                                               _mainUIHandler.post(new Runnable() {
-                                                       @Override
-                                                       public void run() {
-                                                               ((IProxyListener)_proxyListener).onRegisterAppInterfaceResponse(msg);
-                                                       }
-                                               });
-                                       } else {
-                                               ((IProxyListener)_proxyListener).onRegisterAppInterfaceResponse(msg);                                                   
-                                       }
-                               }
-                       } else if (functionName.equals(Names.Speak)) {
-                               // SpeakResponse
-                               
-                               final SpeakResponse msg = new SpeakResponse(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onSpeakResponse(msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onSpeakResponse(msg);                                            
-                               }
-                       } else if (functionName.equals(Names.Alert)) {
-                               // AlertResponse
-                               
-                               final AlertResponse msg = new AlertResponse(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onAlertResponse(msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onAlertResponse(msg);                                            
-                               }
-                       } else if (functionName.equals(Names.Show)) {
-                               // ShowResponse
-                               
-                               final ShowResponse msg = new ShowResponse(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onShowResponse((ShowResponse)msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onShowResponse((ShowResponse)msg);                                               
-                               }
-                       } else if (functionName.equals(Names.AddCommand)) {
-                               // AddCommand
-                               
-                               final AddCommandResponse msg = new AddCommandResponse(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onAddCommandResponse((AddCommandResponse)msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onAddCommandResponse((AddCommandResponse)msg);                                   
-                               }
-                       } else if (functionName.equals(Names.DeleteCommand)) {
-                               // DeleteCommandResponse
-                               
-                               final DeleteCommandResponse msg = new DeleteCommandResponse(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onDeleteCommandResponse((DeleteCommandResponse)msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onDeleteCommandResponse((DeleteCommandResponse)msg);                                     
-                               }
-                       } else if (functionName.equals(Names.AddSubMenu)) {
-                               // AddSubMenu
-                               
-                               final AddSubMenuResponse msg = new AddSubMenuResponse(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onAddSubMenuResponse((AddSubMenuResponse)msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onAddSubMenuResponse((AddSubMenuResponse)msg);                                   
-                               }
-                       } else if (functionName.equals(Names.DeleteSubMenu)) {
-                               // DeleteSubMenu
-                               
-                               final DeleteSubMenuResponse msg = new DeleteSubMenuResponse(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onDeleteSubMenuResponse((DeleteSubMenuResponse)msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onDeleteSubMenuResponse((DeleteSubMenuResponse)msg);                                     
-                               }
-                       } else if (functionName.equals(Names.SubscribeButton)) {
-                               // SubscribeButton
-                               
-                               final SubscribeButtonResponse msg = new SubscribeButtonResponse(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onSubscribeButtonResponse((SubscribeButtonResponse)msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onSubscribeButtonResponse((SubscribeButtonResponse)msg);                         
-                               }
-                       } else if (functionName.equals(Names.UnsubscribeButton)) {
-                               // UnsubscribeButton
-                               
-                               final UnsubscribeButtonResponse msg = new UnsubscribeButtonResponse(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onUnsubscribeButtonResponse((UnsubscribeButtonResponse)msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onUnsubscribeButtonResponse((UnsubscribeButtonResponse)msg);                     
-                               }
-                       } else if (functionName.equals(Names.SetMediaClockTimer)) {
-                               // SetMediaClockTimer
-                               
-                               final SetMediaClockTimerResponse msg = new SetMediaClockTimerResponse(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onSetMediaClockTimerResponse((SetMediaClockTimerResponse)msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onSetMediaClockTimerResponse((SetMediaClockTimerResponse)msg);           
-                               }
-                       } else if (functionName.equals(Names.EncodedSyncPData)) {
-                               // EncodedSyncPData
-                               
-                               final EncodedSyncPDataResponse msg = new EncodedSyncPDataResponse(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onEncodedSyncPDataResponse(msg); 
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onEncodedSyncPDataResponse(msg);                 
-                               }
-                       } else if (functionName.equals(Names.CreateInteractionChoiceSet)) {
-                               // CreateInteractionChoiceSet
-                               
-                               final CreateInteractionChoiceSetResponse msg = new CreateInteractionChoiceSetResponse(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onCreateInteractionChoiceSetResponse((CreateInteractionChoiceSetResponse)msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onCreateInteractionChoiceSetResponse((CreateInteractionChoiceSetResponse)msg);           
-                               }
-                       } else if (functionName.equals(Names.DeleteInteractionChoiceSet)) {
-                               // DeleteInteractionChoiceSet
-                               
-                               final DeleteInteractionChoiceSetResponse msg = new DeleteInteractionChoiceSetResponse(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onDeleteInteractionChoiceSetResponse((DeleteInteractionChoiceSetResponse)msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onDeleteInteractionChoiceSetResponse((DeleteInteractionChoiceSetResponse)msg);           
-                               }
-                       } else if (functionName.equals(Names.PerformInteraction)) {
-                               // PerformInteraction
-                               
-                               final PerformInteractionResponse msg = new PerformInteractionResponse(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onPerformInteractionResponse((PerformInteractionResponse)msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onPerformInteractionResponse((PerformInteractionResponse)msg);           
-                               }
-                       } else if (functionName.equals(Names.SetGlobalProperties)) {
-                               // SetGlobalPropertiesResponse (can also be Heartbeat)
-                               
-                               final SetGlobalPropertiesResponse msg = new SetGlobalPropertiesResponse(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onSetGlobalPropertiesResponse((SetGlobalPropertiesResponse)msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onSetGlobalPropertiesResponse((SetGlobalPropertiesResponse)msg);         
-                               }
-                       } else if (functionName.equals(Names.ResetGlobalProperties)) {
-                               // ResetGlobalProperties                                
-                               
-                               final ResetGlobalPropertiesResponse msg = new ResetGlobalPropertiesResponse(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onResetGlobalPropertiesResponse((ResetGlobalPropertiesResponse)msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onResetGlobalPropertiesResponse((ResetGlobalPropertiesResponse)msg);             
-                               }
-                       } else if (functionName.equals(Names.UnregisterAppInterface)) {
-                               // UnregisterAppInterface
-                               
-                               _appInterfaceRegisterd = false;
-                               synchronized(APP_INTERFACE_REGISTERED_LOCK) {
-                                       APP_INTERFACE_REGISTERED_LOCK.notify();
-                               }
-                               
-                               final UnregisterAppInterfaceResponse msg = new UnregisterAppInterfaceResponse(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       ((IProxyListener)_proxyListener).onUnregisterAppInterfaceResponse(msg);
-                                               }
-                                       });
-                               } else {
-                                       ((IProxyListener)_proxyListener).onUnregisterAppInterfaceResponse(msg); 
-                               }
-                               
-                               notifyProxyClosed("UnregisterAppInterfaceResponse", null);
-                       } else if (functionName.equals(Names.GenericResponse)) {
-                               // GenericResponse (Usually and error)
-                               final GenericResponse msg = new GenericResponse(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onGenericResponse((GenericResponse)msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onGenericResponse((GenericResponse)msg); 
-                               }
-                       } else {
-                               if (_SyncMsgVersion != null) {
-                                       DebugTool.logError("Unrecognized response Message: " + functionName.toString() + 
-                                                       "SmartDeviceLink Message Version = " + _SyncMsgVersion);
-                               } else {
-                                       DebugTool.logError("Unrecognized response Message: " + functionName.toString());
-                               }
-                       } // end-if
-               } else if (messageType.equals(Names.notification)) {
-                       SyncTrace.logRPCEvent(InterfaceActivityDirection.Receive, new RPCNotification(rpcMsg), SMARTDEVICELINK_LIB_TRACE_KEY);
-                       if (functionName.equals(Names.OnHMIStatus)) {
-                               // OnHMIStatus
-                               
-                               final OnHMIStatus msg = new OnHMIStatus(hash);
-                               msg.setFirstRun(new Boolean(firstTimeFull));
-                               if (msg.getHmiLevel() == HMILevel.HMI_FULL) firstTimeFull = false;
-                               
-                               if (msg.getHmiLevel() != _priorHmiLevel && msg.getAudioStreamingState() != _priorAudioStreamingState) {
-                                       if (_callbackToUIThread) {
-                                               // Run in UI thread
-                                               _mainUIHandler.post(new Runnable() {
-                                                       @Override
-                                                       public void run() {
-                                                               _proxyListener.onOnHMIStatus((OnHMIStatus)msg);
-                                                       }
-                                               });
-                                       } else {
-                                               _proxyListener.onOnHMIStatus((OnHMIStatus)msg);
-                                       }
-                               }
-                       } else if (functionName.equals(Names.OnCommand)) {
-                               // OnCommand
-                               
-                               final OnCommand msg = new OnCommand(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onOnCommand((OnCommand)msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onOnCommand((OnCommand)msg);
-                               }
-                       } else if (functionName.equals(Names.OnDriverDistraction)) {
-                               // OnDriverDistration
-                               
-                               final OnDriverDistraction msg = new OnDriverDistraction(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onOnDriverDistraction(msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onOnDriverDistraction(msg);
-                               }
-                       } else if (functionName.equals(Names.OnEncodedSyncPData)) {
-                               // OnEncodedSyncPData
-                               
-                               final OnEncodedSyncPData msg = new OnEncodedSyncPData(hash);
-                                       
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onOnEncodedSyncPData(msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onOnEncodedSyncPData(msg);
-                               }
-                       } else if (functionName.equals(Names.OnPermissionsChange)) {
-                               //OnPermissionsChange
-                               
-                               final OnPermissionsChange msg = new OnPermissionsChange(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onOnPermissionsChange(msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onOnPermissionsChange(msg);
-                               }
-                       } else if (functionName.equals(Names.OnTBTClientState)) {
-                               // OnTBTClientState
-                               
-                               final OnTBTClientState msg = new OnTBTClientState(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onOnTBTClientState(msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onOnTBTClientState(msg);
-                               }
-                       } else if (functionName.equals(Names.OnButtonPress)) {
-                               // OnButtonPress
-                               
-                               final OnButtonPress msg = new OnButtonPress(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onOnButtonPress((OnButtonPress)msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onOnButtonPress((OnButtonPress)msg);
-                               }
-                       } else if (functionName.equals(Names.OnButtonEvent)) {
-                               // OnButtonEvent
-                               
-                               final OnButtonEvent msg = new OnButtonEvent(hash);
-                               if (_callbackToUIThread) {
-                                       // Run in UI thread
-                                       _mainUIHandler.post(new Runnable() {
-                                               @Override
-                                               public void run() {
-                                                       _proxyListener.onOnButtonEvent((OnButtonEvent)msg);
-                                               }
-                                       });
-                               } else {
-                                       _proxyListener.onOnButtonEvent((OnButtonEvent)msg);
-                               }
-                       } else if (functionName.equals(Names.OnAppInterfaceUnregistered)) {
-                               // OnAppInterfaceUnregistered
-                               
-                               _appInterfaceRegisterd = false;
-                               synchronized(APP_INTERFACE_REGISTERED_LOCK) {
-                                       APP_INTERFACE_REGISTERED_LOCK.notify();
-                               }
-                               
-                               final OnAppInterfaceUnregistered msg = new OnAppInterfaceUnregistered(hash);
-                                                               
-                               if (_advancedLifecycleManagementEnabled) {
-                                       // This requires the proxy to be cycled
-                                       cycleProxy(SmartDeviceLinkDisconnectedReason.convertAppInterfaceUnregisteredReason(msg.getReason()));
-                               } else {
-                                       if (_callbackToUIThread) {
-                                               // Run in UI thread
-                                               _mainUIHandler.post(new Runnable() {
-                                                       @Override
-                                                       public void run() {
-                                                               ((IProxyListener)_proxyListener).onOnAppInterfaceUnregistered(msg);
-                                                       }
-                                               });
-                                       } else {
-                                               ((IProxyListener)_proxyListener).onOnAppInterfaceUnregistered(msg);
-                                       }
-                                       
-                                       notifyProxyClosed("OnAppInterfaceUnregistered", null);
-                               }
-                       }
-                       else {
-                               if (_SyncMsgVersion != null) {
-                                       DebugTool.logInfo("Unrecognized notification Message: " + functionName.toString() + 
-                                                       " connected to SmartDeviceLink using message version: " + _SyncMsgVersion.getMajorVersion() + "." + _SyncMsgVersion.getMinorVersion());
-                               } else {
-                                       DebugTool.logInfo("Unrecognized notification Message: " + functionName.toString());
-                               }
-                       } // end-if
-               } // end-if notification
-               
-               SyncTrace.logProxyEvent("Proxy received RPC Message: " + functionName, SMARTDEVICELINK_LIB_TRACE_KEY);
-       }
-       
-       /**
-        * Takes an RPCRequest and sends it to SmartDeviceLink.  Responses are captured through callback on IProxyListener.  
-        * 
-        * @param msg
-        * @throws SmartDeviceLinkException
-        */
-       public void sendRPCRequest(RPCRequest request) throws SmartDeviceLinkException {
-               if (_proxyDisposed) {
-                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);
-               }
-               
-               // Test if request is null
-               if (request == null) {
-                       SyncTrace.logProxyEvent("Application called sendRPCRequest method with a null RPCRequest.", SMARTDEVICELINK_LIB_TRACE_KEY);
-                       throw new IllegalArgumentException("sendRPCRequest cannot be called with a null request.");
-               }
-               
-               SyncTrace.logProxyEvent("Application called sendRPCRequest method for RPCRequest: ." + request.getFunctionName(), SMARTDEVICELINK_LIB_TRACE_KEY);
-                       
-               // Test if SmartDeviceLinkConnection is null
-               synchronized(CONNECTION_REFERENCE_LOCK) {
-                       if (_SmartDeviceLinkConnection == null || !_SmartDeviceLinkConnection.getIsConnected()) {
-                               SyncTrace.logProxyEvent("Application attempted to send and RPCRequest without a connected transport.", SMARTDEVICELINK_LIB_TRACE_KEY);
-                               throw new SmartDeviceLinkException("There is no valid connection to SmartDeviceLink. sendRPCRequest cannot be called until SmartDeviceLink has been connected.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);
-                       }
-               }
-               
-               // Test for illegal correlation ID
-               if (isCorrelationIDProtected(request.getCorrelationID())) {
-                       
-                       SyncTrace.logProxyEvent("Application attempted to use the reserved correlation ID, " + request.getCorrelationID(), SMARTDEVICELINK_LIB_TRACE_KEY);
-                       throw new SmartDeviceLinkException("Invalid correlation ID. The correlation ID, " + request.getCorrelationID()
-                                       + " , is a reserved correlation ID.", SmartDeviceLinkExceptionCause.RESERVED_CORRELATION_ID);
-               }
-               
-               // Throw exception if RPCRequest is sent when SmartDeviceLink is unavailable 
-               if (!_appInterfaceRegisterd && request.getFunctionName() != Names.RegisterAppInterface) {
-                       
-                       SyncTrace.logProxyEvent("Application attempted to send an RPCRequest (non-registerAppInterface), before the interface was registerd.", SMARTDEVICELINK_LIB_TRACE_KEY);
-                       throw new SmartDeviceLinkException("SmartDeviceLink is currently unavailable. RPC Requests cannot be sent.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);
-               }
-                               
-               if (_advancedLifecycleManagementEnabled) {
-                       if (               request.getFunctionName() == Names.RegisterAppInterface
-                                       || request.getFunctionName() == Names.UnregisterAppInterface) {
-                               
-                               SyncTrace.logProxyEvent("Application attempted to send a RegisterAppInterface or UnregisterAppInterface while using ALM.", SMARTDEVICELINK_LIB_TRACE_KEY);
-                               throw new SmartDeviceLinkException("The RPCRequest, " + request.getFunctionName() + 
-                                               ", is unnallowed using the Advanced Lifecycle Management Model.", SmartDeviceLinkExceptionCause.INCORRECT_LIFECYCLE_MODEL);
-                       }
-               }
-               
-               sendRPCRequestPrivate(request);
-       } // end-method
-       
-       public void sendRPCRequest(RPCMessage request) throws SmartDeviceLinkException {
-               sendRPCRequest((RPCRequest) request);
-       }
-       
-       protected void notifyProxyClosed(final String info, final Exception e) {                
-               SyncTrace.logProxyEvent("NotifyProxyClose", SMARTDEVICELINK_LIB_TRACE_KEY);
-               
-               OnProxyClosed message = new OnProxyClosed(info, e);
-               queueInternalMessage(message);
-       }
-
-       private void passErrorToProxyListener(final String info, final Exception e) {
-                               
-               OnError message = new OnError(info, e);
-               queueInternalMessage(message);
-       }
-       
-       private void startRPCProtocolSession(byte sessionID, String correlationID) {
-               _rpcSessionID = sessionID;
-               
-               // Set Proxy Lifecyclek Available
-               if (_advancedLifecycleManagementEnabled) {
-                       
-                       try {
-                               registerAppInterfacePrivate(
-                                               _SyncMsgVersionRequest,
-                                               _applicationName,
-                                               _ngnMediaScreenAppName,
-                                               _vrSynonyms,
-                                               _isMediaApp, 
-                                               _SmartDeviceLinkLanguageDesired,
-                                               _autoActivateIdDesired,
-                                               REGISTER_APP_INTERFACE_CORRELATION_ID);
-                               
-                       } catch (Exception e) {
-                               notifyProxyClosed("Failed to register application interface with SmartDeviceLink. Check parameter values given to SmartDeviceLinkProxy constructor.", e);
-                       }
-               } else {
-                       InternalProxyMessage message = new InternalProxyMessage(Names.OnProxyOpened);
-                       queueInternalMessage(message);
-               }
-       }
-       
-       // Queue internal callback message
-       private void queueInternalMessage(InternalProxyMessage message) {
-               synchronized(INTERNAL_MESSAGE_QUEUE_THREAD_LOCK) {
-                       if (_internalProxyMessageDispatcher != null) {
-                               _internalProxyMessageDispatcher.queueMessage(message);
-                       }
-               }
-       }
-       
-       // Queue incoming ProtocolMessage
-       private void queueIncomingMessage(ProtocolMessage message) {
-               synchronized(INCOMING_MESSAGE_QUEUE_THREAD_LOCK) {
-                       if (_incomingProxyMessageDispatcher != null) {
-                               _incomingProxyMessageDispatcher.queueMessage(message);
-                       }
-               }
-       }
-
-       /******************** Public Helper Methods *************************/
-       
-       /**
-        *Sends an AddCommand RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        *
-        *@param commandID
-        *@param menuText
-        *@param parentID
-        *@param position
-        *@param vrCommands
-        *@param correlationID
-        *@throws SmartDeviceLinkException
-        */
-       public void addCommand(Integer commandID,
-                       String menuText, Integer parentID, Integer position,
-                       Vector<String> vrCommands, Integer correlationID) 
-                       throws SmartDeviceLinkException {
-               
-               AddCommand msg = RPCRequestFactory.buildAddCommand(commandID, menuText, parentID, position,
-                       vrCommands, correlationID);
-               
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        *Sends an AddCommand RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        *
-        *@param commandID
-        *@param menuText
-        *@param position
-        *@param vrCommands
-        *@param correlationID
-        *@throws SmartDeviceLinkException
-        */
-       public void addCommand(Integer commandID,
-                       String menuText, Integer position,
-                       Vector<String> vrCommands, Integer correlationID) 
-                       throws SmartDeviceLinkException {
-               
-               addCommand(commandID, menuText, null, position, vrCommands, correlationID);
-       }
-       
-       /**
-        *Sends an AddCommand RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        *
-        *@param commandID
-        *@param menuText
-        *@param position
-        *@param correlationID
-        *@throws SmartDeviceLinkException
-        */
-       public void addCommand(Integer commandID,
-                       String menuText, Integer position,
-                       Integer correlationID) 
-                       throws SmartDeviceLinkException {
-               
-               addCommand(commandID, menuText, null, position, null, correlationID);
-       }
-       
-       /**
-        *Sends an AddCommand RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        *
-        *@param commandID
-        *@param menuText
-        *@param correlationID
-        *@throws SmartDeviceLinkException
-        */
-       public void addCommand(Integer commandID,
-                       String menuText, Integer correlationID) 
-                       throws SmartDeviceLinkException {
-               
-               addCommand(commandID, menuText, null, null, null, correlationID);
-       }
-       
-       /**
-        * Sends an AddCommand RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param commandID
-        * @param menuText
-        * @param vrCommands
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void addCommand(Integer commandID,
-                       String menuText, Vector<String> vrCommands, Integer correlationID) 
-                       throws SmartDeviceLinkException {
-               
-               addCommand(commandID, menuText, null, null, vrCommands, correlationID);
-       }
-       
-       /**
-        * Sends an AddCommand RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param commandID
-        * @param vrCommands
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void addCommand(Integer commandID,
-                       Vector<String> vrCommands, Integer correlationID) 
-                       throws SmartDeviceLinkException {
-               
-               addCommand(commandID, null, null, null, vrCommands, correlationID);
-       }
-       
-       /**
-        * Sends an AddSubMenu RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param menuID
-        * @param menuName
-        * @param position
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void addSubMenu(Integer menuID, String menuName,
-                       Integer position, Integer correlationID) 
-                       throws SmartDeviceLinkException {
-               
-               AddSubMenu msg = RPCRequestFactory.buildAddSubMenu(menuID, menuName,
-                               position, correlationID);
-               
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        * Sends an AddSubMenu RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param menuID
-        * @param menuName
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void addSubMenu(Integer menuID, String menuName,
-                       Integer correlationID) throws SmartDeviceLinkException {
-               
-               addSubMenu(menuID, menuName, null, correlationID);
-       }
-       
-       /**
-        * Sends an EncodedData RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param data
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void encodedSmartDeviceLinkPData(Vector<String> data, Integer correlationID) 
-                       throws SmartDeviceLinkException {
-               
-               EncodedSyncPData msg = RPCRequestFactory.buildEncodedSyncPData(data, correlationID);
-
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        * Sends an Alert RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param ttsText
-        * @param alertText1
-        * @param alertText2
-        * @param playTone
-        * @param duration
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void alert(String ttsText, String alertText1,
-                       String alertText2, Boolean playTone, Integer duration,
-                       Integer correlationID) throws SmartDeviceLinkException {
-
-               Alert msg = RPCRequestFactory.buildAlert(ttsText, alertText1, alertText2, 
-                               playTone, duration, correlationID);
-
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        * Sends an Alert RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param ttsChunks
-        * @param alertText1
-        * @param alertText2
-        * @param playTone
-        * @param duration
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void alert(Vector<TTSChunk> ttsChunks,
-                       String alertText1, String alertText2, Boolean playTone,
-                       Integer duration, Integer correlationID) throws SmartDeviceLinkException {
-               
-               Alert msg = RPCRequestFactory.buildAlert(ttsChunks, alertText1, alertText2, playTone,
-                               duration, correlationID);
-
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        * Sends an Alert RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param ttsText
-        * @param playTone
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void alert(String ttsText, Boolean playTone,
-                       Integer correlationID) throws SmartDeviceLinkException {
-               
-               alert(ttsText, null, null, playTone, null, correlationID);
-       }
-       
-       /**
-        * Sends an Alert RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param chunks
-        * @param playTone
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void alert(Vector<TTSChunk> chunks, Boolean playTone,
-                       Integer correlationID) throws SmartDeviceLinkException {
-               
-               alert(chunks, null, null, playTone, null, correlationID);
-       }
-       
-       /**
-        * Sends an Alert RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param alertText1
-        * @param alertText2
-        * @param playTone
-        * @param duration
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void alert(String alertText1, String alertText2,
-                       Boolean playTone, Integer duration, Integer correlationID) 
-                       throws SmartDeviceLinkException {
-               
-               alert((Vector<TTSChunk>)null, alertText1, alertText2, playTone, duration, correlationID);
-       }
-       
-       /**
-        * Sends a CreateInteractionChoiceSet RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param choiceSet
-        * @param interactionChoiceSetID
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void createInteractionChoiceSet(
-                       Vector<Choice> choiceSet, Integer interactionChoiceSetID,
-                       Integer correlationID) throws SmartDeviceLinkException {
-               
-               CreateInteractionChoiceSet msg = RPCRequestFactory.buildCreateInteractionChoiceSet(
-                               choiceSet, interactionChoiceSetID, correlationID);
-
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        * Sends a DeleteCommand RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param commandID
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void deleteCommand(Integer commandID,
-                       Integer correlationID) throws SmartDeviceLinkException {
-               
-               DeleteCommand msg = RPCRequestFactory.buildDeleteCommand(commandID, correlationID);
-
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        * Sends a DeleteInteractionChoiceSet RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param interactionChoiceSetID
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void deleteInteractionChoiceSet(
-                       Integer interactionChoiceSetID, Integer correlationID) 
-                       throws SmartDeviceLinkException {
-               
-               DeleteInteractionChoiceSet msg = RPCRequestFactory.buildDeleteInteractionChoiceSet(
-                               interactionChoiceSetID, correlationID);
-
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        * Sends a DeleteSubMenu RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param menuID
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void deleteSubMenu(Integer menuID,
-                       Integer correlationID) throws SmartDeviceLinkException {
-               
-               DeleteSubMenu msg = RPCRequestFactory.buildDeleteSubMenu(menuID, correlationID);
-
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        * Sends a PerformInteraction RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param initPrompt
-        * @param displayText
-        * @param interactionChoiceSetID
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void performInteraction(String initPrompt,
-                       String displayText, Integer interactionChoiceSetID,
-                       Integer correlationID) throws SmartDeviceLinkException {
-               
-               PerformInteraction msg = RPCRequestFactory.buildPerformInteraction(initPrompt,
-                               displayText, interactionChoiceSetID, correlationID);
-               
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        * Sends a PerformInteraction RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param initPrompt
-        * @param displayText
-        * @param interactionChoiceSetID
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void performInteraction(String initPrompt,
-                       String displayText, Integer interactionChoiceSetID,
-                       String helpPrompt, String timeoutPrompt,
-                       InteractionMode interactionMode, Integer timeout,
-                       Integer correlationID) throws SmartDeviceLinkException {
-               
-               PerformInteraction msg = RPCRequestFactory.buildPerformInteraction(
-                               initPrompt, displayText, interactionChoiceSetID,
-                               helpPrompt, timeoutPrompt, interactionMode, 
-                               timeout, correlationID);
-               
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        * Sends a PerformInteraction RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param initPrompt
-        * @param displayText
-        * @param interactionChoiceSetIDList
-        * @param helpPrompt
-        * @param timeoutPrompt
-        * @param interactionMode
-        * @param timeout
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void performInteraction(String initPrompt,
-                       String displayText, Vector<Integer> interactionChoiceSetIDList,
-                       String helpPrompt, String timeoutPrompt,
-                       InteractionMode interactionMode, Integer timeout,
-                       Integer correlationID) throws SmartDeviceLinkException {
-               
-               PerformInteraction msg = RPCRequestFactory.buildPerformInteraction(initPrompt,
-                               displayText, interactionChoiceSetIDList,
-                               helpPrompt, timeoutPrompt, interactionMode, timeout,
-                               correlationID);
-
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        * Sends a PerformInteraction RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param initChunks
-        * @param displayText
-        * @param interactionChoiceSetIDList
-        * @param helpChunks
-        * @param timeoutChunks
-        * @param interactionMode
-        * @param timeout
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void performInteraction(
-                       Vector<TTSChunk> initChunks, String displayText,
-                       Vector<Integer> interactionChoiceSetIDList,
-                       Vector<TTSChunk> helpChunks, Vector<TTSChunk> timeoutChunks,
-                       InteractionMode interactionMode, Integer timeout,
-                       Integer correlationID) throws SmartDeviceLinkException {
-               
-               PerformInteraction msg = RPCRequestFactory.buildPerformInteraction(
-                               initChunks, displayText, interactionChoiceSetIDList,
-                               helpChunks, timeoutChunks, interactionMode, timeout,
-                               correlationID);
-               
-               sendRPCRequest(msg);
-       }
-       
-       // Protected registerAppInterface used to ensure only non-ALM applications call
-       // reqisterAppInterface
-       protected void registerAppInterfacePrivate(
-                       SyncMsgVersion SyncMsgVersion, String appName, String ngnMediaScreenAppName,
-                       Vector<String> vrSynonyms, Boolean isMediaApp, Language languageDesired, 
-                       String autoActivateID, Integer correlationID) 
-                       throws SmartDeviceLinkException {
-               
-               RegisterAppInterface msg = RPCRequestFactory.buildRegisterAppInterface(
-                               SyncMsgVersion, appName, ngnMediaScreenAppName, vrSynonyms, isMediaApp, 
-                               languageDesired, autoActivateID, correlationID);
-
-               sendRPCRequestPrivate(msg);
-       }
-       
-       /**
-        * Sends a SetGlobalProperties RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param helpPrompt
-        * @param timeoutPrompt
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void setGlobalProperties(
-                       String helpPrompt, String timeoutPrompt, Integer correlationID) 
-               throws SmartDeviceLinkException {
-               
-               SetGlobalProperties req = RPCRequestFactory.buildSetGlobalProperties(helpPrompt, 
-                               timeoutPrompt, correlationID);
-               
-               sendRPCRequest(req);
-       }
-       
-       /**
-        * Sends a SetGlobalProperties RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param helpChunks
-        * @param timeoutChunks
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void setGlobalProperties(
-                       Vector<TTSChunk> helpChunks, Vector<TTSChunk> timeoutChunks,
-                       Integer correlationID) throws SmartDeviceLinkException {
-               
-               SetGlobalProperties req = RPCRequestFactory.buildSetGlobalProperties(
-                               helpChunks, timeoutChunks, correlationID);
-
-               sendRPCRequest(req);
-       }
-       
-       public void resetGlobalProperties(Vector<GlobalProperty> properties,
-                       Integer correlationID) throws SmartDeviceLinkException {
-               
-               ResetGlobalProperties req = new ResetGlobalProperties();
-               
-               req.setCorrelationID(correlationID);
-               req.setProperties(properties);
-               
-               sendRPCRequest(req);
-       }
-                                                               
-       
-       /**
-        * Sends a SetMediaClockTimer RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param hours
-        * @param minutes
-        * @param seconds
-        * @param updateMode
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void setMediaClockTimer(Integer hours,
-                       Integer minutes, Integer seconds, UpdateMode updateMode,
-                       Integer correlationID) throws SmartDeviceLinkException {
-
-               SetMediaClockTimer msg = RPCRequestFactory.buildSetMediaClockTimer(hours,
-                               minutes, seconds, updateMode, correlationID);
-
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        * Pauses the media clock. Responses are captured through callback on IProxyListener.
-        * 
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void pauseMediaClockTimer(Integer correlationID) 
-                       throws SmartDeviceLinkException {
-
-               SetMediaClockTimer msg = RPCRequestFactory.buildSetMediaClockTimer(0,
-                               0, 0, UpdateMode.PAUSE, correlationID);
-
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        * Resumes the media clock. Responses are captured through callback on IProxyListener.
-        * 
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void resumeMediaClockTimer(Integer correlationID) 
-                       throws SmartDeviceLinkException {
-
-               SetMediaClockTimer msg = RPCRequestFactory.buildSetMediaClockTimer(0,
-                               0, 0, UpdateMode.RESUME, correlationID);
-
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        * Clears the media clock. Responses are captured through callback on IProxyListener.
-        * 
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void clearMediaClockTimer(Integer correlationID) 
-                       throws SmartDeviceLinkException {
-
-               Show msg = RPCRequestFactory.buildShow(null, null, null, "     ", null, null, correlationID);
-
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        * Sends a Show RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param mainText1
-        * @param mainText2
-        * @param statusBar
-        * @param mediaClock
-        * @param mediaTrack
-        * @param alignment
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void show(String mainText1, String mainText2,
-                       String statusBar, String mediaClock, String mediaTrack,
-                       TextAlignment alignment, Integer correlationID) 
-                       throws SmartDeviceLinkException {
-               
-               Show msg = RPCRequestFactory.buildShow(mainText1, mainText2,
-                               statusBar, mediaClock, mediaTrack,
-                               alignment, correlationID);
-
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        * Sends a Show RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param mainText1
-        * @param mainText2
-        * @param alignment
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void show(String mainText1, String mainText2,
-                       TextAlignment alignment, Integer correlationID) 
-                       throws SmartDeviceLinkException {
-               
-               show(mainText1, mainText2, null, null, null, alignment, correlationID);
-       }
-       
-       /**
-        * Sends a Speak RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param ttsText
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void speak(String ttsText, Integer correlationID) 
-                       throws SmartDeviceLinkException {
-               
-               Speak msg = RPCRequestFactory.buildSpeak(TTSChunkFactory.createSimpleTTSChunks(ttsText),
-                               correlationID);
-
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        * Sends a Speak RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param ttsChunks
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void speak(Vector<TTSChunk> ttsChunks,
-                       Integer correlationID) throws SmartDeviceLinkException {
-
-               Speak msg = RPCRequestFactory.buildSpeak(ttsChunks, correlationID);
-
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        * Sends a SubscribeButton RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param buttonName
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void subscribeButton(ButtonName buttonName,
-                       Integer correlationID) throws SmartDeviceLinkException {
-
-               SubscribeButton msg = RPCRequestFactory.buildSubscribeButton(buttonName,
-                               correlationID);
-
-               sendRPCRequest(msg);
-       }
-       
-       // Protected unregisterAppInterface used to ensure no non-ALM app calls
-       // unregisterAppInterface.
-       protected void unregisterAppInterfacePrivate(Integer correlationID) 
-               throws SmartDeviceLinkException {
-
-               UnregisterAppInterface msg = 
-                               RPCRequestFactory.buildUnregisterAppInterface(correlationID);
-               
-               sendRPCRequestPrivate(msg);
-       }
-       
-       /**
-        * Sends an UnsubscribeButton RPCRequest to SmartDeviceLink. Responses are captured through callback on IProxyListener.
-        * 
-        * @param buttonName
-        * @param correlationID
-        * @throws SmartDeviceLinkException
-        */
-       public void unsubscribeButton(ButtonName buttonName, 
-                       Integer correlationID) throws SmartDeviceLinkException {
-
-               UnsubscribeButton msg = RPCRequestFactory.buildUnsubscribeButton(
-                               buttonName, correlationID);
-
-               sendRPCRequest(msg);
-       }
-       
-       /**
-        * Creates a choice to be added to a choiceset. Choice has both a voice and a visual menu component.
-        * 
-        * @param choiceID -Unique ID used to identify this choice (returned in callback).
-        * @param choiceMenuName -Text name displayed for this choice.
-        * @param choiceVrCommands -Vector of vrCommands used to select this choice by voice. Must contain
-        *                      at least one non-empty element.
-        * @return Choice created. 
-        * @throws SmartDeviceLinkException 
-        */
-       public Choice createChoiceSetChoice(Integer choiceID, String choiceMenuName,
-                       Vector<String> choiceVrCommands) {              
-               Choice returnChoice = new Choice();
-               
-               returnChoice.setChoiceID(choiceID);
-               returnChoice.setMenuName(choiceMenuName);
-               returnChoice.setVrCommands(choiceVrCommands);
-               
-               return returnChoice;
-       }
-       
-       /******************** END Public Helper Methods *************************/
-
-       public TransportType getCurrentTransportType() throws IllegalStateException {
-               if (_SmartDeviceLinkConnection == null) {
-                       throw new IllegalStateException("Incorrect state of SmartDeviceLinkProxyBase: Calling for getCurrentTransportType() while connection is not initialized");
-               }
-                       
-               return _SmartDeviceLinkConnection.getCurrentTransportType();
-       }
-} // end-class
+package com.smartdevicelink.proxy;\r
+\r
+import java.lang.reflect.Constructor;\r
+import java.lang.reflect.Method;\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import android.app.Service;\r
+import android.content.Context;\r
+import android.content.Intent;\r
+import android.os.Handler;\r
+import android.os.Looper;\r
+import android.telephony.TelephonyManager;\r
+import android.util.Log;\r
+\r
+import com.smartdevicelink.exception.SmartDeviceLinkException;\r
+import com.smartdevicelink.exception.SmartDeviceLinkExceptionCause;\r
+import com.smartdevicelink.marshal.JsonRPCMarshaller;\r
+import com.smartdevicelink.messageDispatcher.IDispatchingStrategy;\r
+import com.smartdevicelink.messageDispatcher.IncomingProtocolMessageComparitor;\r
+import com.smartdevicelink.messageDispatcher.InternalProxyMessageComparitor;\r
+import com.smartdevicelink.messageDispatcher.OutgoingProtocolMessageComparitor;\r
+import com.smartdevicelink.messageDispatcher.ProxyMessageDispatcher;\r
+import com.smartdevicelink.protocol.ProtocolMessage;\r
+import com.smartdevicelink.protocol.SmartDeviceLinkProtocol;\r
+import com.smartdevicelink.protocol.enums.FunctionID;\r
+import com.smartdevicelink.protocol.enums.MessageType;\r
+import com.smartdevicelink.protocol.enums.SessionType;\r
+import com.smartdevicelink.proxy.callbacks.InternalProxyMessage;\r
+import com.smartdevicelink.proxy.callbacks.OnError;\r
+import com.smartdevicelink.proxy.callbacks.OnProxyClosed;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.interfaces.IProxyListenerALM;\r
+import com.smartdevicelink.proxy.interfaces.IProxyListenerBase;\r
+import com.smartdevicelink.proxy.rpc.*;\r
+import com.smartdevicelink.proxy.rpc.enums.AppHMIType;\r
+import com.smartdevicelink.proxy.rpc.enums.AudioStreamingState;\r
+import com.smartdevicelink.proxy.rpc.enums.AudioType;\r
+import com.smartdevicelink.proxy.rpc.enums.BitsPerSample;\r
+import com.smartdevicelink.proxy.rpc.enums.ButtonName;\r
+import com.smartdevicelink.proxy.rpc.enums.FileType;\r
+import com.smartdevicelink.proxy.rpc.enums.GlobalProperty;\r
+import com.smartdevicelink.proxy.rpc.enums.HMILevel;\r
+import com.smartdevicelink.proxy.rpc.enums.HmiZoneCapabilities;\r
+import com.smartdevicelink.proxy.rpc.enums.ImageType;\r
+import com.smartdevicelink.proxy.rpc.enums.InteractionMode;\r
+import com.smartdevicelink.proxy.rpc.enums.Language;\r
+import com.smartdevicelink.proxy.rpc.enums.SamplingRate;\r
+import com.smartdevicelink.proxy.rpc.enums.SpeechCapabilities;\r
+import com.smartdevicelink.proxy.rpc.enums.SmartDeviceLinkConnectionState;\r
+import com.smartdevicelink.proxy.rpc.enums.SmartDeviceLinkDisconnectedReason;\r
+import com.smartdevicelink.proxy.rpc.enums.SmartDeviceLinkInterfaceAvailability;\r
+import com.smartdevicelink.proxy.rpc.enums.SystemContext;\r
+import com.smartdevicelink.proxy.rpc.enums.TextAlignment;\r
+import com.smartdevicelink.proxy.rpc.enums.UpdateMode;\r
+import com.smartdevicelink.proxy.rpc.enums.VrCapabilities;\r
+import com.smartdevicelink.smartDeviceLinkConnection.IsmartDeviceLinkConnectionListener;\r
+import com.smartdevicelink.smartDeviceLinkConnection.smartDeviceLinkConnection;\r
+import com.smartdevicelink.trace.SmartDeviceLinkTrace;\r
+import com.smartdevicelink.trace.TraceDeviceInfo;\r
+import com.smartdevicelink.trace.enums.InterfaceActivityDirection;\r
+import com.smartdevicelink.transport.BaseTransportConfig;\r
+import com.smartdevicelink.transport.SiphonServer;\r
+import com.smartdevicelink.transport.TransportType;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+public abstract class SmartDeviceLinkProxyBase<proxyListenerType extends IProxyListenerBase> {\r
+       // Used for calls to Android Log class.\r
+       public static final String TAG = "SmartDeviceLinkProxy";\r
+       private static final String SMARTDEVICELINK_LIB_TRACE_KEY = "42baba60-eb57-11df-98cf-0800200c9a66";\r
+       private static final int PROX_PROT_VER_ONE = 1;\r
+       \r
+       private smartDeviceLinkConnection _smartDeviceLinkConnection;\r
+       private proxyListenerType _proxyListener = null;\r
+       \r
+       protected Service _appService = null;\r
+       \r
+       // Protected Correlation IDs\r
+       private final int       REGISTER_APP_INTERFACE_CORRELATION_ID = 65529,\r
+                                               UNREGISTER_APP_INTERFACE_CORRELATION_ID = 65530,\r
+                                               POLICIES_CORRELATION_ID = 65535;\r
+       \r
+       // SmartDeviceLinkhronization Objects\r
+       private static final Object CONNECTION_REFERENCE_LOCK = new Object(),\r
+                                                               INCOMING_MESSAGE_QUEUE_THREAD_LOCK = new Object(),\r
+                                                               OUTGOING_MESSAGE_QUEUE_THREAD_LOCK = new Object(),\r
+                                                               INTERNAL_MESSAGE_QUEUE_THREAD_LOCK = new Object(),\r
+                                                               APP_INTERFACE_REGISTERED_LOCK = new Object();\r
+               \r
+       // RPC Session ID\r
+       private byte _rpcSessionID = 0;\r
+       \r
+       private int iFileCount = 0;\r
+\r
+       // Device Info for logging\r
+       private TraceDeviceInfo _traceDeviceInterrogator = null;\r
+               \r
+       // Declare Queuing Threads\r
+       private ProxyMessageDispatcher<ProtocolMessage> _incomingProxyMessageDispatcher;\r
+       private ProxyMessageDispatcher<ProtocolMessage> _outgoingProxyMessageDispatcher;\r
+       private ProxyMessageDispatcher<InternalProxyMessage> _internalProxyMessageDispatcher;\r
+       \r
+       // Flag indicating if callbacks should be called from UIThread\r
+       private Boolean _callbackToUIThread = false;\r
+       // UI Handler\r
+       private Handler _mainUIHandler = null; \r
+       \r
+       // SmartDeviceLinkProxy Advanced Lifecycle Management\r
+       protected Boolean _advancedLifecycleManagementEnabled = false;\r
+       // Parameters passed to the constructor from the app to register an app interface\r
+       private String _applicationName = null;\r
+       private Vector<TTSChunk> _ttsName = null;\r
+       private String _ngnMediaScreenAppName = null;\r
+       private Boolean _isMediaApp = null;\r
+       private Language _smartDeviceLinkLanguageDesired = null;\r
+       private Language _hmiDisplayLanguageDesired = null;\r
+       private Vector<AppHMIType> _appType = null;\r
+       private String _appID = null;\r
+       private String _autoActivateIdDesired = null;\r
+       private smartdevicelinkMsgVersion _smartDeviceLinkMsgVersionRequest = null;\r
+       private Vector<String> _vrSynonyms = null;\r
+       \r
+       /**\r
+        * Contains current configuration for the transport that was selected during \r
+        * construction of this object\r
+        */\r
+       private BaseTransportConfig _transportConfig = null;\r
+       // Proxy State Variables\r
+       protected Boolean _appInterfaceRegisterd = false;\r
+       private Boolean _haveReceivedFirstNonNoneHMILevel = false;\r
+       protected Boolean _haveReceivedFirstFocusLevel = false;\r
+       protected Boolean _haveReceivedFirstFocusLevelFull = false;\r
+       protected Boolean _proxyDisposed = false;\r
+       protected SmartDeviceLinkConnectionState _smartDeviceLinkConnectionState = null;\r
+       protected SmartDeviceLinkInterfaceAvailability _smartDeviceLinkIntefaceAvailablity = null;\r
+       protected HMILevel _hmiLevel = null;\r
+       private HMILevel _priorHmiLevel = null;\r
+       protected AudioStreamingState _audioStreamingState = null;\r
+       private AudioStreamingState _priorAudioStreamingState = null;\r
+       protected SystemContext _systemContext = null;\r
+       // Variables set by RegisterAppInterfaceResponse\r
+       protected smartdevicelinkMsgVersion _smartDeviceLinkMsgVersion = null;\r
+       protected String _autoActivateIdReturned = null;\r
+       protected Language _smartDeviceLinkLanguage = null;\r
+       protected Language _hmiDisplayLanguage = null;\r
+       protected DisplayCapabilities _displayCapabilities = null;\r
+       protected Vector<ButtonCapabilities> _buttonCapabilities = null;\r
+       protected Vector<SoftButtonCapabilities> _softButtonCapabilities = null;\r
+       protected PresetBankCapabilities _presetBankCapabilities = null;\r
+       protected Vector<HmiZoneCapabilities> _hmiZoneCapabilities = null;\r
+       protected Vector<SpeechCapabilities> _speechCapabilities = null;\r
+       protected Vector<VrCapabilities> _vrCapabilities = null;\r
+       protected VehicleType _vehicleType = null;\r
+       protected Boolean firstTimeFull = true;\r
+       protected String _proxyVersionInfo = null;\r
+       \r
+       protected byte _sdlproVersion = 1;\r
+       \r
+       // Interface broker\r
+       private SmartDeviceLinkInterfaceBroker _interfaceBroker = null;\r
+       \r
+       // Private Class to Interface with smartDeviceLinkConnection\r
+       private class SmartDeviceLinkInterfaceBroker implements IsmartDeviceLinkConnectionListener {\r
+               \r
+               @Override\r
+               public void onTransportDisconnected(String info) {\r
+                       // proxyOnTransportDisconnect is called to alert the proxy that a requested\r
+                       // disconnect has completed\r
+                       \r
+                       if (_advancedLifecycleManagementEnabled) {\r
+                               // If ALM, nothing is required to be done here\r
+                       } else {\r
+                               // If original model, notify app the proxy is closed so it will delete and reinstanciate \r
+                               notifyProxyClosed(info, new SmartDeviceLinkException("Transport disconnected.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE));\r
+                       }\r
+               }\r
+\r
+               @Override\r
+               public void onTransportError(String info, Exception e) {\r
+                       DebugTool.logError("Transport failure: " + info, e);\r
+                       \r
+                       if (_advancedLifecycleManagementEnabled) {                      \r
+                               // Cycle the proxy\r
+                               cycleProxy(SmartDeviceLinkDisconnectedReason.TRANSPORT_ERROR);\r
+                       } else {\r
+                               notifyProxyClosed(info, e);\r
+                       }\r
+               }\r
+\r
+               @Override\r
+               public void onProtocolMessageReceived(ProtocolMessage msg) {\r
+                       \r
+                       try {if (msg.getData().length > 0) queueIncomingMessage(msg);}\r
+                       catch (Exception e) {}\r
+                       try {if (msg.getBulkData().length > 0) queueIncomingMessage(msg);}\r
+                       catch (Exception e) {}\r
+               }\r
+\r
+               @Override\r
+               public void onProtocolSessionStarted(SessionType sessionType,\r
+                               byte sessionID, byte version, String correlationID) {\r
+                       if (_sdlproVersion == 1) {\r
+                               if (version == 2) setsdlproVersion(version);\r
+                       }\r
+                       if (sessionType.eq(SessionType.RPC)) {                  \r
+                               startRPCProtocolSession(sessionID, correlationID);\r
+                       } else if (_sdlproVersion == 2) {\r
+                               //If version 2 then don't need to specify a Session Type\r
+                               startRPCProtocolSession(sessionID, correlationID);\r
+                       }  else {\r
+                               // Handle other protocol session types here\r
+                       }\r
+               }\r
+\r
+               @Override\r
+               public void onProtocolSessionEnded(SessionType sessionType,\r
+                               byte sessionID, String correlationID) {\r
+                       // How to handle protocol session ended?\r
+                               // How should protocol session management occur? \r
+               }\r
+\r
+               @Override\r
+               public void onProtocolError(String info, Exception e) {\r
+                       passErrorToProxyListener(info, e);\r
+               }\r
+       }\r
+       \r
+       /**\r
+        * Constructor.\r
+        * \r
+        * @param listener Type of listener for this proxy base.\r
+        * @param smartDeviceLinkProxyConfigurationResources Configuration resources for this proxy.\r
+        * @param enableAdvancedLifecycleManagement Flag that ALM should be enabled or not.\r
+        * @param appName Client application name.\r
+        * @param ttsName TTS name.\r
+        * @param ngnMediaScreenAppName Media Screen Application name.\r
+        * @param vrSynonyms List of synonyms.\r
+        * @param isMediaApp Flag that indicates that client application if media application or not.\r
+        * @param smartDeviceLinkMsgVersion Version of SmartDeviceLink Message.\r
+        * @param languageDesired Desired language.\r
+        * @param hmiDisplayLanguageDesired Desired language for HMI. \r
+        * @param appType Type of application.\r
+        * @param appID Application identifier.\r
+        * @param autoActivateID Auto activation identifier.\r
+        * @param callbackToUIThread Flag that indicates that this proxy should send callback to UI thread or not.\r
+        * @param transportConfig Configuration of transport to be used by underlying connection.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       protected SmartDeviceLinkProxyBase(proxyListenerType listener, SmartDeviceLinkProxyConfigurationResources smartDeviceLinkProxyConfigurationResources, \r
+                       boolean enableAdvancedLifecycleManagement, String appName, Vector<TTSChunk> ttsName, \r
+                       String ngnMediaScreenAppName, Vector<String> vrSynonyms, Boolean isMediaApp, smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, \r
+                       Language languageDesired, Language hmiDisplayLanguageDesired, Vector<AppHMIType> appType, String appID, \r
+                       String autoActivateID, boolean callbackToUIThread, BaseTransportConfig transportConfig) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               setsdlproVersion((byte)PROX_PROT_VER_ONE);\r
+               \r
+               _interfaceBroker = new SmartDeviceLinkInterfaceBroker();\r
+               \r
+               _callbackToUIThread = callbackToUIThread;\r
+               \r
+               if (_callbackToUIThread) {\r
+                       _mainUIHandler = new Handler(Looper.getMainLooper());\r
+               }\r
+               \r
+               // Set variables for Advanced Lifecycle Management\r
+               _advancedLifecycleManagementEnabled = enableAdvancedLifecycleManagement;\r
+               _applicationName = appName;\r
+               _ttsName = ttsName;\r
+               _ngnMediaScreenAppName = ngnMediaScreenAppName;\r
+               _isMediaApp = isMediaApp;\r
+               _smartDeviceLinkMsgVersionRequest = smartDeviceLinkMsgVersion;\r
+               _vrSynonyms = vrSynonyms; \r
+               _smartDeviceLinkLanguageDesired = languageDesired;\r
+               _hmiDisplayLanguageDesired = hmiDisplayLanguageDesired;\r
+               _appType = appType;\r
+               _appID = appID;\r
+               _autoActivateIdDesired = autoActivateID;\r
+               _transportConfig = transportConfig;\r
+               \r
+               // Test conditions to invalidate the proxy\r
+               if (listener == null) {\r
+                       throw new IllegalArgumentException("IProxyListener listener must be provided to instantiate SmartDeviceLinkProxy object.");\r
+               }\r
+               if (_advancedLifecycleManagementEnabled) {\r
+                       if (_applicationName == null ) {\r
+                               throw new IllegalArgumentException("To use SmartDeviceLinkProxyALM, an application name, appName, must be provided");\r
+                       }\r
+                       if (_applicationName.length() < 1 || _applicationName.length() > 100) {\r
+                               throw new IllegalArgumentException("A provided application name, appName, must be between 1 and 100 characters in length.");\r
+                       }\r
+                       if (_isMediaApp == null) {\r
+                               throw new IllegalArgumentException("isMediaApp must not be null when using SmartDeviceLinkProxyALM.");\r
+                       }\r
+               }\r
+               \r
+               _proxyListener = listener;\r
+               \r
+               // Get information from smartDeviceLinkProxyConfigurationResources\r
+               TelephonyManager telephonyManager = null;\r
+               if (smartDeviceLinkProxyConfigurationResources != null) {\r
+                       telephonyManager = smartDeviceLinkProxyConfigurationResources.getTelephonyManager();\r
+               } \r
+               \r
+               // Use the telephonyManager to get and log phone info\r
+               if (telephonyManager != null) {\r
+                       // Following is not quite thread-safe (because m_traceLogger could test null twice),\r
+                       // so we need to fix this, but vulnerability (i.e. two instances of listener) is\r
+                       // likely harmless.\r
+                       if (_traceDeviceInterrogator == null) {\r
+                               _traceDeviceInterrogator = new TraceDeviceInfo(smartDeviceLinkProxyConfigurationResources.getTelephonyManager());\r
+                       } // end-if\r
+               } // end-if\r
+               \r
+               // Setup Internal ProxyMessage Dispatcher\r
+               synchronized(INTERNAL_MESSAGE_QUEUE_THREAD_LOCK) {\r
+                       // Ensure internalProxyMessageDispatcher is null\r
+                       if (_internalProxyMessageDispatcher != null) {\r
+                               _internalProxyMessageDispatcher.dispose();\r
+                               _internalProxyMessageDispatcher = null;\r
+                       }\r
+                       \r
+                       _internalProxyMessageDispatcher = new ProxyMessageDispatcher<InternalProxyMessage>("INTERNAL_MESSAGE_DISPATCHER",\r
+                                       new InternalProxyMessageComparitor(),\r
+                                       new IDispatchingStrategy<InternalProxyMessage>() {\r
+\r
+                                               @Override\r
+                                               public void dispatch(InternalProxyMessage message) {\r
+                                                       dispatchInternalMessage((InternalProxyMessage)message);\r
+                                               }\r
+       \r
+                                               @Override\r
+                                               public void handleDispatchingError(String info, Exception ex) {\r
+                                                       handleErrorsFromInternalMessageDispatcher(info, ex);\r
+                                               }\r
+       \r
+                                               @Override\r
+                                               public void handleQueueingError(String info, Exception ex) {\r
+                                                       handleErrorsFromInternalMessageDispatcher(info, ex);\r
+                                               }                       \r
+                       });\r
+               }\r
+               \r
+               // Setup Incoming ProxyMessage Dispatcher\r
+               synchronized(INCOMING_MESSAGE_QUEUE_THREAD_LOCK) {\r
+                       // Ensure incomingProxyMessageDispatcher is null\r
+                       if (_incomingProxyMessageDispatcher != null) {\r
+                               _incomingProxyMessageDispatcher.dispose();\r
+                               _incomingProxyMessageDispatcher = null;\r
+                       }\r
+                       \r
+                       _incomingProxyMessageDispatcher = new ProxyMessageDispatcher<ProtocolMessage>("INCOMING_MESSAGE_DISPATCHER",\r
+                                       new IncomingProtocolMessageComparitor(),\r
+                                       new IDispatchingStrategy<ProtocolMessage>() {\r
+                                               @Override\r
+                                               public void dispatch(ProtocolMessage message) {\r
+                                                       dispatchIncomingMessage((ProtocolMessage)message);\r
+                                               }\r
+       \r
+                                               @Override\r
+                                               public void handleDispatchingError(String info, Exception ex) {\r
+                                                       handleErrorsFromIncomingMessageDispatcher(info, ex);\r
+                                               }\r
+       \r
+                                               @Override\r
+                                               public void handleQueueingError(String info, Exception ex) {\r
+                                                       handleErrorsFromIncomingMessageDispatcher(info, ex);\r
+                                               }                       \r
+                       });\r
+               }\r
+               \r
+               // Setup Outgoing ProxyMessage Dispatcher\r
+               synchronized(OUTGOING_MESSAGE_QUEUE_THREAD_LOCK) {\r
+                       // Ensure outgoingProxyMessageDispatcher is null\r
+                       if (_outgoingProxyMessageDispatcher != null) {\r
+                               _outgoingProxyMessageDispatcher.dispose();\r
+                               _outgoingProxyMessageDispatcher = null;\r
+                       }\r
+                       \r
+                       _outgoingProxyMessageDispatcher = new ProxyMessageDispatcher<ProtocolMessage>("OUTGOING_MESSAGE_DISPATCHER",\r
+                                       new OutgoingProtocolMessageComparitor(),\r
+                                       new IDispatchingStrategy<ProtocolMessage>() {\r
+                                               @Override\r
+                                               public void dispatch(ProtocolMessage message) {\r
+                                                       dispatchOutgoingMessage((ProtocolMessage)message);\r
+                                               }\r
+       \r
+                                               @Override\r
+                                               public void handleDispatchingError(String info, Exception ex) {\r
+                                                       handleErrorsFromOutgoingMessageDispatcher(info, ex);\r
+                                               }\r
+       \r
+                                               @Override\r
+                                               public void handleQueueingError(String info, Exception ex) {\r
+                                                       handleErrorsFromOutgoingMessageDispatcher(info, ex);\r
+                                               }\r
+                       });\r
+               }\r
+               \r
+               // Initialize the proxy\r
+               try {\r
+                       initializeProxy();\r
+               } catch (SmartDeviceLinkException e) {\r
+                       // Couldn't initialize the proxy \r
+                       // Dispose threads and then rethrow exception\r
+                       \r
+                       if (_internalProxyMessageDispatcher != null) {\r
+                               _internalProxyMessageDispatcher.dispose();\r
+                               _internalProxyMessageDispatcher = null;\r
+                       }\r
+                       if (_incomingProxyMessageDispatcher != null) {\r
+                               _incomingProxyMessageDispatcher.dispose();\r
+                               _incomingProxyMessageDispatcher = null;\r
+                       }\r
+                       if (_outgoingProxyMessageDispatcher != null) {\r
+                               _outgoingProxyMessageDispatcher.dispose();\r
+                               _outgoingProxyMessageDispatcher = null;\r
+                       }\r
+                       throw e;\r
+               } \r
+               \r
+               // Trace that ctor has fired\r
+               SmartDeviceLinkTrace.logProxyEvent("SmartDeviceLinkProxy Created, instanceID=" + this.toString(), SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       /**\r
+        * Constructor.\r
+        * \r
+        * @param listener Type of listener for this proxy base.\r
+        * @param smartDeviceLinkProxyConfigurationResources Configuration resources for this proxy.\r
+        * @param enableAdvancedLifecycleManagement Flag that ALM should be enabled or not.\r
+        * @param appName Client application name.\r
+        * @param ttsName TTS name.\r
+        * @param ngnMediaScreenAppName Media Screen Application name.\r
+        * @param vrSynonyms List of synonyms.\r
+        * @param isMediaApp Flag that indicates that client application if media application or not.\r
+        * @param smartDeviceLinkMsgVersion Version of SmartDeviceLink Message.\r
+        * @param languageDesired Desired language.\r
+        * @param hmiDisplayLanguageDesired Desired language for HMI. \r
+        * @param appType Type of application.\r
+        * @param appID Application identifier.\r
+        * @param autoActivateID Auto activation identifier.\r
+        * @param callbackToUIThread Flag that indicates that this proxy should send callback to UI thread or not.\r
+        * @param preRegister Flag that indicates that this proxy should be pre-registerd or not.\r
+        * @param transportConfig Configuration of transport to be used by underlying connection.\r
+        * @throws SmartDeviceLinkException\r
+        */     \r
+       protected SmartDeviceLinkProxyBase(proxyListenerType listener, SmartDeviceLinkProxyConfigurationResources smartDeviceLinkProxyConfigurationResources, \r
+                       boolean enableAdvancedLifecycleManagement, String appName, Vector<TTSChunk> ttsName, \r
+                       String ngnMediaScreenAppName, Vector<String> vrSynonyms, Boolean isMediaApp, smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, \r
+                       Language languageDesired, Language hmiDisplayLanguageDesired, Vector<AppHMIType> appType, String appID, \r
+                       String autoActivateID, boolean callbackToUIThread, boolean preRegister,\r
+                       BaseTransportConfig transportConfig) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               setsdlproVersion((byte)PROX_PROT_VER_ONE);\r
+               \r
+               if (preRegister) _appInterfaceRegisterd = preRegister;\r
+               \r
+               _interfaceBroker = new SmartDeviceLinkInterfaceBroker();\r
+               \r
+               _callbackToUIThread = callbackToUIThread;\r
+               \r
+               if (_callbackToUIThread) {\r
+                       _mainUIHandler = new Handler(Looper.getMainLooper());\r
+               }\r
+               \r
+               // Set variables for Advanced Lifecycle Management\r
+               _advancedLifecycleManagementEnabled = enableAdvancedLifecycleManagement;\r
+               _applicationName = appName;\r
+               _ttsName = ttsName;\r
+               _ngnMediaScreenAppName = ngnMediaScreenAppName;\r
+               _isMediaApp = isMediaApp;\r
+               _smartDeviceLinkMsgVersionRequest = smartDeviceLinkMsgVersion;\r
+               _vrSynonyms = vrSynonyms; \r
+               _smartDeviceLinkLanguageDesired = languageDesired;\r
+               _hmiDisplayLanguageDesired = hmiDisplayLanguageDesired;\r
+               _appType = appType;\r
+               _appID = appID;\r
+               _autoActivateIdDesired = autoActivateID;\r
+               _transportConfig = transportConfig;\r
+               \r
+               // Test conditions to invalidate the proxy\r
+               if (listener == null) {\r
+                       throw new IllegalArgumentException("IProxyListener listener must be provided to instantiate SmartDeviceLinkProxy object.");\r
+               }\r
+               if (_advancedLifecycleManagementEnabled) {\r
+                       if (_applicationName == null ) {\r
+                               throw new IllegalArgumentException("To use SmartDeviceLinkProxyALM, an application name, appName, must be provided");\r
+                       }\r
+                       if (_applicationName.length() < 1 || _applicationName.length() > 100) {\r
+                               throw new IllegalArgumentException("A provided application name, appName, must be between 1 and 100 characters in length.");\r
+                       }\r
+                       if (_isMediaApp == null) {\r
+                               throw new IllegalArgumentException("isMediaApp must not be null when using SmartDeviceLinkProxyALM.");\r
+                       }\r
+               }\r
+               \r
+               _proxyListener = listener;\r
+               \r
+               // Get information from smartDeviceLinkProxyConfigurationResources\r
+               TelephonyManager telephonyManager = null;\r
+               if (smartDeviceLinkProxyConfigurationResources != null) {\r
+                       telephonyManager = smartDeviceLinkProxyConfigurationResources.getTelephonyManager();\r
+               } \r
+               \r
+               // Use the telephonyManager to get and log phone info\r
+               if (telephonyManager != null) {\r
+                       // Following is not quite thread-safe (because m_traceLogger could test null twice),\r
+                       // so we need to fix this, but vulnerability (i.e. two instances of listener) is\r
+                       // likely harmless.\r
+                       if (_traceDeviceInterrogator == null) {\r
+                               _traceDeviceInterrogator = new TraceDeviceInfo(smartDeviceLinkProxyConfigurationResources.getTelephonyManager());\r
+                       } // end-if\r
+               } // end-if\r
+               \r
+               // Setup Internal ProxyMessage Dispatcher\r
+               synchronized(INTERNAL_MESSAGE_QUEUE_THREAD_LOCK) {\r
+                       // Ensure internalProxyMessageDispatcher is null\r
+                       if (_internalProxyMessageDispatcher != null) {\r
+                               _internalProxyMessageDispatcher.dispose();\r
+                               _internalProxyMessageDispatcher = null;\r
+                       }\r
+                       \r
+                       _internalProxyMessageDispatcher = new ProxyMessageDispatcher<InternalProxyMessage>("INTERNAL_MESSAGE_DISPATCHER",\r
+                                       new InternalProxyMessageComparitor(),\r
+                                       new IDispatchingStrategy<InternalProxyMessage>() {\r
+\r
+                                               @Override\r
+                                               public void dispatch(InternalProxyMessage message) {\r
+                                                       dispatchInternalMessage((InternalProxyMessage)message);\r
+                                               }\r
+       \r
+                                               @Override\r
+                                               public void handleDispatchingError(String info, Exception ex) {\r
+                                                       handleErrorsFromInternalMessageDispatcher(info, ex);\r
+                                               }\r
+       \r
+                                               @Override\r
+                                               public void handleQueueingError(String info, Exception ex) {\r
+                                                       handleErrorsFromInternalMessageDispatcher(info, ex);\r
+                                               }                       \r
+                       });\r
+               }\r
+               \r
+               // Setup Incoming ProxyMessage Dispatcher\r
+               synchronized(INCOMING_MESSAGE_QUEUE_THREAD_LOCK) {\r
+                       // Ensure incomingProxyMessageDispatcher is null\r
+                       if (_incomingProxyMessageDispatcher != null) {\r
+                               _incomingProxyMessageDispatcher.dispose();\r
+                               _incomingProxyMessageDispatcher = null;\r
+                       }\r
+                       \r
+                       _incomingProxyMessageDispatcher = new ProxyMessageDispatcher<ProtocolMessage>("INCOMING_MESSAGE_DISPATCHER",\r
+                                       new IncomingProtocolMessageComparitor(),\r
+                                       new IDispatchingStrategy<ProtocolMessage>() {\r
+                                               @Override\r
+                                               public void dispatch(ProtocolMessage message) {\r
+                                                       dispatchIncomingMessage((ProtocolMessage)message);\r
+                                               }\r
+       \r
+                                               @Override\r
+                                               public void handleDispatchingError(String info, Exception ex) {\r
+                                                       handleErrorsFromIncomingMessageDispatcher(info, ex);\r
+                                               }\r
+       \r
+                                               @Override\r
+                                               public void handleQueueingError(String info, Exception ex) {\r
+                                                       handleErrorsFromIncomingMessageDispatcher(info, ex);\r
+                                               }                       \r
+                       });\r
+               }\r
+               \r
+               // Setup Outgoing ProxyMessage Dispatcher\r
+               synchronized(OUTGOING_MESSAGE_QUEUE_THREAD_LOCK) {\r
+                       // Ensure outgoingProxyMessageDispatcher is null\r
+                       if (_outgoingProxyMessageDispatcher != null) {\r
+                               _outgoingProxyMessageDispatcher.dispose();\r
+                               _outgoingProxyMessageDispatcher = null;\r
+                       }\r
+                       \r
+                       _outgoingProxyMessageDispatcher = new ProxyMessageDispatcher<ProtocolMessage>("OUTGOING_MESSAGE_DISPATCHER",\r
+                                       new OutgoingProtocolMessageComparitor(),\r
+                                       new IDispatchingStrategy<ProtocolMessage>() {\r
+                                               @Override\r
+                                               public void dispatch(ProtocolMessage message) {\r
+                                                       dispatchOutgoingMessage((ProtocolMessage)message);\r
+                                               }\r
+       \r
+                                               @Override\r
+                                               public void handleDispatchingError(String info, Exception ex) {\r
+                                                       handleErrorsFromOutgoingMessageDispatcher(info, ex);\r
+                                               }\r
+       \r
+                                               @Override\r
+                                               public void handleQueueingError(String info, Exception ex) {\r
+                                                       handleErrorsFromOutgoingMessageDispatcher(info, ex);\r
+                                               }\r
+                       });\r
+               }\r
+               \r
+               // Initialize the proxy\r
+               try {\r
+                       initializeProxy();\r
+               } catch (SmartDeviceLinkException e) {\r
+                       // Couldn't initialize the proxy \r
+                       // Dispose threads and then rethrow exception\r
+                       \r
+                       if (_internalProxyMessageDispatcher != null) {\r
+                               _internalProxyMessageDispatcher.dispose();\r
+                               _internalProxyMessageDispatcher = null;\r
+                       }\r
+                       if (_incomingProxyMessageDispatcher != null) {\r
+                               _incomingProxyMessageDispatcher.dispose();\r
+                               _incomingProxyMessageDispatcher = null;\r
+                       }\r
+                       if (_outgoingProxyMessageDispatcher != null) {\r
+                               _outgoingProxyMessageDispatcher.dispose();\r
+                               _outgoingProxyMessageDispatcher = null;\r
+                       }\r
+                       throw e;\r
+               } \r
+               \r
+               // Trace that ctor has fired\r
+               SmartDeviceLinkTrace.logProxyEvent("SmartDeviceLinkProxy Created, instanceID=" + this.toString(), SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+\r
+       private Intent createBroadcastIntent()\r
+       {\r
+               Intent sendIntent = new Intent();\r
+               sendIntent.setAction("com.smartdevicelink.broadcast");\r
+               sendIntent.putExtra("APP_NAME", this._applicationName);\r
+               sendIntent.putExtra("APP_ID", this._appID);\r
+               sendIntent.putExtra("RPC_NAME", "");\r
+               sendIntent.putExtra("TYPE", "");\r
+               sendIntent.putExtra("SUCCESS", true);\r
+               sendIntent.putExtra("CORRID", 0);\r
+               sendIntent.putExtra("FUNCTION_NAME", "");\r
+               sendIntent.putExtra("COMMENT1", "");\r
+               sendIntent.putExtra("COMMENT2", "");\r
+               sendIntent.putExtra("COMMENT3", "");\r
+               sendIntent.putExtra("COMMENT4", "");\r
+               sendIntent.putExtra("COMMENT5", "");\r
+               sendIntent.putExtra("COMMENT6", "");\r
+               sendIntent.putExtra("COMMENT7", "");\r
+               sendIntent.putExtra("COMMENT8", "");\r
+               sendIntent.putExtra("COMMENT9", "");\r
+               sendIntent.putExtra("COMMENT10", "");\r
+               sendIntent.putExtra("DATA", "");\r
+               sendIntent.putExtra("SHOW_ON_UI", true);\r
+               return sendIntent;\r
+       }\r
+       private void updateBroadcastIntent(Intent sendIntent, String sKey, String sValue)\r
+       {\r
+               sendIntent.putExtra(sKey, sValue);              \r
+       }\r
+       private void updateBroadcastIntent(Intent sendIntent, String sKey, boolean bValue)\r
+       {\r
+               sendIntent.putExtra(sKey, bValue);              \r
+       }\r
+       private void updateBroadcastIntent(Intent sendIntent, String sKey, int iValue)\r
+       {\r
+               sendIntent.putExtra(sKey, iValue);              \r
+       }\r
+       \r
+       private void sendBroadcastIntent(Intent sendIntent)\r
+       {\r
+               Service myService = null;               \r
+               if (_proxyListener != null && _proxyListener instanceof Service)\r
+               {\r
+                       myService = (Service) _proxyListener;                           \r
+               }\r
+               else if (_appService != null)\r
+               {\r
+                       myService = _appService;\r
+               }\r
+               else\r
+               {\r
+                       return;\r
+               }               \r
+               Context myContext = myService.getApplicationContext();                          \r
+               if (myContext != null) myContext.sendBroadcast(sendIntent);             \r
+       }\r
+\r
+       /**\r
+        * send encoded SmartDeviceLink data to Url\r
+        * @param urlString\r
+        * @param encodedSyncPData\r
+        * @param timeout\r
+        */\r
+       private void sendEncodedSyncPDataToUrl(String urlString, Vector<String> encodedSyncPData, Integer timeout) {            \r
+               \r
+       }\r
+\r
+       /**\r
+        * send encoded SmartDeviceLink data to Url\r
+        * @param urlString\r
+        * @param bs\r
+        * @param timeout\r
+        */\r
+       private void sendSyncPDataToUrl(String urlString, byte[] bs, Integer timeout) {\r
+\r
+       }\r
+\r
+       // Test correlationID\r
+       private boolean isCorrelationIDProtected(Integer correlationID) {\r
+               if (correlationID != null && \r
+                               (REGISTER_APP_INTERFACE_CORRELATION_ID == correlationID\r
+                                               || UNREGISTER_APP_INTERFACE_CORRELATION_ID == correlationID\r
+                                               || POLICIES_CORRELATION_ID == correlationID)) {\r
+                       return true;\r
+               }\r
+               \r
+               return false;\r
+       }\r
+       \r
+       // Protected isConnected method to allow legacy proxy to poll isConnected state\r
+       public Boolean getIsConnected() {\r
+               return _smartDeviceLinkConnection.getIsConnected();\r
+       }\r
+       \r
+       /**\r
+        * Returns whether the application is registered in SMARTDEVICELINK. Note: for testing\r
+        * purposes, it's possible that the connection is established, but the\r
+        * application is not registered.\r
+        * \r
+        * @return true if the application is registered in SMARTDEVICELINK\r
+        */\r
+       public Boolean getAppInterfaceRegistered() {\r
+               return _appInterfaceRegisterd;\r
+       }\r
+\r
+       // Function to initialize new proxy connection\r
+       private void initializeProxy() throws SmartDeviceLinkException {                \r
+               // Reset all of the flags and state variables\r
+               _haveReceivedFirstNonNoneHMILevel = false;\r
+               _haveReceivedFirstFocusLevel = false;\r
+               _haveReceivedFirstFocusLevelFull = false;\r
+               _smartDeviceLinkIntefaceAvailablity = SmartDeviceLinkInterfaceAvailability.SMARTDEVICELINK_INTERFACE_UNAVAILABLE;\r
+                               \r
+               // Setup smartDeviceLinkConnection\r
+               synchronized(CONNECTION_REFERENCE_LOCK) {\r
+                       if (_smartDeviceLinkConnection != null) {\r
+                               _smartDeviceLinkConnection.closeConnection(_rpcSessionID);\r
+                               _smartDeviceLinkConnection = null;\r
+                       }\r
+                       _smartDeviceLinkConnection = new smartDeviceLinkConnection(_interfaceBroker, _transportConfig);\r
+                       SmartDeviceLinkProtocol protocol = (SmartDeviceLinkProtocol)_smartDeviceLinkConnection.getSmartDeviceLinkProtocolProtocol();\r
+                       protocol.setVersion(_sdlproVersion);\r
+               }\r
+               \r
+               synchronized(CONNECTION_REFERENCE_LOCK) {\r
+                       if (_smartDeviceLinkConnection != null) {\r
+                               _smartDeviceLinkConnection.startTransport();\r
+                       }\r
+               }\r
+       }\r
+       \r
+       /**\r
+        *  Public method to enable the siphon transport\r
+        */\r
+       public static void enableSiphonDebug() {\r
+               SiphonServer.enableSiphonServer();\r
+       }\r
+       \r
+       /**\r
+        *  Public method to disable the Siphon Trace Server\r
+        */\r
+       public static void disableSiphonDebug() {\r
+               SiphonServer.disableSiphonServer();\r
+       }       \r
+       \r
+       /**\r
+        *  Public method to enable the Debug Tool\r
+        */\r
+       public static void enableDebugTool() {\r
+               DebugTool.enableDebugTool();\r
+       }\r
+       \r
+       /**\r
+        *  Public method to disable the Debug Tool\r
+        */\r
+       public static void disableDebugTool() {\r
+               DebugTool.disableDebugTool();\r
+       }       \r
+\r
+       /**\r
+       * Public method to determine Debug Tool enabled\r
+       */\r
+       public static boolean isDebugEnabled() {\r
+               return DebugTool.isDebugEnabled();\r
+       }       \r
+       \r
+       \r
+       @Deprecated\r
+       public void close() throws SmartDeviceLinkException {\r
+               dispose();\r
+       }\r
+       \r
+       private void cleanProxy(SmartDeviceLinkDisconnectedReason disconnectedReason) throws SmartDeviceLinkException {\r
+               try {\r
+                       \r
+                       // ALM Specific Cleanup\r
+                       if (_advancedLifecycleManagementEnabled) {\r
+                               _smartDeviceLinkConnectionState = SmartDeviceLinkConnectionState.SMARTDEVICELINK_DISCONNECTED;\r
+                               \r
+                               firstTimeFull = true;\r
+                       \r
+                               // Should we wait for the interface to be unregistered?\r
+                               Boolean waitForInterfaceUnregistered = false;\r
+                               // Unregister app interface\r
+                               synchronized(CONNECTION_REFERENCE_LOCK) {\r
+                                       if (_appInterfaceRegisterd == true && _smartDeviceLinkConnection != null && _smartDeviceLinkConnection.getIsConnected()) {\r
+                                               waitForInterfaceUnregistered = true;\r
+                                               unregisterAppInterfacePrivate(UNREGISTER_APP_INTERFACE_CORRELATION_ID);\r
+                                       }\r
+                               }\r
+                               \r
+                               // Wait for the app interface to be unregistered\r
+                               if (waitForInterfaceUnregistered) {\r
+                                       synchronized(APP_INTERFACE_REGISTERED_LOCK) {\r
+                                               try {\r
+                                                       APP_INTERFACE_REGISTERED_LOCK.wait(1000);\r
+                                               } catch (InterruptedException e) {\r
+                                                       // Do nothing\r
+                                               }\r
+                                       }\r
+                               }\r
+                       }\r
+                       \r
+                       // Clean up SMARTDEVICELINK Connection\r
+                       synchronized(CONNECTION_REFERENCE_LOCK) {\r
+                               if (_smartDeviceLinkConnection != null) {\r
+                                       _smartDeviceLinkConnection.closeConnection(_rpcSessionID);\r
+                                       _smartDeviceLinkConnection = null;\r
+                               }\r
+                       }               \r
+               } catch (SmartDeviceLinkException e) {\r
+                       throw e;\r
+               } finally {\r
+                       SmartDeviceLinkTrace.logProxyEvent("SmartDeviceLinkProxy cleaned.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+               }\r
+       }\r
+       \r
+       /**\r
+        * Terminates the App's Interface Registration, closes the transport connection, ends the protocol session, and frees any resources used by the proxy.\r
+        */\r
+       public void dispose() throws SmartDeviceLinkException\r
+       {               \r
+               if (_proxyDisposed) {\r
+                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);\r
+               }\r
+               \r
+               _proxyDisposed = true;\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application called dispose() method.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+               \r
+               try{\r
+                       // Clean the proxy\r
+                       cleanProxy(SmartDeviceLinkDisconnectedReason.APPLICATION_REQUESTED_DISCONNECT);\r
+               \r
+                       // Close IncomingProxyMessageDispatcher thread\r
+                       synchronized(INCOMING_MESSAGE_QUEUE_THREAD_LOCK) {\r
+                               if (_incomingProxyMessageDispatcher != null) {\r
+                                       _incomingProxyMessageDispatcher.dispose();\r
+                                       _incomingProxyMessageDispatcher = null;\r
+                               }\r
+                       }\r
+                       \r
+                       // Close OutgoingProxyMessageDispatcher thread\r
+                       synchronized(OUTGOING_MESSAGE_QUEUE_THREAD_LOCK) {\r
+                               if (_outgoingProxyMessageDispatcher != null) {\r
+                                       _outgoingProxyMessageDispatcher.dispose();\r
+                                       _outgoingProxyMessageDispatcher = null;\r
+                               }\r
+                       }\r
+                       \r
+                       // Close InternalProxyMessageDispatcher thread\r
+                       synchronized(INTERNAL_MESSAGE_QUEUE_THREAD_LOCK) {\r
+                               if (_internalProxyMessageDispatcher != null) {\r
+                                       _internalProxyMessageDispatcher.dispose();\r
+                                       _internalProxyMessageDispatcher = null;\r
+                               }\r
+                       }\r
+                       \r
+                       _traceDeviceInterrogator = null;\r
+               } catch (SmartDeviceLinkException e) {\r
+                       throw e;\r
+               } finally {\r
+                       SmartDeviceLinkTrace.logProxyEvent("SmartDeviceLinkProxy disposed.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+               }\r
+       } // end-method\r
+\r
+       // Method to cycle the proxy, only called in ALM\r
+       protected void cycleProxy(SmartDeviceLinkDisconnectedReason disconnectedReason) {               \r
+               try{\r
+                       cleanProxy(disconnectedReason);\r
+                       initializeProxy();      \r
+                       notifyProxyClosed("SMARTDEVICELINK Proxy Cycled", new SmartDeviceLinkException("SMARTDEVICELINK Proxy Cycled", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_CYCLED));\r
+               } catch (SmartDeviceLinkException e) {\r
+                       switch(e.getSmartDeviceLinkExceptionCause()) {\r
+                       case BLUETOOTH_DISABLED:\r
+                               notifyProxyClosed("Bluetooth is disabled. Bluetooth must be enabled to connect to SMARTDEVICELINK. Reattempt a connection once Bluetooth is enabled.", \r
+                                               new SmartDeviceLinkException("Bluetooth is disabled. Bluetooth must be enabled to connect to SMARTDEVICELINK. Reattempt a connection once Bluetooth is enabled.", SmartDeviceLinkExceptionCause.BLUETOOTH_DISABLED));\r
+                               break;\r
+                       case BLUETOOTH_ADAPTER_NULL:\r
+                               notifyProxyClosed("Cannot locate a Bluetooth adapater. A SMARTDEVICELINK connection is impossible on this device until a Bluetooth adapter is added.", \r
+                                               new SmartDeviceLinkException("Cannot locate a Bluetooth adapater. A SMARTDEVICELINK connection is impossible on this device until a Bluetooth adapter is added.", SmartDeviceLinkExceptionCause.BLUETOOTH_ADAPTER_NULL));\r
+                               break;\r
+                       default :\r
+                               notifyProxyClosed("Cycling the proxy failed.", e);\r
+                               break;\r
+                       }\r
+               } catch (Exception e) { \r
+                       notifyProxyClosed("Cycling the proxy failed.", e);\r
+               }\r
+       }\r
+\r
+       \r
+       \r
+       /************* Functions used by the Message Dispatching Queues ****************/\r
+       private void dispatchIncomingMessage(ProtocolMessage message) {\r
+               try{\r
+                       // Dispatching logic\r
+                       if (message.getSessionType().equals(SessionType.RPC)) {\r
+                               try {\r
+                                       if (_sdlproVersion == 1) {\r
+                                               if (message.getVersion() == 2) setsdlproVersion(message.getVersion());\r
+                                       }\r
+                                       \r
+                                       Hashtable hash = new Hashtable();\r
+                                       if (_sdlproVersion == 2) {\r
+                                               Hashtable hashTemp = new Hashtable();\r
+                                               hashTemp.put(Names.correlationID, message.getCorrID());\r
+                                               if (message.getJsonSize() > 0) {\r
+                                                       final Hashtable<String, Object> mhash = JsonRPCMarshaller.unmarshall(message.getData());\r
+                                                       //hashTemp.put(Names.parameters, mhash.get(Names.parameters));\r
+                                                       hashTemp.put(Names.parameters, mhash);\r
+                                               }\r
+                                               FunctionID functionID = new FunctionID();\r
+                                               hashTemp.put(Names.function_name, functionID.getFunctionName(message.getFunctionID()));\r
+                                               if (message.getRPCType() == 0x00) {\r
+                                                       hash.put(Names.request, hashTemp);\r
+                                               } else if (message.getRPCType() == 0x01) {\r
+                                                       hash.put(Names.response, hashTemp);\r
+                                               } else if (message.getRPCType() == 0x02) {\r
+                                                       hash.put(Names.notification, hashTemp);\r
+                                               }\r
+                                               if (message.getBulkData() != null) hash.put(Names.bulkData, message.getBulkData());\r
+                                       } else {\r
+                                               final Hashtable<String, Object> mhash = JsonRPCMarshaller.unmarshall(message.getData());\r
+                                               hash = mhash;\r
+                                       }\r
+                                       handleRPCMessage(hash);                                                 \r
+                               } catch (final Exception excp) {\r
+                                       DebugTool.logError("Failure handling protocol message: " + excp.toString(), excp);\r
+                                       passErrorToProxyListener("Error handing incoming protocol message.", excp);\r
+                               } // end-catch\r
+                       } else {\r
+                               // Handle other protocol message types here\r
+                       }\r
+               } catch (final Exception e) {\r
+                       // Pass error to application through listener \r
+                       DebugTool.logError("Error handing proxy event.", e);\r
+                       passErrorToProxyListener("Error handing incoming protocol message.", e);\r
+               }\r
+       }\r
+       \r
+       private byte getsdlproVersion() {\r
+               return this._sdlproVersion;\r
+       }\r
+       \r
+       private void setsdlproVersion(byte version) {\r
+               this._sdlproVersion = version;\r
+       }\r
+       \r
+       public String serializeJSON(RPCMessage msg)\r
+       {\r
+               String sReturn = null;          \r
+               try\r
+               {\r
+                       sReturn = msg.serializeJSON(getsdlproVersion()).toString(2);\r
+               }\r
+               catch (final Exception e) \r
+               {\r
+                       DebugTool.logError("Error handing proxy event.", e);\r
+                       passErrorToProxyListener("Error serializing message.", e);\r
+                       return null;\r
+               }\r
+               return sReturn;\r
+       }\r
+\r
+       private void handleErrorsFromIncomingMessageDispatcher(String info, Exception e) {\r
+               passErrorToProxyListener(info, e);\r
+       }\r
+       \r
+       private void dispatchOutgoingMessage(ProtocolMessage message) {\r
+               synchronized(CONNECTION_REFERENCE_LOCK) {\r
+                       if (_smartDeviceLinkConnection != null) {\r
+                               _smartDeviceLinkConnection.sendMessage(message);\r
+                       }\r
+               }               \r
+               SmartDeviceLinkTrace.logProxyEvent("SmartDeviceLinkProxy sending Protocol Message: " + message.toString(), SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       private void handleErrorsFromOutgoingMessageDispatcher(String info, Exception e) {\r
+               passErrorToProxyListener(info, e);\r
+       }\r
+       \r
+       void dispatchInternalMessage(final InternalProxyMessage message) {\r
+               try{\r
+                       if (message.getFunctionName().equals(Names.OnProxyError)) {\r
+                               final OnError msg = (OnError)message;                   \r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onError(msg.getInfo(), msg.getException());\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onError(msg.getInfo(), msg.getException());\r
+                               }\r
+                       /**************Start Legacy Specific Call-backs************/\r
+                       } else if (message.getFunctionName().equals(Names.OnProxyOpened)) {\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       ((IProxyListener)_proxyListener).onProxyOpened();\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       ((IProxyListener)_proxyListener).onProxyOpened();\r
+                               }\r
+                       } else if (message.getFunctionName().equals(Names.OnProxyClosed)) {\r
+                               final OnProxyClosed msg = (OnProxyClosed)message;\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onProxyClosed(msg.getInfo(), msg.getException());\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onProxyClosed(msg.getInfo(), msg.getException());\r
+                               }\r
+                       /****************End Legacy Specific Call-backs************/\r
+                       } else {\r
+                               // Diagnostics\r
+                               SmartDeviceLinkTrace.logProxyEvent("Unknown RPC Message encountered. Check for an updated version of the SMARTDEVICELINK Proxy.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+                               DebugTool.logError("Unknown RPC Message encountered. Check for an updated version of the SMARTDEVICELINK Proxy.");\r
+                       }\r
+                       \r
+               SmartDeviceLinkTrace.logProxyEvent("Proxy fired callback: " + message.getFunctionName(), SMARTDEVICELINK_LIB_TRACE_KEY);\r
+               } catch(final Exception e) {\r
+                       // Pass error to application through listener \r
+                       DebugTool.logError("Error handing proxy event.", e);\r
+                       if (_callbackToUIThread) {\r
+                               // Run in UI thread\r
+                               _mainUIHandler.post(new Runnable() {\r
+                                       @Override\r
+                                       public void run() {\r
+                                               _proxyListener.onError("Error handing proxy event.", e);\r
+                                       }\r
+                               });\r
+                       } else {\r
+                               _proxyListener.onError("Error handing proxy event.", e);\r
+                       }\r
+               }\r
+       }\r
+       \r
+       private void handleErrorsFromInternalMessageDispatcher(String info, Exception e) {\r
+               DebugTool.logError(info, e);\r
+               // This error cannot be passed to the user, as it indicates an error\r
+               // in the communication between the proxy and the application.\r
+               \r
+               DebugTool.logError("InternalMessageDispatcher failed.", e);\r
+               \r
+               // Note, this is the only place where the _proxyListener should be referenced asmartDeviceLinkhronously,\r
+               // with an error on the internalMessageDispatcher, we have no other reliable way of \r
+               // communicating with the application.\r
+               notifyProxyClosed("Proxy callback dispatcher is down. Proxy instance is invalid.", e);\r
+               _proxyListener.onError("Proxy callback dispatcher is down. Proxy instance is invalid.", e);\r
+       }\r
+       /************* END Functions used by the Message Dispatching Queues ****************/\r
+       \r
+       // Private sendPRCRequest method. All RPCRequests are funneled through this method after\r
+               // error checking. \r
+       private void sendRPCRequestPrivate(RPCRequest request) throws SmartDeviceLinkException {\r
+                       try {\r
+                       SmartDeviceLinkTrace.logRPCEvent(InterfaceActivityDirection.Transmit, request, SMARTDEVICELINK_LIB_TRACE_KEY);\r
+                                               \r
+                       byte[] msgBytes = JsonRPCMarshaller.marshall(request, _sdlproVersion);\r
+       \r
+                       ProtocolMessage pm = new ProtocolMessage();\r
+                       pm.setData(msgBytes);\r
+                       pm.setSessionID(_rpcSessionID);\r
+                       pm.setMessageType(MessageType.RPC);\r
+                       pm.setSessionType(SessionType.RPC);\r
+                       pm.setFunctionID(FunctionID.getFunctionID(request.getFunctionName()));\r
+                       pm.setCorrID(request.getCorrelationID());\r
+                       if (request.getBulkData() != null) \r
+                               pm.setBulkData(request.getBulkData());\r
+                       \r
+                       // Queue this outgoing message\r
+                       synchronized(OUTGOING_MESSAGE_QUEUE_THREAD_LOCK) {\r
+                               if (_outgoingProxyMessageDispatcher != null) {\r
+                                       _outgoingProxyMessageDispatcher.queueMessage(pm);\r
+                               }\r
+                       }\r
+               } catch (OutOfMemoryError e) {\r
+                       SmartDeviceLinkTrace.logProxyEvent("OutOfMemory exception while sending request " + request.getFunctionName(), SMARTDEVICELINK_LIB_TRACE_KEY);\r
+                       throw new SmartDeviceLinkException("OutOfMemory exception while sending request " + request.getFunctionName(), e, SmartDeviceLinkExceptionCause.INVALID_ARGUMENT);\r
+               }\r
+       }\r
+       \r
+       private void handleRPCMessage(Hashtable hash) {\r
+               RPCMessage rpcMsg = new RPCMessage(hash);\r
+               String functionName = rpcMsg.getFunctionName();\r
+               String messageType = rpcMsg.getMessageType();\r
+               \r
+               if (messageType.equals(Names.response)) {                       \r
+                       SmartDeviceLinkTrace.logRPCEvent(InterfaceActivityDirection.Receive, new RPCResponse(rpcMsg), SMARTDEVICELINK_LIB_TRACE_KEY);\r
+\r
+                       // Check to ensure response is not from an internal message (reserved correlation ID)\r
+                       if (isCorrelationIDProtected((new RPCResponse(hash)).getCorrelationID())) {\r
+                               // This is a response generated from an internal message, it can be trapped here\r
+                               // The app should not receive a response for a request it did not send\r
+                               if ((new RPCResponse(hash)).getCorrelationID() == REGISTER_APP_INTERFACE_CORRELATION_ID \r
+                                               && _advancedLifecycleManagementEnabled \r
+                                               && functionName.equals(Names.RegisterAppInterface)) {\r
+                                       final RegisterAppInterfaceResponse msg = new RegisterAppInterfaceResponse(hash);\r
+                                       if (msg.getSuccess()) {\r
+                                               _appInterfaceRegisterd = true;\r
+                                       }\r
+                                       \r
+                                       //_autoActivateIdReturned = msg.getAutoActivateID();\r
+                                       /*Place holder for legacy support*/ _autoActivateIdReturned = "8675309";\r
+                                       _buttonCapabilities = msg.getButtonCapabilities();\r
+                                       _displayCapabilities = msg.getDisplayCapabilities();\r
+                                       _softButtonCapabilities = msg.getSoftButtonCapabilities();\r
+                                       _presetBankCapabilities = msg.getPresetBankCapabilities();\r
+                                       _hmiZoneCapabilities = msg.getHmiZoneCapabilities();\r
+                                       _speechCapabilities = msg.getSpeechCapabilities();\r
+                                       _smartDeviceLinkLanguage = msg.getLanguage();\r
+                                       _hmiDisplayLanguage = msg.getHmiDisplayLanguage();\r
+                                       _smartDeviceLinkMsgVersion = msg.getsmartdevicelinkMsgVersion();\r
+                                       _vrCapabilities = msg.getVrCapabilities();\r
+                                       _vehicleType = msg.getVehicleType();\r
+                                       _proxyVersionInfo = msg.getProxyVersionInfo();\r
+                                       \r
+                                       String sVersionInfo = "SMARTDEVICELINK Proxy Version: " + _proxyVersionInfo;\r
+                                       \r
+                                       Class<?> cls = null;\r
+                                       try \r
+                                       {\r
+                                               cls = Class.forName(Names.VersionExtend);\r
+                                               Object t = cls.newInstance();                                           \r
+                                               Method meth = cls.getDeclaredMethod("getVersionInfo", null);                                                                                                                    \r
+                                               final Object ver = meth.invoke(t, null);                                                \r
+                                               String sValue = ver.toString();                                 \r
+                                               sVersionInfo += "\r\n" + "ExtendedLib Version: " + sValue;                                              \r
+                                       } \r
+                                       catch (Exception e) \r
+                                       {\r
+                                               //Extended info does not exist\r
+                                       }\r
+                                                                               \r
+                                       if (!isDebugEnabled()) \r
+                                       {\r
+                                               enableDebugTool();\r
+                                               DebugTool.logInfo(sVersionInfo, false);\r
+                                               disableDebugTool();\r
+                                       }                                       \r
+                                       else\r
+                                               DebugTool.logInfo(sVersionInfo, false);\r
+                                       \r
+                                       // Send onSmartDeviceLinkConnected message in ALM\r
+                                       _smartDeviceLinkConnectionState = SmartDeviceLinkConnectionState.SMARTDEVICELINK_CONNECTED;\r
+                                       \r
+                                       // If registerAppInterface failed, exit with OnProxyUnusable\r
+                                       if (!msg.getSuccess()) {\r
+                                               notifyProxyClosed("Unable to register app interface. Review values passed to the SMARTDEVICELINK Proxy constructor. RegisterAppInterface result code: ", \r
+                                                               new SmartDeviceLinkException("Unable to register app interface. Review values passed to the SmartDeviceLinkProxy constructor. RegisterAppInterface result code: " + msg.getResultCode(), SmartDeviceLinkExceptionCause.SMARTDEVICELINK_REGISTRATION_ERROR));\r
+                                       }\r
+                                       \r
+                                       if (_callbackToUIThread) {\r
+                                               // Run in UI thread\r
+                                               _mainUIHandler.post(new Runnable() {\r
+                                                       @Override\r
+                                                       public void run() {\r
+                                                               if (_proxyListener instanceof IProxyListener) {\r
+                                                                       ((IProxyListener)_proxyListener).onRegisterAppInterfaceResponse(msg);\r
+                                                               } else if (_proxyListener instanceof IProxyListenerALM) {\r
+                                                                       //((IProxyListenerALM)_proxyListener).onRegisterAppInterfaceResponse(msg);\r
+                                                               }\r
+                                                       }\r
+                                               });\r
+                                       } else {\r
+                                               if (_proxyListener instanceof IProxyListener) {\r
+                                                       ((IProxyListener)_proxyListener).onRegisterAppInterfaceResponse(msg);\r
+                                               } else if (_proxyListener instanceof IProxyListenerALM) {\r
+                                                       //((IProxyListenerALM)_proxyListener).onRegisterAppInterfaceResponse(msg);\r
+                                               }\r
+                                       }\r
+                               } else if ((new RPCResponse(hash)).getCorrelationID() == POLICIES_CORRELATION_ID \r
+                                               && functionName.equals(Names.OnEncodedSyncPData)) {\r
+                                       // OnEncodedSyncPData\r
+                                       final OnEncodedSyncPData msg = new OnEncodedSyncPData(hash);\r
+\r
+                                       // If url is not null, then send to URL\r
+                                       if (msg.getUrl() != null) {\r
+                                               // URL has data, attempt to post request to external server\r
+                                               Thread handleOffboardSmartDeviceLinkTransmissionTread = new Thread() {\r
+                                                       @Override\r
+                                                       public void run() {\r
+                                                               sendEncodedSyncPDataToUrl(msg.getUrl(), msg.getData(), msg.getTimeout());\r
+                                                       }\r
+                                               };\r
+\r
+                                               handleOffboardSmartDeviceLinkTransmissionTread.start();\r
+                                       } \r
+                                       \r
+                               } else if ((new RPCResponse(hash)).getCorrelationID() == POLICIES_CORRELATION_ID \r
+                                               && functionName.equals(Names.OnSyncPData)) {\r
+                                       // OnSyncPData\r
+                                       final OnSyncPData msg = new OnSyncPData(hash);\r
+\r
+                                       // If url is not null, then send to URL\r
+                                       if (msg.getUrl() != null) {\r
+                                               // URL has data, attempt to post request to external server\r
+                                               Thread handleOffboardSmartDeviceLinkTransmissionTread = new Thread() {\r
+                                                       @Override\r
+                                                       public void run() {\r
+                                                               sendSyncPDataToUrl(msg.getUrl(), msg.getSyncPData(), msg.getTimeout());\r
+                                                       }\r
+                                               };\r
+\r
+                                               handleOffboardSmartDeviceLinkTransmissionTread.start();\r
+                                       } \r
+                               }\r
+                               else if ((new RPCResponse(hash)).getCorrelationID() == POLICIES_CORRELATION_ID \r
+                                               && functionName.equals(Names.EncodedSyncPData)) {\r
+                                       // EncodedSyncPData\r
+                                       final EncodedSyncPDataResponse msg = new EncodedSyncPDataResponse(hash);\r
+                                       \r
+                                       Intent sendIntent = createBroadcastIntent();\r
+                                       updateBroadcastIntent(sendIntent, "RPC_NAME", Names.EncodedSyncPData);\r
+                                       updateBroadcastIntent(sendIntent, "TYPE", Names.response);\r
+                                       updateBroadcastIntent(sendIntent, "SUCCESS", msg.getSuccess());\r
+                                       updateBroadcastIntent(sendIntent, "COMMENT1", msg.getInfo());\r
+                                       updateBroadcastIntent(sendIntent, "COMMENT2", msg.getResultCode().toString());\r
+                                       updateBroadcastIntent(sendIntent, "CORRID", msg.getCorrelationID());\r
+                                       sendBroadcastIntent(sendIntent);\r
+                               }                               \r
+                               return;\r
+                       }\r
+                       \r
+                       if (functionName.equals(Names.RegisterAppInterface)) {\r
+                               final RegisterAppInterfaceResponse msg = new RegisterAppInterfaceResponse(hash);\r
+                               if (msg.getSuccess()) {\r
+                                       _appInterfaceRegisterd = true;\r
+                               }\r
+\r
+                               //_autoActivateIdReturned = msg.getAutoActivateID();\r
+                               /*Place holder for legacy support*/ _autoActivateIdReturned = "8675309";\r
+                               _buttonCapabilities = msg.getButtonCapabilities();\r
+                               _displayCapabilities = msg.getDisplayCapabilities();\r
+                               _softButtonCapabilities = msg.getSoftButtonCapabilities();\r
+                               _presetBankCapabilities = msg.getPresetBankCapabilities();\r
+                               _hmiZoneCapabilities = msg.getHmiZoneCapabilities();\r
+                               _speechCapabilities = msg.getSpeechCapabilities();\r
+                               _smartDeviceLinkLanguage = msg.getLanguage();\r
+                               _hmiDisplayLanguage = msg.getHmiDisplayLanguage();\r
+                               _smartDeviceLinkMsgVersion = msg.getsmartdevicelinkMsgVersion();\r
+                               _vrCapabilities = msg.getVrCapabilities();\r
+                               _vehicleType = msg.getVehicleType();\r
+                               _proxyVersionInfo = msg.getProxyVersionInfo();\r
+                               \r
+                               if (!isDebugEnabled()) \r
+                               {\r
+                                       enableDebugTool();\r
+                                       DebugTool.logInfo("SMARTDEVICELINK Proxy Version: " + _proxyVersionInfo);\r
+                                       disableDebugTool();\r
+                               }                                       \r
+                               else\r
+                                       DebugTool.logInfo("SMARTDEVICELINK Proxy Version: " + _proxyVersionInfo);                               \r
+                               \r
+                               // RegisterAppInterface\r
+                               if (_advancedLifecycleManagementEnabled) {\r
+                                       \r
+                                       // Send onSmartDeviceLinkConnected message in ALM\r
+                                       _smartDeviceLinkConnectionState = SmartDeviceLinkConnectionState.SMARTDEVICELINK_CONNECTED;\r
+                                       \r
+                                       // If registerAppInterface failed, exit with OnProxyUnusable\r
+                                       if (!msg.getSuccess()) {\r
+                                               notifyProxyClosed("Unable to register app interface. Review values passed to the SmartDeviceLinkProxy constructor. RegisterAppInterface result code: ", \r
+                                                               new SmartDeviceLinkException("Unable to register app interface. Review values passed to the SmartDeviceLinkProxy constructor. RegisterAppInterface result code: " + msg.getResultCode(), SmartDeviceLinkExceptionCause.SMARTDEVICELINK_REGISTRATION_ERROR));\r
+                                       }\r
+                               } else {        \r
+                                       if (_callbackToUIThread) {\r
+                                               // Run in UI thread\r
+                                               _mainUIHandler.post(new Runnable() {\r
+                                                       @Override\r
+                                                       public void run() {\r
+                                                               if (_proxyListener instanceof IProxyListener) {\r
+                                                                       ((IProxyListener)_proxyListener).onRegisterAppInterfaceResponse(msg);\r
+                                                               } else if (_proxyListener instanceof IProxyListenerALM) {\r
+                                                                       //((IProxyListenerALM)_proxyListener).onRegisterAppInterfaceResponse(msg);\r
+                                                               }\r
+                                                       }\r
+                                               });\r
+                                       } else {\r
+                                               if (_proxyListener instanceof IProxyListener) {\r
+                                                       ((IProxyListener)_proxyListener).onRegisterAppInterfaceResponse(msg);\r
+                                               } else if (_proxyListener instanceof IProxyListenerALM) {\r
+                                                       //((IProxyListenerALM)_proxyListener).onRegisterAppInterfaceResponse(msg);\r
+                                               }\r
+                                       }\r
+                               }\r
+                       } else if (functionName.equals(Names.Speak)) {\r
+                               // SpeakResponse\r
+                               \r
+                               final SpeakResponse msg = new SpeakResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onSpeakResponse(msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onSpeakResponse(msg);                                            \r
+                               }\r
+                       } else if (functionName.equals(Names.Alert)) {\r
+                               // AlertResponse\r
+                               \r
+                               final AlertResponse msg = new AlertResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onAlertResponse(msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onAlertResponse(msg);                                            \r
+                               }\r
+                       } else if (functionName.equals(Names.Show)) {\r
+                               // ShowResponse\r
+                               \r
+                               final ShowResponse msg = new ShowResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onShowResponse((ShowResponse)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onShowResponse((ShowResponse)msg);                                               \r
+                               }\r
+                       } else if (functionName.equals(Names.AddCommand)) {\r
+                               // AddCommand\r
+                               \r
+                               final AddCommandResponse msg = new AddCommandResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onAddCommandResponse((AddCommandResponse)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onAddCommandResponse((AddCommandResponse)msg);                                   \r
+                               }\r
+                       } else if (functionName.equals(Names.DeleteCommand)) {\r
+                               // DeleteCommandResponse\r
+                               \r
+                               final DeleteCommandResponse msg = new DeleteCommandResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onDeleteCommandResponse((DeleteCommandResponse)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onDeleteCommandResponse((DeleteCommandResponse)msg);                                     \r
+                               }\r
+                       } else if (functionName.equals(Names.AddSubMenu)) {\r
+                               // AddSubMenu\r
+                               \r
+                               final AddSubMenuResponse msg = new AddSubMenuResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onAddSubMenuResponse((AddSubMenuResponse)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onAddSubMenuResponse((AddSubMenuResponse)msg);                                   \r
+                               }\r
+                       } else if (functionName.equals(Names.DeleteSubMenu)) {\r
+                               // DeleteSubMenu\r
+                               \r
+                               final DeleteSubMenuResponse msg = new DeleteSubMenuResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onDeleteSubMenuResponse((DeleteSubMenuResponse)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onDeleteSubMenuResponse((DeleteSubMenuResponse)msg);                                     \r
+                               }\r
+                       } else if (functionName.equals(Names.SubscribeButton)) {\r
+                               // SubscribeButton\r
+                               \r
+                               final SubscribeButtonResponse msg = new SubscribeButtonResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onSubscribeButtonResponse((SubscribeButtonResponse)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onSubscribeButtonResponse((SubscribeButtonResponse)msg);                         \r
+                               }\r
+                       } else if (functionName.equals(Names.UnsubscribeButton)) {\r
+                               // UnsubscribeButton\r
+                               \r
+                               final UnsubscribeButtonResponse msg = new UnsubscribeButtonResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onUnsubscribeButtonResponse((UnsubscribeButtonResponse)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onUnsubscribeButtonResponse((UnsubscribeButtonResponse)msg);                     \r
+                               }\r
+                       } else if (functionName.equals(Names.SetMediaClockTimer)) {\r
+                               // SetMediaClockTimer\r
+                               \r
+                               final SetMediaClockTimerResponse msg = new SetMediaClockTimerResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onSetMediaClockTimerResponse((SetMediaClockTimerResponse)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onSetMediaClockTimerResponse((SetMediaClockTimerResponse)msg);           \r
+                               }\r
+                       } else if (functionName.equals(Names.EncodedSyncPData)) {\r
+                               // EncodedSyncPData\r
+                               \r
+                               final EncodedSyncPDataResponse msg = new EncodedSyncPDataResponse(hash);\r
+                               \r
+                               Intent sendIntent = createBroadcastIntent();\r
+                               updateBroadcastIntent(sendIntent, "RPC_NAME", Names.EncodedSyncPData);\r
+                               updateBroadcastIntent(sendIntent, "TYPE", Names.response);\r
+                               updateBroadcastIntent(sendIntent, "SUCCESS", msg.getSuccess());\r
+                               updateBroadcastIntent(sendIntent, "COMMENT1", msg.getInfo());\r
+                               updateBroadcastIntent(sendIntent, "COMMENT2", msg.getResultCode().toString());\r
+                               updateBroadcastIntent(sendIntent, "CORRID", msg.getCorrelationID());\r
+                               sendBroadcastIntent(sendIntent);\r
+\r
+                               try\r
+                               {\r
+                                       Class<?> cls = Class.forName(Names.ListenerExtend);\r
+                                       if (cls.isInstance(_proxyListener))\r
+                                       {\r
+                                               final Object t = cls.cast(_proxyListener);\r
+                                               final Method meth = cls.getDeclaredMethod(Names.onEncodedSyncPDataResponse, new Class[]{EncodedSyncPDataResponse.class});\r
+                                               if (_callbackToUIThread) {\r
+                                                       // Run in UI thread\r
+                                                       _mainUIHandler.post(new Runnable() {\r
+                                                               @Override\r
+                                                               public void run() {\r
+                                                                       try {\r
+                                                                               meth.invoke(t, msg);\r
+                                                                       }\r
+                                                                       catch (Exception e)  {\r
+                                                                               e.printStackTrace();\r
+                                                                       }\r
+                                                               }\r
+                                                       });\r
+                                               } else {\r
+                                                       meth.invoke(t, msg);\r
+                                               }\r
+                                       }\r
+                               }\r
+                               catch (Exception e)\r
+                               {\r
+                                       //private lib not present\r
+                               }\r
+                       } else if (functionName.equals(Names.SyncPData)) {\r
+                               // SyncPData\r
+                               \r
+                               final SyncPDataResponse msg = new SyncPDataResponse(hash);\r
+\r
+                               Intent sendIntent = createBroadcastIntent();\r
+                               updateBroadcastIntent(sendIntent, "RPC_NAME", Names.SyncPData);\r
+                               updateBroadcastIntent(sendIntent, "TYPE", Names.response);\r
+                               updateBroadcastIntent(sendIntent, "SUCCESS", msg.getSuccess());                         \r
+                               updateBroadcastIntent(sendIntent, "COMMENT1", msg.getInfo());\r
+                               updateBroadcastIntent(sendIntent, "COMMENT2", msg.getResultCode().toString());\r
+                               updateBroadcastIntent(sendIntent, "CORRID", msg.getCorrelationID());\r
+                               sendBroadcastIntent(sendIntent);                                \r
+                               try\r
+                               {\r
+                                       Class<?> cls = Class.forName(Names.ListenerExtend);\r
+                                       if (cls.isInstance(_proxyListener))\r
+                                       {\r
+                                               final Object t = cls.cast(_proxyListener);\r
+                                               final Method meth = cls.getDeclaredMethod(Names.onSyncPDataResponse, new Class[]{SyncPDataResponse.class});\r
+                                               if (_callbackToUIThread) {\r
+                                                       // Run in UI thread\r
+                                                       _mainUIHandler.post(new Runnable() {\r
+                                                               @Override\r
+                                                               public void run() {\r
+                                                                       try {\r
+                                                                               meth.invoke(t, msg);\r
+                                                                       }\r
+                                                                       catch (Exception e)  {\r
+                                                                               e.printStackTrace();\r
+                                                                       }\r
+                                                               }\r
+                                                       });\r
+                                               } else {\r
+                                                       meth.invoke(t, msg);\r
+                                               }\r
+                                       }\r
+                               }\r
+                               catch (Exception e)\r
+                               {\r
+                                       //private lib not present\r
+                               }\r
+                       } else if (functionName.equals(Names.CreateInteractionChoiceSet)) {\r
+                               // CreateInteractionChoiceSet\r
+                               \r
+                               final CreateInteractionChoiceSetResponse msg = new CreateInteractionChoiceSetResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onCreateInteractionChoiceSetResponse((CreateInteractionChoiceSetResponse)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onCreateInteractionChoiceSetResponse((CreateInteractionChoiceSetResponse)msg);           \r
+                               }\r
+                       } else if (functionName.equals(Names.DeleteInteractionChoiceSet)) {\r
+                               // DeleteInteractionChoiceSet\r
+                               \r
+                               final DeleteInteractionChoiceSetResponse msg = new DeleteInteractionChoiceSetResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onDeleteInteractionChoiceSetResponse((DeleteInteractionChoiceSetResponse)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onDeleteInteractionChoiceSetResponse((DeleteInteractionChoiceSetResponse)msg);           \r
+                               }\r
+                       } else if (functionName.equals(Names.PerformInteraction)) {\r
+                               // PerformInteraction\r
+                               \r
+                               final PerformInteractionResponse msg = new PerformInteractionResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onPerformInteractionResponse((PerformInteractionResponse)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onPerformInteractionResponse((PerformInteractionResponse)msg);           \r
+                               }\r
+                       } else if (functionName.equals(Names.SetGlobalProperties)) {\r
+                               // SetGlobalPropertiesResponse \r
+                               \r
+                               final SetGlobalPropertiesResponse msg = new SetGlobalPropertiesResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                               // Run in UI thread\r
+                                               _mainUIHandler.post(new Runnable() {\r
+                                                       @Override\r
+                                                       public void run() {\r
+                                                               _proxyListener.onSetGlobalPropertiesResponse((SetGlobalPropertiesResponse)msg);\r
+                                                       }\r
+                                               });\r
+                                       } else {\r
+                                               _proxyListener.onSetGlobalPropertiesResponse((SetGlobalPropertiesResponse)msg);         \r
+                               }\r
+                       } else if (functionName.equals(Names.ResetGlobalProperties)) {\r
+                               // ResetGlobalProperties                                \r
+                               \r
+                               final ResetGlobalPropertiesResponse msg = new ResetGlobalPropertiesResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onResetGlobalPropertiesResponse((ResetGlobalPropertiesResponse)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onResetGlobalPropertiesResponse((ResetGlobalPropertiesResponse)msg);             \r
+                               }\r
+                       } else if (functionName.equals(Names.UnregisterAppInterface)) {\r
+                               // UnregisterAppInterface\r
+                               \r
+                               _appInterfaceRegisterd = false;\r
+                               synchronized(APP_INTERFACE_REGISTERED_LOCK) {\r
+                                       APP_INTERFACE_REGISTERED_LOCK.notify();\r
+                               }\r
+                               \r
+                               final UnregisterAppInterfaceResponse msg = new UnregisterAppInterfaceResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       if (_proxyListener instanceof IProxyListener) {\r
+                                                               ((IProxyListener)_proxyListener).onUnregisterAppInterfaceResponse(msg);\r
+                                                       } else if (_proxyListener instanceof IProxyListenerALM) {\r
+                                                               //((IProxyListenerALM)_proxyListener).onUnregisterAppInterfaceResponse(msg);\r
+                                                       }\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       if (_proxyListener instanceof IProxyListener) {\r
+                                               ((IProxyListener)_proxyListener).onUnregisterAppInterfaceResponse(msg);\r
+                                       } else if (_proxyListener instanceof IProxyListenerALM) {\r
+                                               //((IProxyListenerALM)_proxyListener).onUnregisterAppInterfaceResponse(msg);\r
+                                       }\r
+                               }\r
+                               \r
+                               notifyProxyClosed("UnregisterAppInterfaceResponse", null);\r
+                       } else if (functionName.equals(Names.GenericResponse)) {\r
+                               // GenericResponse (Usually and error)\r
+                               final GenericResponse msg = new GenericResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onGenericResponse((GenericResponse)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onGenericResponse((GenericResponse)msg); \r
+                               }\r
+                       } else if (functionName.equals(Names.Slider)) {\r
+                // Slider\r
+                final SliderResponse msg = new SliderResponse(hash);\r
+                if (_callbackToUIThread) {\r
+                    // Run in UI thread\r
+                    _mainUIHandler.post(new Runnable() {\r
+                        @Override\r
+                        public void run() {\r
+                            _proxyListener.onSliderResponse((SliderResponse)msg);\r
+                        }\r
+                    });\r
+                } else {\r
+                    _proxyListener.onSliderResponse((SliderResponse)msg);   \r
+                }\r
+            } else if (functionName.equals(Names.PutFile)) {\r
+                // PutFile\r
+                final PutFileResponse msg = new PutFileResponse(hash);\r
+                if (_callbackToUIThread) {\r
+                    // Run in UI thread\r
+                    _mainUIHandler.post(new Runnable() {\r
+                        @Override\r
+                        public void run() {\r
+                            _proxyListener.onPutFileResponse((PutFileResponse)msg);\r
+                        }\r
+                    });\r
+                } else {\r
+                    _proxyListener.onPutFileResponse((PutFileResponse)msg);\r
+                }\r
+            } else if (functionName.equals(Names.DeleteFile)) {\r
+                // DeleteFile\r
+                final DeleteFileResponse msg = new DeleteFileResponse(hash);\r
+                if (_callbackToUIThread) {\r
+                    // Run in UI thread\r
+                    _mainUIHandler.post(new Runnable() {\r
+                        @Override\r
+                        public void run() {\r
+                            _proxyListener.onDeleteFileResponse((DeleteFileResponse)msg);\r
+                        }\r
+                    });\r
+                } else {\r
+                    _proxyListener.onDeleteFileResponse((DeleteFileResponse)msg);   \r
+                }\r
+            } else if (functionName.equals(Names.ListFiles)) {\r
+                // ListFiles\r
+                final ListFilesResponse msg = new ListFilesResponse(hash);\r
+                if (_callbackToUIThread) {\r
+                    // Run in UI thread\r
+                    _mainUIHandler.post(new Runnable() {\r
+                        @Override\r
+                        public void run() {\r
+                            _proxyListener.onListFilesResponse((ListFilesResponse)msg);\r
+                        }\r
+                    });\r
+                } else {\r
+                    _proxyListener.onListFilesResponse((ListFilesResponse)msg);     \r
+                }\r
+            } else if (functionName.equals(Names.SetAppIcon)) {\r
+                // SetAppIcon\r
+                final SetAppIconResponse msg = new SetAppIconResponse(hash);\r
+                if (_callbackToUIThread) {\r
+                    // Run in UI thread\r
+                    _mainUIHandler.post(new Runnable() {\r
+                        @Override\r
+                        public void run() {\r
+                            _proxyListener.onSetAppIconResponse((SetAppIconResponse)msg);\r
+                        }\r
+                    });\r
+                } else {\r
+                        _proxyListener.onSetAppIconResponse((SetAppIconResponse)msg);   \r
+                }\r
+            } else if (functionName.equals(Names.ScrollableMessage)) {\r
+                // ScrollableMessage\r
+                final ScrollableMessageResponse msg = new ScrollableMessageResponse(hash);\r
+                if (_callbackToUIThread) {\r
+                    // Run in UI thread\r
+                    _mainUIHandler.post(new Runnable() {\r
+                        @Override\r
+                        public void run() {\r
+                            _proxyListener.onScrollableMessageResponse((ScrollableMessageResponse)msg);\r
+                        }\r
+                    });\r
+                } else {\r
+                    _proxyListener.onScrollableMessageResponse((ScrollableMessageResponse)msg);     \r
+                }\r
+            } else if (functionName.equals(Names.ChangeRegistration)) {\r
+                // ChangeLanguageRegistration\r
+                final ChangeRegistrationResponse msg = new ChangeRegistrationResponse(hash);\r
+                if (_callbackToUIThread) {\r
+                    // Run in UI thread\r
+                    _mainUIHandler.post(new Runnable() {\r
+                        @Override\r
+                        public void run() {\r
+                            _proxyListener.onChangeRegistrationResponse((ChangeRegistrationResponse)msg);\r
+                        }\r
+                    });\r
+                } else {\r
+                    _proxyListener.onChangeRegistrationResponse((ChangeRegistrationResponse)msg);   \r
+                }\r
+            } else if (functionName.equals(Names.SetDisplayLayout)) {\r
+                // SetDisplayLayout\r
+                final SetDisplayLayoutResponse msg = new SetDisplayLayoutResponse(hash);\r
+                if (_callbackToUIThread) {\r
+                    // Run in UI thread\r
+                    _mainUIHandler.post(new Runnable() {\r
+                        @Override\r
+                        public void run() {\r
+                            _proxyListener.onSetDisplayLayoutResponse((SetDisplayLayoutResponse)msg);\r
+                        }\r
+                    });\r
+                } else {\r
+                        _proxyListener.onSetDisplayLayoutResponse((SetDisplayLayoutResponse)msg);\r
+                }\r
+            } else if (functionName.equals(Names.PerformAudioPassThru)) {\r
+                // PerformAudioPassThru\r
+                final PerformAudioPassThruResponse msg = new PerformAudioPassThruResponse(hash);\r
+                if (_callbackToUIThread) {\r
+                    // Run in UI thread\r
+                    _mainUIHandler.post(new Runnable() {\r
+                        @Override\r
+                        public void run() {\r
+                            _proxyListener.onPerformAudioPassThruResponse((PerformAudioPassThruResponse)msg);\r
+                        }\r
+                    });\r
+                } else {\r
+                    _proxyListener.onPerformAudioPassThruResponse((PerformAudioPassThruResponse)msg);       \r
+                }\r
+            } else if (functionName.equals(Names.EndAudioPassThru)) {\r
+                // EndAudioPassThru\r
+                final EndAudioPassThruResponse msg = new EndAudioPassThruResponse(hash);\r
+                if (_callbackToUIThread) {\r
+                    // Run in UI thread\r
+                    _mainUIHandler.post(new Runnable() {\r
+                        @Override\r
+                        public void run() {\r
+                            _proxyListener.onEndAudioPassThruResponse((EndAudioPassThruResponse)msg);\r
+                        }\r
+                    });\r
+                } else {\r
+                    _proxyListener.onEndAudioPassThruResponse((EndAudioPassThruResponse)msg);\r
+                }\r
+            } else if (functionName.equals(Names.SubscribeVehicleData)) {\r
+               try {\r
+                                       Class<?> cls = Class.forName(Names.SubscribeVehicleDataExtend);\r
+                                       Constructor con = cls.getConstructor(new Class[]{Hashtable.class});                                                                                                                     \r
+                                       final Object msg = con.newInstance(hash);       \r
+                                       // SubscribeVehicleDataExtend\r
+                       if (_callbackToUIThread) {\r
+                           // Run in UI thread\r
+                           _mainUIHandler.post(new Runnable() {\r
+                               @Override\r
+                               public void run() {\r
+                                   _proxyListener.onSubscribeVehicleDataResponse((SubscribeVehicleDataResponse)msg);\r
+                               }\r
+                           });\r
+                       } else {\r
+                           _proxyListener.onSubscribeVehicleDataResponse((SubscribeVehicleDataResponse)msg);   \r
+                       }                                                                       \r
+                               }                 \r
+               catch(Exception e) {                    \r
+               // SubscribeVehicleData\r
+                       final SubscribeVehicleDataResponse msg = new SubscribeVehicleDataResponse(hash);\r
+                       if (_callbackToUIThread) {\r
+                           // Run in UI thread\r
+                           _mainUIHandler.post(new Runnable() {\r
+                               @Override\r
+                               public void run() {\r
+                                   _proxyListener.onSubscribeVehicleDataResponse((SubscribeVehicleDataResponse)msg);\r
+                               }\r
+                           });\r
+                       } else {\r
+                           _proxyListener.onSubscribeVehicleDataResponse((SubscribeVehicleDataResponse)msg);       \r
+                       }\r
+               }\r
+            } else if (functionName.equals(Names.UnsubscribeVehicleData)) {\r
+               try {\r
+                                       Class<?> cls = Class.forName(Names.UnsubscribeVehicleDataExtend);\r
+                                       Constructor con = cls.getConstructor(new Class[]{Hashtable.class});                                                                                                                     \r
+                                       final Object msg = con.newInstance(hash);       \r
+                                       // UnsubscribeVehicleDataExtend\r
+                       if (_callbackToUIThread) {\r
+                           // Run in UI thread\r
+                           _mainUIHandler.post(new Runnable() {\r
+                               @Override\r
+                               public void run() {\r
+                                   _proxyListener.onUnsubscribeVehicleDataResponse((UnsubscribeVehicleDataResponse)msg);\r
+                               }\r
+                           });\r
+                       } else {\r
+                           _proxyListener.onUnsubscribeVehicleDataResponse((UnsubscribeVehicleDataResponse)msg);   \r
+                       }                                                                       \r
+                               }   \r
+               catch(Exception e) {                                                \r
+                       // UnsubscribeVehicleData\r
+                       final UnsubscribeVehicleDataResponse msg = new UnsubscribeVehicleDataResponse(hash);\r
+                       if (_callbackToUIThread) {\r
+                           // Run in UI thread\r
+                           _mainUIHandler.post(new Runnable() {\r
+                               @Override\r
+                               public void run() {\r
+                                   _proxyListener.onUnsubscribeVehicleDataResponse((UnsubscribeVehicleDataResponse)msg);\r
+                               }\r
+                           });\r
+                       } else {\r
+                           _proxyListener.onUnsubscribeVehicleDataResponse((UnsubscribeVehicleDataResponse)msg);   \r
+                       }\r
+                }\r
+            } else if (functionName.equals(Names.GetVehicleData)) {                                                    \r
+               try {\r
+                                       Class<?> cls = Class.forName(Names.GetVehicleDataExtend);\r
+                                       Constructor con = cls.getConstructor(new Class[]{Hashtable.class});                                                                                                                     \r
+                                       final Object msg = con.newInstance(hash);       \r
+                                       // GetVehicleDataExtend\r
+                       if (_callbackToUIThread) {\r
+                           // Run in UI thread\r
+                           _mainUIHandler.post(new Runnable() {\r
+                               @Override\r
+                               public void run() {\r
+                                   _proxyListener.onGetVehicleDataResponse((GetVehicleDataResponse)msg);\r
+                               }\r
+                           });\r
+                       } else {\r
+                           _proxyListener.onGetVehicleDataResponse((GetVehicleDataResponse)msg);   \r
+                       }                                                                       \r
+                               }   \r
+               catch(Exception e) {\r
+                       // GetVehicleData\r
+                    final GetVehicleDataResponse msg = new GetVehicleDataResponse(hash);\r
+                    if (_callbackToUIThread) {\r
+                        // Run in UI thread\r
+                        _mainUIHandler.post(new Runnable() {\r
+                            @Override\r
+                            public void run() {\r
+                                _proxyListener.onGetVehicleDataResponse((GetVehicleDataResponse)msg);\r
+                            }\r
+                        });\r
+                    } else {\r
+                        _proxyListener.onGetVehicleDataResponse((GetVehicleDataResponse)msg);   \r
+                    }\r
+                            }                                 \r
+            } else if (functionName.equals(Names.ReadDID)) {\r
+                // ReadDID\r
+                final ReadDIDResponse msg = new ReadDIDResponse(hash);\r
+                if (_callbackToUIThread) {\r
+                    // Run in UI thread\r
+                    _mainUIHandler.post(new Runnable() {\r
+                        @Override\r
+                        public void run() {\r
+                            _proxyListener.onReadDIDResponse((ReadDIDResponse)msg);\r
+                        }\r
+                    });\r
+                } else {\r
+                    _proxyListener.onReadDIDResponse((ReadDIDResponse)msg); \r
+                }\r
+            } else if (functionName.equals(Names.GetDTCs)) {\r
+                // GetDTCs\r
+                final GetDTCsResponse msg = new GetDTCsResponse(hash);\r
+                if (_callbackToUIThread) {\r
+                    // Run in UI thread\r
+                    _mainUIHandler.post(new Runnable() {\r
+                        @Override\r
+                        public void run() {\r
+                            _proxyListener.onGetDTCsResponse((GetDTCsResponse)msg);\r
+                        }\r
+                    });\r
+                } else {\r
+                    _proxyListener.onGetDTCsResponse((GetDTCsResponse)msg); \r
+                }\r
+            } else if (functionName.equals(Names.AlertManeuver)) {\r
+                               // AlertManeuver\r
+                               final AlertManeuverResponse msg = new AlertManeuverResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onAlertManeuverResponse((AlertManeuverResponse)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onAlertManeuverResponse((AlertManeuverResponse)msg);     \r
+                               }\r
+                       } else if (functionName.equals(Names.ShowConstantTBT)) {\r
+                               // ShowConstantTBT\r
+                               final ShowConstantTBTResponse msg = new ShowConstantTBTResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onShowConstantTBTResponse((ShowConstantTBTResponse)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onShowConstantTBTResponse((ShowConstantTBTResponse)msg); \r
+                               }\r
+                       } else if (functionName.equals(Names.UpdateTurnList)) {\r
+                               // UpdateTurnList\r
+                               final UpdateTurnListResponse msg = new UpdateTurnListResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onUpdateTurnListResponse((UpdateTurnListResponse)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onUpdateTurnListResponse((UpdateTurnListResponse)msg);   \r
+                               }\r
+                       } else if (functionName.equals(Names.DialNumber)) {\r
+                               // DialNumber\r
+                               final DialNumberResponse msg = new DialNumberResponse(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onDialNumberResponse((DialNumberResponse)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onDialNumberResponse((DialNumberResponse)msg);   \r
+                               }\r
+                       } else {\r
+                               if (_smartDeviceLinkMsgVersion != null) {\r
+                                       DebugTool.logError("Unrecognized response Message: " + functionName.toString() + \r
+                                                       "SMARTDEVICELINK Message Version = " + _smartDeviceLinkMsgVersion);\r
+                               } else {\r
+                                       DebugTool.logError("Unrecognized response Message: " + functionName.toString());\r
+                               }\r
+                       } // end-if\r
+               } else if (messageType.equals(Names.notification)) {\r
+                       SmartDeviceLinkTrace.logRPCEvent(InterfaceActivityDirection.Receive, new RPCNotification(rpcMsg), SMARTDEVICELINK_LIB_TRACE_KEY);\r
+                       if (functionName.equals(Names.OnHMIStatus)) {\r
+                               // OnHMIStatus\r
+                               \r
+                               final OnHMIStatus msg = new OnHMIStatus(hash);\r
+                               msg.setFirstRun(new Boolean(firstTimeFull));\r
+                               if (msg.getHmiLevel() == HMILevel.HMI_FULL) firstTimeFull = false;\r
+                               \r
+                               if (msg.getHmiLevel() != _priorHmiLevel && msg.getAudioStreamingState() != _priorAudioStreamingState) {\r
+                                       if (_callbackToUIThread) {\r
+                                               // Run in UI thread\r
+                                               _mainUIHandler.post(new Runnable() {\r
+                                                       @Override\r
+                                                       public void run() {\r
+                                                               _proxyListener.onOnHMIStatus((OnHMIStatus)msg);\r
+                                                       }\r
+                                               });\r
+                                       } else {\r
+                                               _proxyListener.onOnHMIStatus((OnHMIStatus)msg);\r
+                                       }\r
+                               }                               \r
+                       } else if (functionName.equals(Names.OnCommand)) {\r
+                               // OnCommand\r
+                               \r
+                               final OnCommand msg = new OnCommand(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onOnCommand((OnCommand)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onOnCommand((OnCommand)msg);\r
+                               }\r
+                       } else if (functionName.equals(Names.OnDriverDistraction)) {\r
+                               // OnDriverDistration\r
+                               \r
+                               final OnDriverDistraction msg = new OnDriverDistraction(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onOnDriverDistraction(msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onOnDriverDistraction(msg);\r
+                               }\r
+                       } else if (functionName.equals(Names.OnEncodedSyncPData)) {\r
+                               // OnEncodedSyncPData;\r
+                               final OnEncodedSyncPData msg = new OnEncodedSyncPData(hash);\r
+\r
+\r
+                               Intent sendIntent = createBroadcastIntent();\r
+                               updateBroadcastIntent(sendIntent, "RPC_NAME", Names.OnEncodedSyncPData);                                                        \r
+                               updateBroadcastIntent(sendIntent, "TYPE", Names.notification);\r
+                               \r
+                               // If url is null, then send notification to the app, otherwise, send to URL\r
+                               if (msg.getUrl() == null) {\r
+                                       updateBroadcastIntent(sendIntent, "COMMENT1", "URL is a null value (received)");\r
+                                       sendBroadcastIntent(sendIntent);                                        \r
+                                       try\r
+                                       {\r
+                                               Class<?> cls = Class.forName(Names.ListenerExtend);\r
+                                               if (cls.isInstance(_proxyListener))\r
+                                               {\r
+                                                       final Object t = cls.cast(_proxyListener);\r
+                                                       final Method meth = cls.getDeclaredMethod(Names.onOnEncodedSyncPData, new Class[]{OnEncodedSyncPData.class});\r
+                                                       if (_callbackToUIThread) {\r
+                                                               // Run in UI thread\r
+                                                               _mainUIHandler.post(new Runnable() {\r
+                                                                       @Override\r
+                                                                       public void run() {\r
+                                                                               try {\r
+                                                                                       meth.invoke(t, msg);\r
+                                                                               }\r
+                                                                               catch (Exception e)  {\r
+                                                                                       e.printStackTrace();\r
+                                                                               }\r
+                                                                       }\r
+                                                               });\r
+                                                       } else {\r
+                                                               meth.invoke(t, msg);\r
+                                                       }\r
+                                               }\r
+                                       }\r
+                                       catch (Exception e)\r
+                                       {\r
+                                               //private lib not present\r
+                                       }\r
+                               } else {\r
+                                       updateBroadcastIntent(sendIntent, "COMMENT1", "Sending smartDeviceLinkp to cloud: " + msg.getUrl());\r
+                                       sendBroadcastIntent(sendIntent);                                \r
+                                       \r
+                                       // URL has data, attempt to post request to external server\r
+                                       Thread handleOffboardSmartDeviceLinkTransmissionTread = new Thread() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       sendEncodedSyncPDataToUrl(msg.getUrl(), msg.getData(), msg.getTimeout());\r
+                                               }\r
+                                       };\r
+\r
+                                       handleOffboardSmartDeviceLinkTransmissionTread.start();\r
+                               }\r
+                       } else if (functionName.equals(Names.OnSyncPData)) {\r
+                               // OnSyncPData\r
+                               final OnSyncPData msg = new OnSyncPData(hash);\r
+                               Intent sendIntent = createBroadcastIntent();\r
+                               updateBroadcastIntent(sendIntent, "RPC_NAME", Names.OnSyncPData);\r
+                               updateBroadcastIntent(sendIntent, "TYPE", Names.notification);\r
+                               \r
+                               // If url is null, then send notification to the app, otherwise, send to URL\r
+                               if (msg.getUrl() == null) {     \r
+                                       updateBroadcastIntent(sendIntent, "COMMENT1", "URL is a null value (received)");\r
+                                       sendBroadcastIntent(sendIntent);\r
+                                       try\r
+                                       {\r
+                                               Class<?> cls = Class.forName(Names.ListenerExtend);\r
+                                               if (cls.isInstance(_proxyListener))\r
+                                               {\r
+                                                       final Object t = cls.cast(_proxyListener);\r
+                                                       final Method meth = cls.getDeclaredMethod(Names.onOnSyncPData, new Class[]{OnSyncPData.class});\r
+                                                       if (_callbackToUIThread) {\r
+                                                               // Run in UI thread\r
+                                                               _mainUIHandler.post(new Runnable() {\r
+                                                                       @Override\r
+                                                                       public void run() {\r
+                                                                               try {\r
+                                                                                       meth.invoke(t, msg);\r
+                                                                               }\r
+                                                                               catch (Exception e)  {\r
+                                                                                       e.printStackTrace();\r
+                                                                               }\r
+                                                                       }\r
+                                                               });\r
+                                                       } else {\r
+                                                               meth.invoke(t, msg);\r
+                                                       }\r
+                                               }\r
+                                       }\r
+                                       catch (Exception e)\r
+                                       {\r
+                                               //private lib not present\r
+                                       }\r
+                               } else { //url not null, send to url\r
+                                       updateBroadcastIntent(sendIntent, "COMMENT1", "Sending smartDeviceLinkp to cloud: " + msg.getUrl());\r
+                                       sendBroadcastIntent(sendIntent);                                \r
+                                       Log.i("pt", "send smartDeviceLinkp to url");\r
+                                       // URL has data, attempt to post request to external server\r
+                                       Thread handleOffboardSmartDeviceLinkTransmissionTread = new Thread() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       sendSyncPDataToUrl(msg.getUrl(), msg.getSyncPData(), msg.getTimeout());\r
+                                               }\r
+                                       };\r
+\r
+                                       handleOffboardSmartDeviceLinkTransmissionTread.start();\r
+                               }\r
+                       } else if (functionName.equals(Names.OnPermissionsChange)) {\r
+                               //OnPermissionsChange\r
+                               \r
+                               final OnPermissionsChange msg = new OnPermissionsChange(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onOnPermissionsChange(msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onOnPermissionsChange(msg);\r
+                               }\r
+                       } else if (functionName.equals(Names.OnTBTClientState)) {\r
+                               // OnTBTClientState\r
+                               \r
+                               final OnTBTClientState msg = new OnTBTClientState(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onOnTBTClientState(msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onOnTBTClientState(msg);\r
+                               }\r
+                       } else if (functionName.equals(Names.OnButtonPress)) {\r
+                               // OnButtonPress\r
+                               \r
+                               final OnButtonPress msg = new OnButtonPress(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onOnButtonPress((OnButtonPress)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onOnButtonPress((OnButtonPress)msg);\r
+                               }\r
+                       } else if (functionName.equals(Names.OnButtonEvent)) {\r
+                               // OnButtonEvent\r
+                               \r
+                               final OnButtonEvent msg = new OnButtonEvent(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onOnButtonEvent((OnButtonEvent)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onOnButtonEvent((OnButtonEvent)msg);\r
+                               }\r
+                       } else if (functionName.equals(Names.OnLanguageChange)) {\r
+                               // OnLanguageChange\r
+                               \r
+                               final OnLanguageChange msg = new OnLanguageChange(hash);\r
+                               if (_callbackToUIThread) {\r
+                                       // Run in UI thread\r
+                                       _mainUIHandler.post(new Runnable() {\r
+                                               @Override\r
+                                               public void run() {\r
+                                                       _proxyListener.onOnLanguageChange((OnLanguageChange)msg);\r
+                                               }\r
+                                       });\r
+                               } else {\r
+                                       _proxyListener.onOnLanguageChange((OnLanguageChange)msg);\r
+                               }\r
+                       } else if (functionName.equals(Names.OnAudioPassThru)) {                                \r
+                               // OnAudioPassThru\r
+                               final OnAudioPassThru msg = new OnAudioPassThru(hash);\r
+                if (_callbackToUIThread) {\r
+                    // Run in UI thread\r
+                    _mainUIHandler.post(new Runnable() {\r
+                        @Override\r
+                        public void run() {\r
+                                               _proxyListener.onOnAudioPassThru((OnAudioPassThru)msg);\r
+                        }\r
+                    });\r
+                } else {\r
+                                       _proxyListener.onOnAudioPassThru((OnAudioPassThru)msg);\r
+                }                              \r
+                       } else if (functionName.equals(Names.OnVehicleData)) {               \r
+               try {\r
+                                       Class<?> cls = Class.forName(Names.OnVehicleDataExtend);\r
+                                       Constructor con = cls.getConstructor(new Class[]{Hashtable.class});                                                                                                                     \r
+                                       final Object msg = con.newInstance(hash);       \r
+                                       // OnVehicleDataExtend\r
+                       if (_callbackToUIThread) {\r
+                           // Run in UI thread\r
+                           _mainUIHandler.post(new Runnable() {\r
+                               @Override\r
+                               public void run() {\r
+                                   _proxyListener.onOnVehicleData((OnVehicleData)msg);\r
+                               }\r
+                           });\r
+                       } else {\r
+                           _proxyListener.onOnVehicleData((OnVehicleData)msg);   \r
+                       }                                                                       \r
+                               }                               \r
+               catch(Exception e) {\r
+                                       // OnVehicleData\r
+                       final OnVehicleData msg = new OnVehicleData(hash);\r
+                       if (_callbackToUIThread) {\r
+                           // Run in UI thread\r
+                           _mainUIHandler.post(new Runnable() {\r
+                               @Override\r
+                               public void run() {\r
+                                   _proxyListener.onOnVehicleData((OnVehicleData)msg);\r
+                               }\r
+                           });\r
+                       } else {\r
+                           _proxyListener.onOnVehicleData((OnVehicleData)msg);\r
+                       }\r
+                               } \r
+                       }\r
+                       else if (functionName.equals(Names.OnAppInterfaceUnregistered)) {\r
+                               // OnAppInterfaceUnregistered\r
+                               \r
+                               _appInterfaceRegisterd = false;\r
+                               synchronized(APP_INTERFACE_REGISTERED_LOCK) {\r
+                                       APP_INTERFACE_REGISTERED_LOCK.notify();\r
+                               }\r
+                               \r
+                               final OnAppInterfaceUnregistered msg = new OnAppInterfaceUnregistered(hash);\r
+                                                               \r
+                               if (_advancedLifecycleManagementEnabled) {\r
+                                       // This requires the proxy to be cycled\r
+                    if (this.getCurrentTransportType() == TransportType.BLUETOOTH) {\r
+                        cycleProxy(SmartDeviceLinkDisconnectedReason.convertAppInterfaceUnregisteredReason(msg.getReason()));\r
+                    } else {\r
+                        Log.e(this.getClass().getName(), "HandleRPCMessage. No cycle required if transport is TCP");\r
+                    }\r
+                } else {\r
+                                       if (_callbackToUIThread) {\r
+                                               // Run in UI thread\r
+                                               _mainUIHandler.post(new Runnable() {\r
+                                                       @Override\r
+                                                       public void run() {\r
+                                                               ((IProxyListener)_proxyListener).onOnAppInterfaceUnregistered(msg);\r
+                                                       }\r
+                                               });\r
+                                       } else {\r
+                                               ((IProxyListener)_proxyListener).onOnAppInterfaceUnregistered(msg);\r
+                                       }\r
+                                       \r
+                                       notifyProxyClosed("OnAppInterfaceUnregistered", null);\r
+                               }\r
+                       } else {\r
+                               if (_smartDeviceLinkMsgVersion != null) {\r
+                                       DebugTool.logInfo("Unrecognized notification Message: " + functionName.toString() + \r
+                                                       " connected to SMARTDEVICELINK using message version: " + _smartDeviceLinkMsgVersion.getMajorVersion() + "." + _smartDeviceLinkMsgVersion.getMinorVersion());\r
+                               } else {\r
+                                       DebugTool.logInfo("Unrecognized notification Message: " + functionName.toString());\r
+                               }\r
+                       } // end-if\r
+               } // end-if notification\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Proxy received RPC Message: " + functionName, SMARTDEVICELINK_LIB_TRACE_KEY);\r
+       }\r
+       \r
+       /**\r
+        * Takes an RPCRequest and sends it to SMARTDEVICELINK.  Responses are captured through callback on IProxyListener.  \r
+        * \r
+        * @param request\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void sendRPCRequest(RPCRequest request) throws SmartDeviceLinkException {\r
+               if (_proxyDisposed) {\r
+                       throw new SmartDeviceLinkException("This object has been disposed, it is no long capable of executing methods.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_PROXY_DISPOSED);\r
+               }\r
+               \r
+               // Test if request is null\r
+               if (request == null) {\r
+                       SmartDeviceLinkTrace.logProxyEvent("Application called sendRPCRequest method with a null RPCRequest.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+                       throw new IllegalArgumentException("sendRPCRequest cannot be called with a null request.");\r
+               }\r
+               \r
+               SmartDeviceLinkTrace.logProxyEvent("Application called sendRPCRequest method for RPCRequest: ." + request.getFunctionName(), SMARTDEVICELINK_LIB_TRACE_KEY);\r
+                       \r
+               // Test if smartDeviceLinkConnection is null\r
+               synchronized(CONNECTION_REFERENCE_LOCK) {\r
+                       if (_smartDeviceLinkConnection == null || !_smartDeviceLinkConnection.getIsConnected()) {\r
+                               SmartDeviceLinkTrace.logProxyEvent("Application attempted to send and RPCRequest without a connected transport.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+                               throw new SmartDeviceLinkException("There is no valid connection to SMARTDEVICELINK. sendRPCRequest cannot be called until SMARTDEVICELINK has been connected.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);\r
+                       }\r
+               }\r
+               \r
+               // Test for illegal correlation ID\r
+               if (isCorrelationIDProtected(request.getCorrelationID())) {\r
+                       \r
+                       SmartDeviceLinkTrace.logProxyEvent("Application attempted to use the reserved correlation ID, " + request.getCorrelationID(), SMARTDEVICELINK_LIB_TRACE_KEY);\r
+                       throw new SmartDeviceLinkException("Invalid correlation ID. The correlation ID, " + request.getCorrelationID()\r
+                                       + " , is a reserved correlation ID.", SmartDeviceLinkExceptionCause.RESERVED_CORRELATION_ID);\r
+               }\r
+               \r
+               // Throw exception if RPCRequest is sent when SMARTDEVICELINK is unavailable \r
+               if (!_appInterfaceRegisterd && request.getFunctionName() != Names.RegisterAppInterface) {\r
+                       \r
+                       SmartDeviceLinkTrace.logProxyEvent("Application attempted to send an RPCRequest (non-registerAppInterface), before the interface was registerd.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+                       throw new SmartDeviceLinkException("SMARTDEVICELINK is currently unavailable. RPC Requests cannot be sent.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_UNAVAILALBE);\r
+               }\r
+                               \r
+               if (_advancedLifecycleManagementEnabled) {\r
+                       if (               request.getFunctionName() == Names.RegisterAppInterface\r
+                                       || request.getFunctionName() == Names.UnregisterAppInterface) {\r
+                               \r
+                               SmartDeviceLinkTrace.logProxyEvent("Application attempted to send a RegisterAppInterface or UnregisterAppInterface while using ALM.", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+                               throw new SmartDeviceLinkException("The RPCRequest, " + request.getFunctionName() + \r
+                                               ", is unnallowed using the Advanced Lifecycle Management Model.", SmartDeviceLinkExceptionCause.INCORRECT_LIFECYCLE_MODEL);\r
+                       }\r
+               }\r
+               \r
+               sendRPCRequestPrivate(request);\r
+       } // end-method\r
+       \r
+       protected void notifyProxyClosed(final String info, final Exception e) {                \r
+               SmartDeviceLinkTrace.logProxyEvent("NotifyProxyClose", SMARTDEVICELINK_LIB_TRACE_KEY);\r
+               \r
+               OnProxyClosed message = new OnProxyClosed(info, e);\r
+               queueInternalMessage(message);\r
+       }\r
+\r
+       private void passErrorToProxyListener(final String info, final Exception e) {\r
+                               \r
+               OnError message = new OnError(info, e);\r
+               queueInternalMessage(message);\r
+       }\r
+       \r
+       private void startRPCProtocolSession(byte sessionID, String correlationID) {\r
+               _rpcSessionID = sessionID;\r
+               \r
+               // Set Proxy Lifecyclek Available\r
+               if (_advancedLifecycleManagementEnabled) {\r
+                       \r
+                       try {\r
+                               registerAppInterfacePrivate(\r
+                                               _smartDeviceLinkMsgVersionRequest,\r
+                                               _applicationName,\r
+                                               _ttsName,\r
+                                               _ngnMediaScreenAppName,\r
+                                               _vrSynonyms,\r
+                                               _isMediaApp, \r
+                                               _smartDeviceLinkLanguageDesired,\r
+                                               _hmiDisplayLanguageDesired,\r
+                                               _appType,\r
+                                               _appID,\r
+                                               _autoActivateIdDesired,\r
+                                               REGISTER_APP_INTERFACE_CORRELATION_ID);\r
+                               \r
+                       } catch (Exception e) {\r
+                               notifyProxyClosed("Failed to register application interface with SMARTDEVICELINK. Check parameter values given to SmartDeviceLinkProxy constructor.", e);\r
+                       }\r
+               } else {\r
+                       InternalProxyMessage message = new InternalProxyMessage(Names.OnProxyOpened);\r
+                       queueInternalMessage(message);\r
+               }\r
+       }\r
+       \r
+       // Queue internal callback message\r
+       private void queueInternalMessage(InternalProxyMessage message) {\r
+               synchronized(INTERNAL_MESSAGE_QUEUE_THREAD_LOCK) {\r
+                       if (_internalProxyMessageDispatcher != null) {\r
+                               _internalProxyMessageDispatcher.queueMessage(message);\r
+                       }\r
+               }\r
+       }\r
+       \r
+       // Queue incoming ProtocolMessage\r
+       private void queueIncomingMessage(ProtocolMessage message) {\r
+               synchronized(INCOMING_MESSAGE_QUEUE_THREAD_LOCK) {\r
+                       if (_incomingProxyMessageDispatcher != null) {\r
+                               _incomingProxyMessageDispatcher.queueMessage(message);\r
+                       }\r
+               }\r
+       }\r
+       \r
+       public void setAppService(Service mService)\r
+       {\r
+               _appService = mService;\r
+       }\r
+\r
+       /******************** Public Helper Methods *************************/\r
+       \r
+       /*Begin V1 Enhanced helper*/\r
+       \r
+       /**\r
+        *Sends an AddCommand RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        *\r
+        *@param commandID -Unique command ID of the command to add.\r
+        *@param menuText  -Menu text for optional sub value containing menu parameters.\r
+        *@param parentID  -Menu parent ID for optional sub value containing menu parameters.\r
+        *@param position  -Menu position for optional sub value containing menu parameters.\r
+        *@param vrCommands -VR synonyms for this AddCommand.\r
+        *@param IconValue -A static hex icon value or the binary image file name identifier (sent by the PutFile RPC).\r
+        *@param IconType -Describes whether the image is static or dynamic\r
+        *@param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        *@throws SmartDeviceLinkException\r
+        */\r
+       public void addCommand(Integer commandID,\r
+                       String menuText, Integer parentID, Integer position,\r
+                       Vector<String> vrCommands, String IconValue, ImageType IconType, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               AddCommand msg = RPCRequestFactory.buildAddCommand(commandID, menuText, parentID, position,\r
+                       vrCommands, IconValue, IconType, correlationID);\r
+               \r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        *Sends an AddCommand RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        *\r
+        *@param commandID -Unique command ID of the command to add.\r
+        *@param menuText -Menu text for optional sub value containing menu parameters.\r
+        *@param position -Menu position for optional sub value containing menu parameters.\r
+        *@param vrCommands -VR synonyms for this AddCommand.\r
+        *@param IconValue -A static hex icon value or the binary image file name identifier (sent by the PutFile RPC).\r
+        *@param IconType -Describes whether the image is static or dynamic\r
+        *@param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        *@throws SmartDeviceLinkException\r
+        */\r
+       public void addCommand(Integer commandID,\r
+                       String menuText, Integer position,\r
+                       Vector<String> vrCommands, String IconValue, ImageType IconType, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               addCommand(commandID, menuText, null, position, vrCommands, IconValue, IconType, correlationID);\r
+       }\r
+       \r
+       /**\r
+        *Sends an AddCommand RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        *\r
+        *@param commandID -Unique command ID of the command to add.\r
+        *@param menuText -Menu text for optional sub value containing menu parameters.\r
+        *@param position -Menu position for optional sub value containing menu parameters.\r
+        *@param IconValue -A static hex icon value or the binary image file name identifier (sent by the PutFile RPC).\r
+        *@param IconType -Describes whether the image is static or dynamic\r
+        *@param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        *@throws SmartDeviceLinkException\r
+        */\r
+       public void addCommand(Integer commandID,\r
+                       String menuText, Integer position, String IconValue, ImageType IconType,\r
+                       Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               addCommand(commandID, menuText, null, position, null, IconValue, IconType, correlationID);\r
+       }\r
+       \r
+       /**\r
+        *Sends an AddCommand RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        *\r
+        *@param commandID -Unique command ID of the command to add.\r
+        *@param menuText -Menu text for optional sub value containing menu parameters.\r
+        *@param IconValue -A static hex icon value or the binary image file name identifier (sent by the PutFile RPC).\r
+        *@param IconType -Describes whether the image is static or dynamic\r
+        *@param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        *@throws SmartDeviceLinkException\r
+        */\r
+       public void addCommand(Integer commandID,\r
+                       String menuText, String IconValue, ImageType IconType, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               addCommand(commandID, menuText, null, null, null, IconValue, IconType, correlationID);\r
+       }\r
+       \r
+       /**\r
+        * Sends an AddCommand RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param commandID -Unique command ID of the command to add.\r
+        * @param menuText -Menu text for optional sub value containing menu parameters.\r
+        * @param vrCommands -VR synonyms for this AddCommand.\r
+        * @param IconValue -A static hex icon value or the binary image file name identifier (sent by the PutFile RPC).\r
+        * @param IconType -Describes whether the image is static or dynamic\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void addCommand(Integer commandID,\r
+                       String menuText, Vector<String> vrCommands, String IconValue, ImageType IconType, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               addCommand(commandID, menuText, null, null, vrCommands, IconValue, IconType, correlationID);\r
+       }\r
+       \r
+       /**\r
+        * Sends an AddCommand RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param commandID -Unique command ID of the command to add.\r
+        * @param vrCommands -VR synonyms for this AddCommand.\r
+        * @param IconValue -A static hex icon value or the binary image file name identifier (sent by the PutFile RPC).\r
+        * @param IconType -Describes whether the image is static or dynamic\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void addCommand(Integer commandID,\r
+                       Vector<String> vrCommands, String IconValue, ImageType IconType, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               addCommand(commandID, null, null, null, vrCommands, IconValue, IconType, correlationID);\r
+       }\r
+\r
+       /*End V1 Enhanced helper*/\r
+       \r
+       /**\r
+        *Sends an AddCommand RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        *\r
+        *@param commandID -Unique command ID of the command to add.\r
+        *@param menuText -Menu text for optional sub value containing menu parameters.\r
+        *@param parentID  -Menu parent ID for optional sub value containing menu parameters.\r
+        *@param position  -Menu position for optional sub value containing menu parameters.\r
+        *@param vrCommands -VR synonyms for this AddCommand.\r
+        *@param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        *@throws SmartDeviceLinkException\r
+        */\r
+       public void addCommand(Integer commandID,\r
+                       String menuText, Integer parentID, Integer position,\r
+                       Vector<String> vrCommands, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               AddCommand msg = RPCRequestFactory.buildAddCommand(commandID, menuText, parentID, position,\r
+                       vrCommands, correlationID);\r
+               \r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        *Sends an AddCommand RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        *\r
+        *@param commandID -Unique command ID of the command to add.\r
+        *@param menuText -Menu text for optional sub value containing menu parameters.\r
+        *@param position  -Menu position for optional sub value containing menu parameters.\r
+        *@param vrCommands -VR synonyms for this AddCommand.\r
+        *@param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        *@throws SmartDeviceLinkException\r
+        */\r
+       public void addCommand(Integer commandID,\r
+                       String menuText, Integer position,\r
+                       Vector<String> vrCommands, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               addCommand(commandID, menuText, null, position, vrCommands, correlationID);\r
+       }\r
+       \r
+       /**\r
+        *Sends an AddCommand RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        *\r
+        *@param commandID -Unique command ID of the command to add.\r
+        *@param menuText -Menu text for optional sub value containing menu parameters.\r
+        *@param position  -Menu position for optional sub value containing menu parameters.\r
+        *@param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        *@throws SmartDeviceLinkException\r
+        */\r
+       public void addCommand(Integer commandID,\r
+                       String menuText, Integer position,\r
+                       Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               addCommand(commandID, menuText, null, position, null, correlationID);\r
+       }\r
+       \r
+       /**\r
+        *Sends an AddCommand RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        *\r
+        *@param commandID -Unique command ID of the command to add.\r
+        *@param menuText -Menu text for optional sub value containing menu parameters.\r
+        *@param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        *@throws SmartDeviceLinkException\r
+        */\r
+       public void addCommand(Integer commandID,\r
+                       String menuText, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               Vector<String> vrCommands = null;\r
+               \r
+               addCommand(commandID, menuText, null, null, vrCommands, correlationID);\r
+       }\r
+       \r
+       /**\r
+        * Sends an AddCommand RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        *@param commandID -Unique command ID of the command to add.\r
+        *@param menuText -Menu text for optional sub value containing menu parameters.\r
+        *@param vrCommands -VR synonyms for this AddCommand.\r
+        *@param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        *@throws SmartDeviceLinkException\r
+        */\r
+       public void addCommand(Integer commandID,\r
+                       String menuText, Vector<String> vrCommands, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               addCommand(commandID, menuText, null, null, vrCommands, correlationID);\r
+       }\r
+       \r
+       /**\r
+        * Sends an AddCommand RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        *@param commandID -Unique command ID of the command to add.\r
+        *@param vrCommands -VR synonyms for this AddCommand.\r
+        *@param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        *@throws SmartDeviceLinkException\r
+        */\r
+       public void addCommand(Integer commandID,\r
+                       Vector<String> vrCommands, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               addCommand(commandID, null, null, null, vrCommands, correlationID);\r
+       }\r
+               \r
+       \r
+       /**\r
+        * Sends an AddSubMenu RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param menuID -Unique ID of the sub menu to add.\r
+        * @param menuName -Text to show in the menu for this sub menu.\r
+        * @param position -Position within the items that are are at top level of the in application menu.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void addSubMenu(Integer menuID, String menuName,\r
+                       Integer position, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               AddSubMenu msg = RPCRequestFactory.buildAddSubMenu(menuID, menuName,\r
+                               position, correlationID);\r
+               \r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends an AddSubMenu RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param menuID -Unique ID of the sub menu to add.\r
+        * @param menuName -Text to show in the menu for this sub menu.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void addSubMenu(Integer menuID, String menuName,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               addSubMenu(menuID, menuName, null, correlationID);\r
+       }\r
+       \r
+       /**\r
+        * Sends an EncodedData RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param data -Contains base64 encoded string of SmartDeviceLinkP packets.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void encodedSyncPData(Vector<String> data, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               Log.i("pt", "encodedSyncPData() giving to smartDeviceLink");\r
+               EncodedSyncPData msg = RPCRequestFactory.buildEncodedSyncPData(data, correlationID);\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends a Data RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param data \r
+        * @param correlationID\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void SyncPData(byte[] data, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               Log.i("pt", "SyncPData() giving to smartDeviceLink");\r
+               SyncPData msg = RPCRequestFactory.buildSyncPData(data, correlationID);\r
+               sendRPCRequest(msg);\r
+       }\r
+\r
+       /*Begin V1 Enhanced helper*/    \r
+       \r
+       \r
+       /**\r
+        * Sends an Alert RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param ttsText -The text to speech message in the form of a string.\r
+        * @param alertText1 -The first line of the alert text field.\r
+        * @param alertText2 -The second line of the alert text field.\r
+        * @param alertText3 -The optional third line of the alert text field.\r
+        * @param playTone -Defines if tone should be played.\r
+        * @param duration -Timeout in milliseconds.\r
+        * @param softButtons -A list of App defined SoftButtons.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void alert(String ttsText, String alertText1,\r
+                       String alertText2, String alertText3, Boolean playTone, Integer duration, Vector<SoftButton> softButtons,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+\r
+               Alert msg = RPCRequestFactory.buildAlert(ttsText, alertText1, alertText2, alertText3, playTone, duration, softButtons, correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends an Alert RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param ttsChunks -Text/phonemes to speak in the form of ttsChunks.\r
+        * @param alertText1 -The first line of the alert text field.\r
+        * @param alertText2 -The second line of the alert text field.\r
+        * @param alertText3 -The optional third line of the alert text field.\r
+        * @param playTone -Defines if tone should be played.\r
+        * @param duration -Timeout in milliseconds.\r
+        * @param softButtons -A list of App defined SoftButtons.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void alert(Vector<TTSChunk> ttsChunks,\r
+                       String alertText1, String alertText2, String alertText3, Boolean playTone,\r
+                       Integer duration, Vector<SoftButton> softButtons, Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               Alert msg = RPCRequestFactory.buildAlert(ttsChunks, alertText1, alertText2, alertText3, playTone, duration, softButtons, correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends an Alert RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param ttsText -The text to speech message in the form of a string.\r
+        * @param playTone -Defines if tone should be played.\r
+        * @param softButtons -A list of App defined SoftButtons.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void alert(String ttsText, Boolean playTone, Vector<SoftButton> softButtons,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               alert(ttsText, null, null, null, playTone, null, softButtons, correlationID);\r
+       }\r
+       \r
+       /**\r
+        * Sends an Alert RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param chunks -A list of text/phonemes to speak in the form of ttsChunks.\r
+        * @param playTone -Defines if tone should be played.\r
+        * @param softButtons -A list of App defined SoftButtons.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void alert(Vector<TTSChunk> chunks, Boolean playTone, Vector<SoftButton> softButtons,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               alert(chunks, null, null, null, playTone, null, softButtons, correlationID);\r
+       }\r
+       \r
+       /**\r
+        * Sends an Alert RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param alertText1 -The first line of the alert text field.\r
+        * @param alertText2 -The second line of the alert text field.\r
+        * @param alertText3 -The optional third line of the alert text field.\r
+        * @param playTone -Defines if tone should be played.\r
+        * @param duration -Timeout in milliseconds.\r
+        * @param softButtons -A list of App defined SoftButtons.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void alert(String alertText1, String alertText2, String alertText3,\r
+                       Boolean playTone, Integer duration, Vector<SoftButton> softButtons, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               alert((Vector<TTSChunk>)null, alertText1, alertText2, alertText3, playTone, duration, softButtons, correlationID);\r
+       }\r
+               \r
+       /*End V1 Enhanced helper*/\r
+       \r
+       /**\r
+        * Sends an Alert RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param ttsText -The text to speech message in the form of a string.\r
+        * @param alertText1 -The first line of the alert text field.\r
+        * @param alertText2 -The second line of the alert text field.\r
+        * @param playTone -Defines if tone should be played.\r
+        * @param duration -Timeout in milliseconds.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void alert(String ttsText, String alertText1,\r
+                       String alertText2, Boolean playTone, Integer duration,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+\r
+               Alert msg = RPCRequestFactory.buildAlert(ttsText, alertText1, alertText2, \r
+                               playTone, duration, correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends an Alert RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param ttsChunks -A list of text/phonemes to speak in the form of ttsChunks.\r
+        * @param alertText1 -The first line of the alert text field.\r
+        * @param alertText2 -The second line of the alert text field.\r
+        * @param playTone -Defines if tone should be played.\r
+        * @param duration -Timeout in milliseconds.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void alert(Vector<TTSChunk> ttsChunks,\r
+                       String alertText1, String alertText2, Boolean playTone,\r
+                       Integer duration, Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               Alert msg = RPCRequestFactory.buildAlert(ttsChunks, alertText1, alertText2, playTone,\r
+                               duration, correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends an Alert RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param ttsText -The text to speech message in the form of a string.\r
+        * @param playTone -Defines if tone should be played.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void alert(String ttsText, Boolean playTone,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               alert(ttsText, null, null, playTone, null, correlationID);\r
+       }\r
+       \r
+       /**\r
+        * Sends an Alert RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param chunks -A list of text/phonemes to speak in the form of ttsChunks.\r
+        * @param playTone -Defines if tone should be played.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void alert(Vector<TTSChunk> chunks, Boolean playTone,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               alert(chunks, null, null, playTone, null, correlationID);\r
+       }\r
+       \r
+       /**\r
+        * Sends an Alert RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param alertText1 -The first line of the alert text field.\r
+        * @param alertText2 -The second line of the alert text field.\r
+        * @param playTone -Defines if tone should be played.\r
+        * @param duration -Timeout in milliseconds.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void alert(String alertText1, String alertText2,\r
+                       Boolean playTone, Integer duration, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               alert((Vector<TTSChunk>)null, alertText1, alertText2, playTone, duration, correlationID);\r
+       }\r
+       \r
+       /**\r
+        * Sends a CreateInteractionChoiceSet RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param choiceSet\r
+        * @param interactionChoiceSetID\r
+        * @param correlationID\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void createInteractionChoiceSet(\r
+                       Vector<Choice> choiceSet, Integer interactionChoiceSetID,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               CreateInteractionChoiceSet msg = RPCRequestFactory.buildCreateInteractionChoiceSet(\r
+                               choiceSet, interactionChoiceSetID, correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends a DeleteCommand RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param commandID -ID of the command(s) to delete.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void deleteCommand(Integer commandID,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               DeleteCommand msg = RPCRequestFactory.buildDeleteCommand(commandID, correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends a DeleteInteractionChoiceSet RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param interactionChoiceSetID -ID of the interaction choice set to delete.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void deleteInteractionChoiceSet(\r
+                       Integer interactionChoiceSetID, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               DeleteInteractionChoiceSet msg = RPCRequestFactory.buildDeleteInteractionChoiceSet(\r
+                               interactionChoiceSetID, correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends a DeleteSubMenu RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param menuID -The menuID of the submenu to delete.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void deleteSubMenu(Integer menuID,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               DeleteSubMenu msg = RPCRequestFactory.buildDeleteSubMenu(menuID, correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       \r
+       \r
+       /*Begin V1 Enhanced helper*/\r
+       \r
+       /**\r
+        * Sends a PerformInteraction RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param initPrompt -Intial prompt spoken to the user at the start of an interaction.          \r
+        * @param displayText -Text to be displayed first.\r
+        * @param interactionChoiceSetID -Interaction choice set IDs to use with an interaction.\r
+        * @param vrHelp -Suggested VR Help Items to display on-screen during Perform Interaction.              \r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void performInteraction(String initPrompt,\r
+                       String displayText, Integer interactionChoiceSetID, Vector<VrHelpItem> vrHelp,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               PerformInteraction msg = RPCRequestFactory.buildPerformInteraction(initPrompt,\r
+                               displayText, interactionChoiceSetID, vrHelp, correlationID);\r
+               \r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends a PerformInteraction RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param initPrompt -Intial prompt spoken to the user at the start of an interaction.          \r
+        * @param displayText -Text to be displayed first.\r
+        * @param interactionChoiceSetID -Interaction choice set IDs to use with an interaction.\r
+        * @param helpPrompt -Help text that is spoken when a user speaks "help" during the interaction.\r
+        * @param timeoutPrompt -Timeout text that is spoken when a VR interaction times out.\r
+        * @param interactionMode - The method in which the user is notified and uses the interaction (Manual,VR,Both).\r
+        * @param timeout -Timeout in milliseconds.\r
+        * @param vrHelp -Suggested VR Help Items to display on-screen during Perform Interaction.              \r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void performInteraction(String initPrompt,\r
+                       String displayText, Integer interactionChoiceSetID,\r
+                       String helpPrompt, String timeoutPrompt,\r
+                       InteractionMode interactionMode, Integer timeout, Vector<VrHelpItem> vrHelp,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               PerformInteraction msg = RPCRequestFactory.buildPerformInteraction(\r
+                               initPrompt, displayText, interactionChoiceSetID,\r
+                               helpPrompt, timeoutPrompt, interactionMode, \r
+                               timeout, vrHelp, correlationID);\r
+               \r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends a PerformInteraction RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param initPrompt -Intial prompt spoken to the user at the start of an interaction.          \r
+        * @param displayText -Text to be displayed first.\r
+        * @param interactionChoiceSetIDList -A list of interaction choice set IDs to use with an interaction.\r
+        * @param helpPrompt -Help text that is spoken when a user speaks "help" during the interaction.\r
+        * @param timeoutPrompt -Timeout text that is spoken when a VR interaction times out.\r
+        * @param interactionMode - The method in which the user is notified and uses the interaction (Manual,VR,Both).\r
+        * @param timeout -Timeout in milliseconds.\r
+        * @param vrHelp -Suggested VR Help Items to display on-screen during Perform Interaction.              \r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void performInteraction(String initPrompt,\r
+                       String displayText, Vector<Integer> interactionChoiceSetIDList,\r
+                       String helpPrompt, String timeoutPrompt,\r
+                       InteractionMode interactionMode, Integer timeout, Vector<VrHelpItem> vrHelp,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               PerformInteraction msg = RPCRequestFactory.buildPerformInteraction(initPrompt,\r
+                               displayText, interactionChoiceSetIDList,\r
+                               helpPrompt, timeoutPrompt, interactionMode, timeout, vrHelp,\r
+                               correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends a PerformInteraction RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param initChunks -A list of text/phonemes to speak for the initial prompt in the form of ttsChunks.\r
+        * @param displayText -Text to be displayed first.\r
+        * @param interactionChoiceSetIDList -A list of interaction choice set IDs to use with an interaction.\r
+        * @param helpChunks -A list of text/phonemes to speak for the help text that is spoken when a user speaks "help" during the interaction.\r
+        * @param timeoutChunks A list of text/phonems to speak for the timeout text that is spoken when a VR interaction times out.\r
+        * @param interactionMode - The method in which the user is notified and uses the interaction (Manual,VR,Both).\r
+        * @param timeout -Timeout in milliseconds.\r
+        * @param vrHelp -Suggested VR Help Items to display on-screen during Perform Interaction.              \r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void performInteraction(\r
+                       Vector<TTSChunk> initChunks, String displayText,\r
+                       Vector<Integer> interactionChoiceSetIDList,\r
+                       Vector<TTSChunk> helpChunks, Vector<TTSChunk> timeoutChunks,\r
+                       InteractionMode interactionMode, Integer timeout, Vector<VrHelpItem> vrHelp,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               PerformInteraction msg = RPCRequestFactory.buildPerformInteraction(\r
+                               initChunks, displayText, interactionChoiceSetIDList,\r
+                               helpChunks, timeoutChunks, interactionMode, timeout,vrHelp,\r
+                               correlationID);\r
+               \r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /*End V1 Enhanced*/\r
+       \r
+       /**\r
+        * Sends a PerformInteraction RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param initPrompt -Intial prompt spoken to the user at the start of an interaction.          \r
+        * @param displayText -Text to be displayed first.\r
+        * @param interactionChoiceSetID -Interaction choice set IDs to use with an interaction.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void performInteraction(String initPrompt,\r
+                       String displayText, Integer interactionChoiceSetID,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               PerformInteraction msg = RPCRequestFactory.buildPerformInteraction(initPrompt,\r
+                               displayText, interactionChoiceSetID, correlationID);\r
+               \r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends a PerformInteraction RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param initPrompt -Intial prompt spoken to the user at the start of an interaction.          \r
+        * @param displayText -Text to be displayed first.\r
+        * @param interactionChoiceSetID -Interaction choice set IDs to use with an interaction.\r
+        * @param helpPrompt -Help text that is spoken when a user speaks "help" during the interaction. \r
+        * @param timeoutPrompt -Timeout text that is spoken when a VR interaction times out.\r
+        * @param interactionMode - The method in which the user is notified and uses the interaction (Manual,VR,Both).\r
+        * @param timeout -Timeout in milliseconds.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void performInteraction(String initPrompt,\r
+                       String displayText, Integer interactionChoiceSetID,\r
+                       String helpPrompt, String timeoutPrompt,\r
+                       InteractionMode interactionMode, Integer timeout,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               PerformInteraction msg = RPCRequestFactory.buildPerformInteraction(\r
+                               initPrompt, displayText, interactionChoiceSetID,\r
+                               helpPrompt, timeoutPrompt, interactionMode, \r
+                               timeout, correlationID);\r
+               \r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends a PerformInteraction RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param initPrompt -Intial prompt spoken to the user at the start of an interaction.          \r
+        * @param displayText -Text to be displayed first.\r
+        * @param interactionChoiceSetIDList -A list of interaction choice set IDs to use with an interaction.\r
+        * @param helpPrompt -Help text that is spoken when a user speaks "help" during the interaction. \r
+        * @param timeoutPrompt -Timeout text that is spoken when a VR interaction times out.\r
+        * @param interactionMode - The method in which the user is notified and uses the interaction (Manual,VR,Both).\r
+        * @param timeout -Timeout in milliseconds.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void performInteraction(String initPrompt,\r
+                       String displayText, Vector<Integer> interactionChoiceSetIDList,\r
+                       String helpPrompt, String timeoutPrompt,\r
+                       InteractionMode interactionMode, Integer timeout,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               PerformInteraction msg = RPCRequestFactory.buildPerformInteraction(initPrompt,\r
+                               displayText, interactionChoiceSetIDList,\r
+                               helpPrompt, timeoutPrompt, interactionMode, timeout,\r
+                               correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends a PerformInteraction RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param initChunks -A list of text/phonemes to speak for the initial prompt in the form of ttsChunks.\r
+        * @param displayText -Text to be displayed first.\r
+        * @param interactionChoiceSetIDList -A list of interaction choice set IDs to use with an interaction.\r
+        * @param helpChunks -A list of text/phonemes to speak for the help text that is spoken when a user speaks "help" during the interaction.\r
+        * @param timeoutChunks A list of text/phonems to speak for the timeout text that is spoken when a VR interaction times out.\r
+        * @param interactionMode - The method in which the user is notified and uses the interaction (Manual,VR,Both).\r
+        * @param timeout -Timeout in milliseconds.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void performInteraction(\r
+                       Vector<TTSChunk> initChunks, String displayText,\r
+                       Vector<Integer> interactionChoiceSetIDList,\r
+                       Vector<TTSChunk> helpChunks, Vector<TTSChunk> timeoutChunks,\r
+                       InteractionMode interactionMode, Integer timeout,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               PerformInteraction msg = RPCRequestFactory.buildPerformInteraction(\r
+                               initChunks, displayText, interactionChoiceSetIDList,\r
+                               helpChunks, timeoutChunks, interactionMode, timeout,\r
+                               correlationID);\r
+               \r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       // Protected registerAppInterface used to ensure only non-ALM applications call\r
+       // reqisterAppInterface\r
+       protected void registerAppInterfacePrivate(\r
+                       smartdevicelinkMsgVersion smartDeviceLinkMsgVersion, String appName, Vector<TTSChunk> ttsName,\r
+                       String ngnMediaScreenAppName, Vector<String> vrSynonyms, Boolean isMediaApp, \r
+                       Language languageDesired, Language hmiDisplayLanguageDesired, Vector<AppHMIType> appType,\r
+                       String appID, String autoActivateID, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               RegisterAppInterface msg = RPCRequestFactory.buildRegisterAppInterface(\r
+                               smartDeviceLinkMsgVersion, appName, ttsName, ngnMediaScreenAppName, vrSynonyms, isMediaApp, \r
+                               languageDesired, hmiDisplayLanguageDesired, appType, appID, correlationID);\r
+\r
+               sendRPCRequestPrivate(msg);\r
+       }\r
+       \r
+       /*Begin V1 Enhanced helper function*/\r
+\r
+       /**\r
+        * Sends a SetGlobalProperties RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param helpPrompt\r
+        * @param timeoutPrompt\r
+        * @param vrHelpTitle\r
+        * @param vrHelp\r
+        * @param correlationID\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void setGlobalProperties(\r
+                       String helpPrompt, String timeoutPrompt, String vrHelpTitle, Vector<VrHelpItem> vrHelp, Integer correlationID) \r
+               throws SmartDeviceLinkException {\r
+               \r
+               SetGlobalProperties req = RPCRequestFactory.buildSetGlobalProperties(helpPrompt, \r
+                               timeoutPrompt, vrHelpTitle, vrHelp, correlationID);\r
+               \r
+               sendRPCRequest(req);\r
+       }\r
+       \r
+       /**\r
+        * Sends a SetGlobalProperties RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param helpChunks\r
+        * @param timeoutChunks\r
+        * @param vrHelpTitle\r
+        * @param vrHelp\r
+        * @param correlationID\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void setGlobalProperties(\r
+                       Vector<TTSChunk> helpChunks, Vector<TTSChunk> timeoutChunks, String vrHelpTitle, Vector<VrHelpItem> vrHelp,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               SetGlobalProperties req = RPCRequestFactory.buildSetGlobalProperties(\r
+                               helpChunks, timeoutChunks, vrHelpTitle, vrHelp, correlationID);\r
+\r
+               sendRPCRequest(req);\r
+       }\r
+\r
+       /*End V1 Enhanced helper function*/     \r
+       \r
+       /**\r
+        * Sends a SetGlobalProperties RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param helpPrompt\r
+        * @param timeoutPrompt\r
+        * @param correlationID\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void setGlobalProperties(\r
+                       String helpPrompt, String timeoutPrompt, Integer correlationID) \r
+               throws SmartDeviceLinkException {\r
+               \r
+               SetGlobalProperties req = RPCRequestFactory.buildSetGlobalProperties(helpPrompt, \r
+                               timeoutPrompt, correlationID);\r
+               \r
+               sendRPCRequest(req);\r
+       }\r
+       \r
+       /**\r
+        * Sends a SetGlobalProperties RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param helpChunks\r
+        * @param timeoutChunks\r
+        * @param correlationID\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void setGlobalProperties(\r
+                       Vector<TTSChunk> helpChunks, Vector<TTSChunk> timeoutChunks,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               SetGlobalProperties req = RPCRequestFactory.buildSetGlobalProperties(\r
+                               helpChunks, timeoutChunks, correlationID);\r
+\r
+               sendRPCRequest(req);\r
+       }\r
+       \r
+       public void resetGlobalProperties(Vector<GlobalProperty> properties,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+               \r
+               ResetGlobalProperties req = new ResetGlobalProperties();\r
+               \r
+               req.setCorrelationID(correlationID);\r
+               req.setProperties(properties);\r
+               \r
+               sendRPCRequest(req);\r
+       }\r
+                                                               \r
+       \r
+       /**\r
+        * Sends a SetMediaClockTimer RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param hours\r
+        * @param minutes\r
+        * @param seconds\r
+        * @param updateMode\r
+        * @param correlationID\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void setMediaClockTimer(Integer hours,\r
+                       Integer minutes, Integer seconds, UpdateMode updateMode,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+\r
+               SetMediaClockTimer msg = RPCRequestFactory.buildSetMediaClockTimer(hours,\r
+                               minutes, seconds, updateMode, correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Pauses the media clock. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param correlationID\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void pauseMediaClockTimer(Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+\r
+               SetMediaClockTimer msg = RPCRequestFactory.buildSetMediaClockTimer(0,\r
+                               0, 0, UpdateMode.PAUSE, correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Resumes the media clock. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param correlationID\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void resumeMediaClockTimer(Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+\r
+               SetMediaClockTimer msg = RPCRequestFactory.buildSetMediaClockTimer(0,\r
+                               0, 0, UpdateMode.RESUME, correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Clears the media clock. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param correlationID\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void clearMediaClockTimer(Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+\r
+               Show msg = RPCRequestFactory.buildShow(null, null, null, "     ", null, null, correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+               \r
+       /*Begin V1 Enhanced helper*/\r
+       /**\r
+        * Sends a Show RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param mainText1 -Text displayed in a single or upper display line.\r
+        * @param mainText2 -Text displayed on the second display line.\r
+        * @param mainText3 -Text displayed on the second "page" first display line.\r
+        * @param mainText4 -Text displayed on the second "page" second display line.\r
+        * @param statusBar\r
+        * @param mediaClock -Text value for MediaClock field.\r
+        * @param mediaTrack -Text displayed in the track field.\r
+        * @param graphic -Image struct determining whether static or dynamic image to display in app.\r
+        * @param softButtons -App defined SoftButtons.\r
+        * @param customPresets -App labeled on-screen presets.\r
+        * @param alignment -Specifies how mainText1 and mainText2s texts should be aligned on display.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void show(String mainText1, String mainText2, String mainText3, String mainText4,\r
+                       String statusBar, String mediaClock, String mediaTrack,\r
+                       Image graphic, Vector<SoftButton> softButtons, Vector <String> customPresets,\r
+                       TextAlignment alignment, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               Show msg = RPCRequestFactory.buildShow(mainText1, mainText2, mainText3, mainText4,\r
+                               statusBar, mediaClock, mediaTrack, graphic, softButtons, customPresets,\r
+                               alignment, correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends a Show RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param mainText1 -Text displayed in a single or upper display line.\r
+        * @param mainText2 -Text displayed on the second display line.\r
+        * @param mainText3 -Text displayed on the second "page" first display line.\r
+        * @param mainText4 -Text displayed on the second "page" second display line.\r
+        * @param graphic -Image struct determining whether static or dynamic image to display in app.\r
+        * @param softButtons -App defined SoftButtons.\r
+        * @param customPresets -App labeled on-screen presets.\r
+        * @param alignment -Specifies how mainText1 and mainText2s texts should be aligned on display.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void show(String mainText1, String mainText2, String mainText3, String mainText4,\r
+                       Image graphic, Vector<SoftButton> softButtons, Vector <String> customPresets,\r
+                       TextAlignment alignment, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               show(mainText1, mainText2, mainText3, mainText4, null, null, null, graphic, softButtons, customPresets, alignment, correlationID);\r
+       }               \r
+       /*End V1 Enhanced helper*/\r
+       \r
+       /**\r
+        * Sends a Show RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param mainText1 -Text displayed in a single or upper display line.\r
+        * @param mainText2 -Text displayed on the second display line.\r
+        * @param statusBar\r
+        * @param mediaClock -Text value for MediaClock field.\r
+        * @param mediaTrack -Text displayed in the track field.\r
+        * @param alignment -Specifies how mainText1 and mainText2s texts should be aligned on display.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void show(String mainText1, String mainText2,\r
+                       String statusBar, String mediaClock, String mediaTrack,\r
+                       TextAlignment alignment, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               Show msg = RPCRequestFactory.buildShow(mainText1, mainText2,\r
+                               statusBar, mediaClock, mediaTrack,\r
+                               alignment, correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends a Show RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param mainText1 -Text displayed in a single or upper display line.\r
+        * @param mainText2 -Text displayed on the second display line.\r
+        * @param alignment -Specifies how mainText1 and mainText2s texts should be aligned on display.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void show(String mainText1, String mainText2,\r
+                       TextAlignment alignment, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               show(mainText1, mainText2, null, null, null, alignment, correlationID);\r
+       }\r
+       \r
+       /**\r
+        * Sends a Speak RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param ttsText -The text to speech message in the form of a string.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void speak(String ttsText, Integer correlationID) \r
+                       throws SmartDeviceLinkException {\r
+               \r
+               Speak msg = RPCRequestFactory.buildSpeak(TTSChunkFactory.createSimpleTTSChunks(ttsText),\r
+                               correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends a Speak RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param ttsChunks -Text/phonemes to speak in the form of ttsChunks.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void speak(Vector<TTSChunk> ttsChunks,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+\r
+               Speak msg = RPCRequestFactory.buildSpeak(ttsChunks, correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends a SubscribeButton RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param buttonName -Name of the button to subscribe.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void subscribeButton(ButtonName buttonName,\r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+\r
+               SubscribeButton msg = RPCRequestFactory.buildSubscribeButton(buttonName,\r
+                               correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       // Protected unregisterAppInterface used to ensure no non-ALM app calls\r
+       // unregisterAppInterface.\r
+       protected void unregisterAppInterfacePrivate(Integer correlationID) \r
+               throws SmartDeviceLinkException {\r
+\r
+               UnregisterAppInterface msg = \r
+                               RPCRequestFactory.buildUnregisterAppInterface(correlationID);\r
+               \r
+               sendRPCRequestPrivate(msg);\r
+       }\r
+       \r
+       /**\r
+        * Sends an UnsubscribeButton RPCRequest to SMARTDEVICELINK. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param buttonName -Name of the button to unsubscribe.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+        */\r
+       public void unsubscribeButton(ButtonName buttonName, \r
+                       Integer correlationID) throws SmartDeviceLinkException {\r
+\r
+               UnsubscribeButton msg = RPCRequestFactory.buildUnsubscribeButton(\r
+                               buttonName, correlationID);\r
+\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        * Creates a choice to be added to a choiceset. Choice has both a voice and a visual menu component.\r
+        * \r
+        * @param choiceID -Unique ID used to identify this choice (returned in callback).\r
+        * @param choiceMenuName -Text name displayed for this choice.\r
+        * @param choiceVrCommands -Vector of vrCommands used to select this choice by voice. Must contain\r
+        *                      at least one non-empty element.\r
+        * @return Choice created. \r
+        * @throws SmartDeviceLinkException \r
+        */\r
+       public Choice createChoiceSetChoice(Integer choiceID, String choiceMenuName,\r
+                       Vector<String> choiceVrCommands) {              \r
+               Choice returnChoice = new Choice();\r
+               \r
+               returnChoice.setChoiceID(choiceID);\r
+               returnChoice.setMenuName(choiceMenuName);\r
+               returnChoice.setVrCommands(choiceVrCommands);\r
+               \r
+               return returnChoice;\r
+       }\r
+       \r
+       /**\r
+        * Starts audio pass thru session. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param initialPrompt -SMARTDEVICELINK will speak this prompt before opening the audio pass thru session.\r
+        * @param audioPassThruDisplayText1 -First line of text displayed during audio capture.\r
+        * @param audioPassThruDisplayText2 -Second line of text displayed during audio capture.\r
+        * @param samplingRate -Allowable values of 8 khz or 16 or 22 or 44 khz.\r
+        * @param maxDuration -The maximum duration of audio recording in milliseconds.\r
+        * @param bitsPerSample -Specifies the quality the audio is recorded. Currently 8 bit or 16 bit.\r
+        * @param audioType -Specifies the type of audio data being requested.\r
+        * @param muteAudio -Defines if the current audio source should be muted during the APT session.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException \r
+        */\r
+       public void performaudiopassthru(String initialPrompt, String audioPassThruDisplayText1, String audioPassThruDisplayText2,\r
+                         SamplingRate samplingRate, Integer maxDuration, BitsPerSample bitsPerSample,\r
+                         AudioType audioType, Boolean muteAudio, Integer correlationID) throws SmartDeviceLinkException {              \r
+\r
+               PerformAudioPassThru msg = RPCRequestFactory.BuildPerformAudioPassThru(initialPrompt, audioPassThruDisplayText1, audioPassThruDisplayText2, \r
+                                                                                                                                                               samplingRate, maxDuration, bitsPerSample, audioType, muteAudio, correlationID);\r
+               sendRPCRequest(msg);\r
+       }\r
+\r
+       /**\r
+        * Ends audio pass thru session. Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param correlationID\r
+        * @throws SmartDeviceLinkException \r
+        */\r
+       public void endaudiopassthru(Integer correlationID) throws SmartDeviceLinkException \r
+       {\r
+               EndAudioPassThru msg = RPCRequestFactory.BuildEndAudioPassThru(correlationID);          \r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        *     Subscribes for specific published data items.  The data will be only sent if it has changed.\r
+        *     Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param gps -Subscribes to GPS data.\r
+        * @param speed -Subscribes to vehicle speed data in kilometers per hour.\r
+        * @param rpm -Subscribes to number of revolutions per minute of the engine.\r
+        * @param fuelLevel -Subscribes to fuel level in the tank (percentage).\r
+        * @param fuelLevel_State -Subscribes to fuel level state.\r
+        * @param instantFuelConsumption -Subscribes to instantaneous fuel consumption in microlitres.\r
+        * @param externalTemperature -Subscribes to the external temperature in degrees celsius.\r
+        * @param prndl -Subscribes to PRNDL data that houses the selected gear.\r
+        * @param tirePressure -Subscribes to the TireStatus data containing status and pressure of tires. \r
+        * @param odometer -Subscribes to Odometer data in km.\r
+        * @param beltStatus -Subscribes to status of the seat belts.\r
+        * @param bodyInformation -Subscribes to body information including power modes.\r
+        * @param deviceStatus -Subscribes to device status including signal and battery strength.\r
+        * @param driverBraking -Subscribes to the status of the brake pedal.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+       */\r
+       public void subscribevehicledata(boolean gps, boolean speed, boolean rpm, boolean fuelLevel, boolean fuelLevel_State,\r
+                                                                        boolean instantFuelConsumption, boolean externalTemperature, boolean prndl, boolean tirePressure,                                              \r
+                                                                        boolean odometer, boolean beltStatus, boolean bodyInformation, boolean deviceStatus,\r
+                                                                        boolean driverBraking, Integer correlationID) throws SmartDeviceLinkException\r
+       {\r
+               SubscribeVehicleData msg = RPCRequestFactory.BuildSubscribeVehicleData(gps, speed, rpm, fuelLevel, fuelLevel_State, instantFuelConsumption, externalTemperature, prndl, tirePressure, \r
+                                                                                                                                                               odometer, beltStatus, bodyInformation, deviceStatus, driverBraking, correlationID);\r
+               \r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        *     Unsubscribes for specific published data items.\r
+        *     Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param gps -Unsubscribes to GPS data.\r
+        * @param speed -Unsubscribes to vehicle speed data in kilometers per hour.\r
+        * @param rpm -Unsubscribes to number of revolutions per minute of the engine.\r
+        * @param fuelLevel -Unsubscribes to fuel level in the tank (percentage).\r
+        * @param fuelLevel_State -Unsubscribes to fuel level state.\r
+        * @param instantFuelConsumption -Unsubscribes to instantaneous fuel consumption in microlitres.\r
+        * @param externalTemperature -Unsubscribes to the external temperature in degrees celsius.\r
+        * @param prndl -Unsubscribes to PRNDL data that houses the selected gear.\r
+        * @param tirePressure -Unsubscribes to the TireStatus data containing status and pressure of tires. \r
+        * @param odometer -Unsubscribes to Odometer data in km.\r
+        * @param beltStatus -Unsubscribes to status of the seat belts.\r
+        * @param bodyInformation -Unsubscribes to body information including power modes.\r
+        * @param deviceStatus -Unsubscribes to device status including signal and battery strength.\r
+        * @param driverBraking -Unsubscribes to the status of the brake pedal.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+       */\r
+\r
+       public void unsubscribevehicledata(boolean gps, boolean speed, boolean rpm, boolean fuelLevel, boolean fuelLevel_State,\r
+                                                                          boolean instantFuelConsumption, boolean externalTemperature, boolean prndl, boolean tirePressure,\r
+                                                                          boolean odometer, boolean beltStatus, boolean bodyInformation, boolean deviceStatus,\r
+                                                                          boolean driverBraking, Integer correlationID) throws SmartDeviceLinkException\r
+       {\r
+               UnsubscribeVehicleData msg = RPCRequestFactory.BuildUnsubscribeVehicleData(gps, speed, rpm, fuelLevel, fuelLevel_State, instantFuelConsumption, externalTemperature, prndl, tirePressure,\r
+                                                                                                                                                                       odometer, beltStatus, bodyInformation, deviceStatus, driverBraking, correlationID);\r
+               sendRPCRequest(msg);\r
+       }\r
+\r
+\r
+       /**\r
+        *     Performs a Non periodic vehicle data read request.\r
+        *     Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param gps -Performs an ad-hoc request for GPS data.\r
+        * @param speed -Performs an ad-hoc request for vehicle speed data in kilometers per hour.\r
+        * @param rpm -Performs an ad-hoc request for number of revolutions per minute of the engine.\r
+        * @param fuelLevel -Performs an ad-hoc request for fuel level in the tank (percentage).\r
+        * @param fuelLevel_State -Performs an ad-hoc request for fuel level state.\r
+        * @param instantFuelConsumption -Performs an ad-hoc request for instantaneous fuel consumption in microlitres.\r
+        * @param externalTemperature -Performs an ad-hoc request for the external temperature in degrees celsius.\r
+        * @param vin -Performs an ad-hoc request for the Vehicle identification number\r
+        * @param prndl -Performs an ad-hoc request for PRNDL data that houses the selected gear.\r
+        * @param tirePressure -Performs an ad-hoc request for the TireStatus data containing status and pressure of tires. \r
+        * @param odometer -Performs an ad-hoc request for Odometer data in km.\r
+        * @param beltStatus -Performs an ad-hoc request for status of the seat belts.\r
+        * @param bodyInformation -Performs an ad-hoc request for  body information including power modes.\r
+        * @param deviceStatus -Performs an ad-hoc request for device status including signal and battery strength.\r
+        * @param driverBraking -Performs an ad-hoc request for the status of the brake pedal.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+       */\r
+       public void getvehicledata(boolean gps, boolean speed, boolean rpm, boolean fuelLevel, boolean fuelLevel_State,\r
+                                                          boolean instantFuelConsumption, boolean externalTemperature, boolean vin, boolean prndl, boolean tirePressure,\r
+                                                          boolean odometer, boolean beltStatus, boolean bodyInformation, boolean deviceStatus,\r
+                                                          boolean driverBraking, Integer correlationID) throws SmartDeviceLinkException\r
+       {\r
+       \r
+               GetVehicleData msg = RPCRequestFactory.BuildGetVehicleData(gps, speed, rpm, fuelLevel, fuelLevel_State, instantFuelConsumption, externalTemperature, vin, prndl, tirePressure, odometer,\r
+                                                                                                                                  beltStatus, bodyInformation, deviceStatus, driverBraking, correlationID);\r
+               sendRPCRequest(msg);\r
+       }\r
+\r
+\r
+       /**\r
+        *     Non periodic vehicle data read request\r
+        *     Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param ecuName -Name of ECU.\r
+        * @param didLocation -Raw data from vehicle data DID location(s)\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+       */\r
+\r
+       public void readdid(Integer ecuName, Vector<Integer> didLocation, Integer correlationID) throws SmartDeviceLinkException\r
+       {\r
+               ReadDID msg = RPCRequestFactory.BuildReadDID(ecuName, didLocation, correlationID);              \r
+               sendRPCRequest(msg);            \r
+       }\r
+\r
+\r
+       /**\r
+        *     Vehicle module diagnostic trouble code request.\r
+        *     Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param ecuName -Name of ECU.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+       */      \r
+       public void getdtcs(Integer ecuName, Integer correlationID) throws SmartDeviceLinkException\r
+       {\r
+               GetDTCs msg = RPCRequestFactory.BuildGetDTCs(ecuName, correlationID);           \r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        *     Creates a full screen overlay containing a large block of formatted text that can be scrolled with up to 8 SoftButtons defined.\r
+        *     Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param scrollableMessageBody -Body of text that can include newlines and tabs.\r
+        * @param timeout -App defined timeout.  Indicates how long of a timeout from the last action.\r
+        * @param softButtons -App defined SoftButtons.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+       */              \r
+       public void scrollablemessage(String scrollableMessageBody, Integer timeout, Vector<SoftButton> softButtons, Integer correlationID) throws SmartDeviceLinkException\r
+       {\r
+               ScrollableMessage msg = RPCRequestFactory.BuildScrollableMessage(scrollableMessageBody, timeout, softButtons, correlationID);           \r
+               sendRPCRequest(msg);\r
+       }\r
+\r
+\r
+       /**\r
+        *     Creates a full screen or pop-up overlay (depending on platform) with a single user controlled slider.\r
+        *     Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param numTicks -Number of selectable items on a horizontal axis.\r
+        * @param position -Initial position of slider control (cannot exceed numTicks).\r
+        * @param sliderHeader -Text header to display.\r
+        * @param sliderFooter - Text footer to display (meant to display min/max threshold descriptors).\r
+        * @param timeout -App defined timeout.  Indicates how long of a timeout from the last action.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+       */      \r
+       public void slider(Integer numTicks, Integer position, String sliderHeader, Vector<String> sliderFooter, Integer timeout, Integer correlationID) throws SmartDeviceLinkException\r
+       {\r
+               Slider msg = RPCRequestFactory.BuildSlider(numTicks, position, sliderHeader, sliderFooter, timeout, correlationID);             \r
+               sendRPCRequest(msg);            \r
+       }\r
+\r
+       \r
+       /**     \r
+        *     Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param navigationText1\r
+        * @param navigationText2\r
+        * @param eta\r
+        * @param totalDistance\r
+        * @param turnIcon\r
+        * @param distanceToManeuver\r
+        * @param distanceToManeuverScale\r
+        * @param maneuverComplete\r
+        * @param softButtons\r
+        * @param correlationID\r
+        * @throws SmartDeviceLinkException\r
+       */              \r
+       public void showconstanttbt(String navigationText1, String navigationText2, String eta, String totalDistance, Image turnIcon, Double distanceToManeuver,\r
+                                                               Double distanceToManeuverScale, boolean maneuverComplete, Vector <SoftButton> softButtons, Integer correlationID) throws SmartDeviceLinkException\r
+       {\r
+               ShowConstantTBT msg = RPCRequestFactory.BuildShowConstantTBT(navigationText1, navigationText2, eta, totalDistance, turnIcon, distanceToManeuver, \r
+                                                                                                                                                                       distanceToManeuverScale, maneuverComplete, softButtons, correlationID);\r
+               sendRPCRequest(msg);\r
+       }\r
+\r
+\r
+       /**\r
+        *     Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param ttsText\r
+        * @param softButtons\r
+        * @param correlationID\r
+        * @throws SmartDeviceLinkException\r
+       */\r
+       public void alertmaneuver(String ttsText, Vector<SoftButton> softButtons, Integer correlationID) throws SmartDeviceLinkException\r
+       {\r
+               AlertManeuver msg = RPCRequestFactory.BuildAlertManeuver(ttsText, softButtons, correlationID);\r
+               sendRPCRequest(msg);\r
+       }       \r
+       \r
+\r
+       /**\r
+        *     Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param turnList\r
+        * @param softButtons\r
+        * @param correlationID\r
+        * @throws SmartDeviceLinkException\r
+       */\r
+       public void updateturnlist(Vector<Turn> turnList, Vector<SoftButton> softButtons, Integer correlationID) throws SmartDeviceLinkException\r
+       {\r
+               UpdateTurnList msg = RPCRequestFactory.BuildUpdateTurnList(turnList, softButtons, correlationID);               \r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        *     Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param language\r
+        * @param hmiDisplayLanguage\r
+        * @param correlationID\r
+        * @throws SmartDeviceLinkException\r
+       */      \r
+       public void changeregistration(Language language, Language hmiDisplayLanguage, Integer correlationID) throws SmartDeviceLinkException\r
+       {\r
+               ChangeRegistration msg = RPCRequestFactory.BuildChangeRegistration(language, hmiDisplayLanguage, correlationID);\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+\r
+       /**\r
+        *     Used to push a binary data onto the SMARTDEVICELINK module from a mobile device, such as icons and album art.  Not supported on first generation SMARTDEVICELINK vehicles.\r
+        *     Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param smartDeviceLinkFileName -File reference name.\r
+        * @param fileType -Selected file type.\r
+        * @param persistentFile -Indicates if the file is meant to persist between sessions / ignition cycles.\r
+        * @param fileData\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+       */      \r
+       public void putfile(String smartDeviceLinkFileName, FileType fileType, Boolean persistentFile, byte[] fileData, Integer correlationID) throws SmartDeviceLinkException \r
+       {\r
+               PutFile msg = RPCRequestFactory.buildPutFile(smartDeviceLinkFileName, fileType, persistentFile, fileData, correlationID);\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        *     Used to delete a file resident on the SMARTDEVICELINK module in the app's local cache.  Not supported on first generation SMARTDEVICELINK vehicles.\r
+        *     Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param smartDeviceLinkFileName -File reference name.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+       */      \r
+       public void deletefile(String smartDeviceLinkFileName, Integer correlationID) throws SmartDeviceLinkException \r
+       {\r
+               DeleteFile msg = RPCRequestFactory.buildDeleteFile(smartDeviceLinkFileName, correlationID);\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        *     Requests the current list of resident filenames for the registered app.  Not supported on first generation SMARTDEVICELINK vehicles.\r
+        *     Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+       */      \r
+       public void listfiles(Integer correlationID) throws SmartDeviceLinkException\r
+       {\r
+               ListFiles msg = RPCRequestFactory.buildListFiles(correlationID);\r
+               sendRPCRequest(msg);\r
+       }\r
+\r
+       /**\r
+        *     Used to set existing local file on SMARTDEVICELINK as the app's icon.  Not supported on first generation SMARTDEVICELINK vehicles.\r
+        *     Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param smartDeviceLinkFileName -File reference name.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+       */      \r
+       public void setappicon(String smartDeviceLinkFileName, Integer correlationID) throws SmartDeviceLinkException \r
+       {\r
+               SetAppIcon msg = RPCRequestFactory.buildSetAppIcon(smartDeviceLinkFileName, correlationID);\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /**\r
+        *     Set an alternate display layout. If not sent, default screen for given platform will be shown.\r
+        *     Responses are captured through callback on IProxyListener.\r
+        * \r
+        * @param displayLayout -Predefined or dynamically created screen layout.\r
+        * @param correlationID -A unique ID that correlates each RPCRequest and RPCResponse.\r
+        * @throws SmartDeviceLinkException\r
+       */      \r
+       public void setdisplaylayout(String displayLayout, Integer correlationID) throws SmartDeviceLinkException\r
+       {\r
+               SetDisplayLayout msg = RPCRequestFactory.BuildSetDisplayLayout(displayLayout, correlationID);\r
+               sendRPCRequest(msg);\r
+       }\r
+       \r
+       /******************** END Public Helper Methods *************************/\r
+       \r
+       /**\r
+        * Gets type of transport currently used by this SmartDeviceLinkProxy.\r
+        * \r
+        * @return One of TransportType enumeration values.\r
+        * \r
+        * @see TransportType\r
+        */\r
+       public TransportType getCurrentTransportType() throws IllegalStateException {\r
+               if (_smartDeviceLinkConnection  == null) {\r
+                       throw new IllegalStateException("Incorrect state of SmartDeviceLinkProxyBase: Calling for getCurrentTransportType() while connection is not initialized");\r
+               }\r
+                       \r
+               return _smartDeviceLinkConnection.getCurrentTransportType();\r
+       }\r
+       \r
+} // end-class
\ No newline at end of file
index 55bd304..1239663 100755 (executable)
@@ -1,37 +1,34 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy;
-
-import android.telephony.TelephonyManager;
-
-public class SmartDeviceLinkProxyConfigurationResources {
-       private String _SmartDeviceLinkConfigurationFilePath;
-       private TelephonyManager _telephonyManager;
-       
-       public SmartDeviceLinkProxyConfigurationResources() {
-               this(null, null);
-       }
-       
-       public SmartDeviceLinkProxyConfigurationResources(String SmartDeviceLinkConfigurationFilePath, 
-                       TelephonyManager telephonyManager) {
-               _SmartDeviceLinkConfigurationFilePath = SmartDeviceLinkConfigurationFilePath;
-               _telephonyManager = telephonyManager;
-       }
-       
-       public void setSmartDeviceLinkConfigurationFilePath(String SmartDeviceLinkConfigurationFilePath) {
-               _SmartDeviceLinkConfigurationFilePath = SmartDeviceLinkConfigurationFilePath;
-       }
-       
-       public String getSmartDeviceLinkConfigurationFilePath() {
-               return _SmartDeviceLinkConfigurationFilePath;
-       }
-       
-       public void setTelephonyManager(TelephonyManager telephonyManager) {
-               _telephonyManager = telephonyManager;
-       }
-       
-       public TelephonyManager getTelephonyManager() {
-               return _telephonyManager;
-       }
-}
+package com.smartdevicelink.proxy;\r
+\r
+import android.telephony.TelephonyManager;\r
+\r
+public class SmartDeviceLinkProxyConfigurationResources {\r
+       private String _smartDeviceLinkConfigurationFilePath;\r
+       private TelephonyManager _telephonyManager;\r
+       \r
+       public SmartDeviceLinkProxyConfigurationResources() {\r
+               this(null, null);\r
+       }\r
+       \r
+       public SmartDeviceLinkProxyConfigurationResources(String smartDeviceLinkConfigurationFilePath, \r
+                       TelephonyManager telephonyManager) {\r
+               _smartDeviceLinkConfigurationFilePath = smartDeviceLinkConfigurationFilePath;\r
+               _telephonyManager = telephonyManager;\r
+       }\r
+       \r
+       public void setSmartDeviceLinkConfigurationFilePath(String smartDeviceLinkConfigurationFilePath) {\r
+               _smartDeviceLinkConfigurationFilePath = smartDeviceLinkConfigurationFilePath;\r
+       }\r
+       \r
+       public String getSmartDeviceLinkConfigurationFilePath() {\r
+               return _smartDeviceLinkConfigurationFilePath;\r
+       }\r
+       \r
+       public void setTelephonyManager(TelephonyManager telephonyManager) {\r
+               _telephonyManager = telephonyManager;\r
+       }\r
+       \r
+       public TelephonyManager getTelephonyManager() {\r
+               return _telephonyManager;\r
+       }\r
+}\r
index 51f407e..10b7eaf 100755 (executable)
@@ -1,19 +1,17 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy;
-
-import com.smartdevicelink.exception.SmartDeviceLinkException;
-
-public class SmartDeviceLinkProxyFactory {
-       
-       public static SmartDeviceLinkProxy buildSmartDeviceLinkProxy(IProxyListener listener) {
-               SmartDeviceLinkProxy ret = null;
-               try {
-                       ret = new SmartDeviceLinkProxy(listener);
-               } catch (SmartDeviceLinkException e) {
-                       e.printStackTrace();
-               }
-               return ret;
-       }
-}
+package com.smartdevicelink.proxy;\r
+\r
+import com.smartdevicelink.exception.SmartDeviceLinkException;\r
+@Deprecated\r
+public class SmartDeviceLinkProxyFactory {\r
+       \r
+       @Deprecated\r
+       public static SmartDeviceLinkProxy buildSmartDeviceLinkProxy(IProxyListener listener) {\r
+               SmartDeviceLinkProxy ret = null;\r
+               try {\r
+                       ret = new SmartDeviceLinkProxy(listener);\r
+               } catch (SmartDeviceLinkException e) {\r
+                       e.printStackTrace();\r
+               }\r
+               return ret;\r
+       }\r
+}
\ No newline at end of file
index b16cd0b..b8b8472 100755 (executable)
@@ -1,42 +1,39 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy;
-
-import java.util.Vector;
-
-import com.smartdevicelink.proxy.rpc.TTSChunk;
-import com.smartdevicelink.proxy.rpc.enums.SpeechCapabilities;
-
-public class TTSChunkFactory {
-
-       public static TTSChunk createChunk(SpeechCapabilities type, String text) {
-               TTSChunk ret = new TTSChunk();
-               ret.setType(type);
-               ret.setText(text);
-               return ret;
-       }
-
-       public static Vector<TTSChunk> createSimpleTTSChunks(String simple) {
-               if (simple == null) {
-                       return null;
-               }
-               
-               Vector<TTSChunk> chunks = new Vector<TTSChunk>();
-               
-               TTSChunk chunk = createChunk(SpeechCapabilities.TEXT, simple);
-               chunks.add(chunk);
-               return chunks;
-       }
-
-       public static Vector<TTSChunk> createPrerecordedTTSChunks(String prerecorded) {
-               if (prerecorded == null) {
-                       return null;
-               }
-               
-               Vector<TTSChunk> chunks = new Vector<TTSChunk>();
-               TTSChunk chunk = createChunk(SpeechCapabilities.PRE_RECORDED, prerecorded);
-               chunks.add(chunk);
-               return chunks;
-       }
-}
+package com.smartdevicelink.proxy;\r
+\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.rpc.TTSChunk;\r
+import com.smartdevicelink.proxy.rpc.enums.SpeechCapabilities;\r
+\r
+public class TTSChunkFactory {\r
+\r
+       public static TTSChunk createChunk(SpeechCapabilities type, String text) {\r
+               TTSChunk ret = new TTSChunk();\r
+               ret.setType(type);\r
+               ret.setText(text);\r
+               return ret;\r
+       }\r
+\r
+       public static Vector<TTSChunk> createSimpleTTSChunks(String simple) {\r
+               if (simple == null) {\r
+                       return null;\r
+               }\r
+               \r
+               Vector<TTSChunk> chunks = new Vector<TTSChunk>();\r
+               \r
+               TTSChunk chunk = createChunk(SpeechCapabilities.TEXT, simple);\r
+               chunks.add(chunk);\r
+               return chunks;\r
+       }\r
+\r
+       public static Vector<TTSChunk> createPrerecordedTTSChunks(String prerecorded) {\r
+               if (prerecorded == null) {\r
+                       return null;\r
+               }\r
+               \r
+               Vector<TTSChunk> chunks = new Vector<TTSChunk>();\r
+               TTSChunk chunk = createChunk(SpeechCapabilities.PRE_RECORDED, prerecorded);\r
+               chunks.add(chunk);\r
+               return chunks;\r
+       }\r
+}\r
index b1712bd..214792f 100755 (executable)
@@ -1,8 +1,5 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy;
-
-public class Version {
-       public static final String VERSION = "MAJOR.MINOR.YYMMDD.#_FOR_DAY";
-}
+package com.smartdevicelink.proxy;\r
+\r
+public class Version {\r
+       public static final String VERSION = "VERSION-INFO";\r
+}\r
index 3d35a50..f0638de 100755 (executable)
@@ -1,16 +1,14 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.callbacks;
-
-public class InternalProxyMessage {
-       private String _functionName;
-       
-       public InternalProxyMessage(String functionName) {
-               this._functionName = functionName;
-       }
-       
-       public String getFunctionName() {
-               return _functionName;
-       }
-}
+package com.smartdevicelink.proxy.callbacks;\r
+\r
+public class InternalProxyMessage {\r
+       private String _functionName;\r
+       \r
+       public InternalProxyMessage(String functionName) {\r
+               //this(functionName, null, null);\r
+               this._functionName = functionName;\r
+       }\r
+       \r
+       public String getFunctionName() {\r
+               return _functionName;\r
+       }\r
+}
\ No newline at end of file
index fff5fef..38696e2 100755 (executable)
@@ -1,30 +1,27 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.callbacks;
-
-import com.smartdevicelink.proxy.constants.Names;
-
-public class OnError extends InternalProxyMessage {
-
-       private String _info;
-       private Exception _e;
-       
-       public OnError() {
-               super(Names.OnProxyError);
-       }
-
-       public OnError(String info, Exception e) {
-               super(Names.OnProxyError);
-               this._info = info;
-               this._e = e;
-       }
-       
-       public String getInfo() {
-               return _info;
-       }
-       
-       public Exception getException() {
-               return _e;
-       }
-}
+package com.smartdevicelink.proxy.callbacks;\r
+\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+public class OnError extends InternalProxyMessage {\r
+\r
+       private String _info;\r
+       private Exception _e;\r
+       \r
+       public OnError() {\r
+               super(Names.OnProxyError);\r
+       }\r
+\r
+       public OnError(String info, Exception e) {\r
+               super(Names.OnProxyError);\r
+               this._info = info;\r
+               this._e = e;\r
+       }\r
+       \r
+       public String getInfo() {\r
+               return _info;\r
+       }\r
+       \r
+       public Exception getException() {\r
+               return _e;\r
+       }\r
+}
\ No newline at end of file
index a5ea6d7..323b74a 100755 (executable)
@@ -1,30 +1,27 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.callbacks;
-
-import com.smartdevicelink.proxy.constants.Names;
-
-public class OnProxyClosed extends InternalProxyMessage {
-       
-       private String _info;
-       private Exception _e;
-       
-       public OnProxyClosed() {
-               super(Names.OnProxyClosed);
-       }
-       
-       public OnProxyClosed(String info, Exception e) {
-               super(Names.OnProxyClosed);
-               this._info = info;
-               this._e = e;
-       }
-
-       public String getInfo() {
-               return _info;
-       }
-       
-       public Exception getException() {
-               return _e;
-       }
-}
+package com.smartdevicelink.proxy.callbacks;\r
+\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+public class OnProxyClosed extends InternalProxyMessage {\r
+       \r
+       private String _info;\r
+       private Exception _e;\r
+       \r
+       public OnProxyClosed() {\r
+               super(Names.OnProxyClosed);\r
+       }\r
+       \r
+       public OnProxyClosed(String info, Exception e) {\r
+               super(Names.OnProxyClosed);\r
+               this._info = info;\r
+               this._e = e;\r
+       }\r
+\r
+       public String getInfo() {\r
+               return _info;\r
+       }\r
+       \r
+       public Exception getException() {\r
+               return _e;\r
+       }\r
+}
\ No newline at end of file
index e69f0d1..6d21316 100755 (executable)
@@ -1,13 +1,10 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.callbacks;
-
-import com.smartdevicelink.proxy.constants.Names;
-
-public class OnProxyOpened extends InternalProxyMessage {
-
-       public OnProxyOpened() {
-               super(Names.OnProxyOpened);
-       }
-}
+package com.smartdevicelink.proxy.callbacks;\r
+\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+public class OnProxyOpened extends InternalProxyMessage {\r
+\r
+       public OnProxyOpened() {\r
+               super(Names.OnProxyOpened);\r
+       }\r
+}\r
index bc6060c..0ea371b 100755 (executable)
@@ -1,17 +1,14 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.constants;
-
-public class Jingles {
-       public static final String POSITIVE_JINGLE = "POSITIVE_JINGLE";
-
-       public static final String NEGATIVE_JINGLE = "NEGATIVE_JINGLE";
-
-       public static final String INITIAL_JINGLE = "INITIAL_JINGLE";
-
-       public static final String LISTEN_JINGLE = "LISTEN_JINGLE";
-
-       public static final String HELP_JINGLE = "HELP_JINGLE";
-
-}
+package com.smartdevicelink.proxy.constants;\r
+\r
+public class Jingles {\r
+       public static final String POSITIVE_JINGLE = "POSITIVE_JINGLE";\r
+\r
+       public static final String NEGATIVE_JINGLE = "NEGATIVE_JINGLE";\r
+\r
+       public static final String INITIAL_JINGLE = "INITIAL_JINGLE";\r
+\r
+       public static final String LISTEN_JINGLE = "LISTEN_JINGLE";\r
+\r
+       public static final String HELP_JINGLE = "HELP_JINGLE";\r
+\r
+}
\ No newline at end of file
index 586111d..cf594a3 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.constants;
-
-public class Names {
-       public static final String request = "request";
-       public static final String response = "response";
-       public static final String notification = "notification";
-       public static final String function_name = "name";
-       public static final String parameters = "parameters";
-       public static final String bulkData = "bulkData";
-
-       public static final String RegisterAppInterface = "RegisterAppInterface";
-       public static final String UnregisterAppInterface = "UnregisterAppInterface";
-       public static final String Alert = "Alert";
-       public static final String Show = "Show";
-       public static final String Speak = "Speak";
-       public static final String AddCommand = "AddCommand";
-       public static final String DeleteCommand = "DeleteCommand";
-       public static final String AddSubMenu = "AddSubMenu";
-       public static final String DeleteSubMenu = "DeleteSubMenu";
-       public static final String CreateInteractionChoiceSet = "CreateInteractionChoiceSet";
-       public static final String DeleteInteractionChoiceSet = "DeleteInteractionChoiceSet";
-       public static final String PerformInteraction = "PerformInteraction";
-       public static final String DialNumber = "DialNumber";
-       public static final String EncodedSyncPData = "EncodedSyncPData";
-       public static final String SubscribeButton = "SubscribeButton";
-       public static final String UnsubscribeButton = "UnsubscribeButton";
-       public static final String SubscribeVehicleData = "SubscribeVehicleData";
-       public static final String UnsubscribeVehicleData = "UnsubscribeVehicleData";
-       public static final String SetMediaClockTimer = "SetMediaClockTimer";
-       public static final String SetGlobalProperties = "SetGlobalProperties";
-       public static final String GenericResponse = "GenericResponse";
-       public static final String ScrollableMessage = "ScrollableMessage";
-       public static final String GetDID = "GetDID";
-       public static final String GetDTCs = "GetDTCs";
-       public static final String ReadDID = "ReadDID";
-       public static final String OnVehicleData = "OnVehicleData";
-       public static final String GetFile = "GetFile";
-       public static final String PutFile = "PutFile";
-       public static final String DeleteFile = "DeleteFile";
-       public static final String ListFiles = "ListFiles";
-       public static final String EndAudioCapture = "EndAudioCapture";
-       public static final String GetVehicleData = "GetVehicleData";
-       public static final String ResetGlobalProperties = "ResetGlobalProperties";
-       public static final String PerformAudioCapture = "PerformAudioCapture";
-       public static final String SetAppIcon = "SetAppIcon";
-       public static final String ChangeRegistration = "ChangeRegistration";
-       public static final String SetDisplayLayout = "SetDisplayLayout";
-       public static final String OnLanguageChange = "OnLanguageChange";
-       public static final String hmiDisplayLanguage = "hmiDisplayLanguage";
-       public static final String displayLayout = "displayLayout";
-       public static final String ttsName = "ttsName";
-       public static final String hmiDisplayLanguageDesired = "hmiDisplayLanguageDesired";
-       public static final String appType = "appType";
-       public static final String appID = "appID";
-       public static final String vrHelpTitle = "vrHelpTitle";
-       public static final String graphic = "graphic";
-       public static final String customPresets = "customPresets";
-       public static final String softButtonCapabilities = "softButtonCapabilities";
-       public static final String presetBankCapabilities = "presetBankCapabilities";
-       public static final String vehicleType = "vehicleType";
-       public static final String make = "make";
-       public static final String model = "model";
-       public static final String modelYear = "modelYear";
-       public static final String trim = "trim";
-       public static final String allowed = "allowed";
-       public static final String userDisallowed = "userDisallowed";
-       public static final String rpcName = "rpcName";
-       public static final String hmiPermissions = "hmiPermissions";
-       public static final String parameterPermissions = "parameterPermissions";
-       public static final String permissionItem = "permissionItem";
-       public static final String numTicks = "numTicks";
-       public static final String sliderHeader = "sliderHeader";
-       public static final String sliderFooter = "sliderFooter";
-       public static final String PerformAudioPassThru = "PerformAudioPassThru";
-       public static final String PerformAudioPassThruResponse = "PerformAudioPassThruResponse";
-       public static final String EndAudioPassThru = "EndAudioPassThru";
-       public static final String EndAudioPassThruResponse = "EndAudioPassThruResponse";
-       public static final String OnAudioPassThru = "OnAudioPassThru";
-       public static final String ShowConstantTBT = "ShowConstantTBT";
-       public static final String AlertManeuver = "AlertManeuver";
-       public static final String UpdateTurnList = "UpdateTurnList";
-       
-       public static final String OnCommand = "OnCommand";
-       public static final String OnDataPublished = "OnDataPublished";
-       public static final String OnButtonPress = "OnButtonPress";
-       public static final String OnButtonEvent = "OnButtonEvent";
-       public static final String OnHMIStatus = "OnHMIStatus";
-       public static final String OnTBTClientState = "OnTBTClientState";
-       public static final String OnEncodedSyncPData = "OnEncodedSyncPData";
-       public static final String OnDriverDistraction = "OnDriverDistraction";
-       public static final String OnAppInterfaceUnregistered = "OnAppInterfaceUnregistered";
-       public static final String OnProxyClosed = "OnProxyClosed";
-       public static final String OnProxyError = "OnProxyError";
-       public static final String OnProxyOpened = "OnProxyOpened";
-       public static final String OnProxyUnusable = "OnProxyUnusable";
-       public static final String OnHMILevelChange = "OnHMILevelChange";
-       public static final String OnSyncChoiceChosen = "OnSyncChoiceChosen";
-       public static final String OnPermissionsChange = "OnPermissionsChange";
-       public static final String OnScreenPresetsAvailable = "OnScreenPresetsAvailable";
-       public static final String isHighlighted = "isHighlighted";
-       public static final String softButtonID = "softButtonID";
-       public static final String fileType = "fileType";
-       public static final String persistentFile = "persistentFile";
-       public static final String spaceAvailable = "spaceAvailable";
-       public static final String filenames = "filenames";
-       public static final String cmdIcon = "cmdIcon";
-       public static final String Slider = "Slider";
-       public static final String sliderPosition = "sliderPosition";
-       public static final String samplingRate = "samplingRate";
-       public static final String audioType = "audioType";
-       public static final String satRadioESN = "satRadioESN";
-       public static final String encrypted = "encrypted";
-       public static final String dtcList = "dtcList";
-       public static final String tryAgainTime = "tryAgainTime";
-
-       public static final String success = "success";
-       public static final String resultCode = "resultCode";
-       public static final String info = "info";
-       
-       public static final String fordURL = "fordURL";
-       public static final String payload = "payload";
-       public static final String reason = "reason";
-       public static final String state = "state";
-       public static final String cmdID = "cmdID";
-       public static final String menuParams = "menuParams";
-       public static final String parentID = "parentID";
-       public static final String position = "position";
-       public static final String menuName = "menuName";
-       public static final String vrCommands = "vrCommands";
-       public static final String language = "language";
-       public static final String languageDesired = "languageDesired";
-       public static final String triggerSource = "triggerSource";
-       public static final String subscriptionType = "subscriptionType";
-       public static final String data = "data";
-       public static final String correlationID = "correlationID";
-       public static final String syncMsgVersion = "syncMsgVersion";
-       public static final String majorVersion = "majorVersion";
-       public static final String minorVersion = "minorVersion";
-       public static final String appName = "appName";
-       public static final String ngnMediaScreenAppName = "ngnMediaScreenAppName";
-       public static final String isMediaApplication = "isMediaApplication";
-       public static final String vrSynonyms = "vrSynonyms";
-       public static final String usesVehicleData = "usesVehicleData";
-       public static final String text = "text";
-       public static final String type = "type";
-       public static final String ttsChunks = "ttsChunks";
-       public static final String playTone = "playTone";
-       public static final String duration = "duration";
-       public static final String mainField1 = "mainField1";
-       public static final String mainField2 = "mainField2";
-       public static final String mainField3 = "mainField3";
-       public static final String mainField4 = "mainField4";
-       public static final String statusBar = "statusBar";
-       public static final String name = "name";
-       public static final String menuID = "menuID";
-       public static final String longPress = "longPress";
-       public static final String shortPress = "shortPress";
-       public static final String buttonName = "buttonName";
-       public static final String buttonPressMode = "buttonPressMode";
-       public static final String buttonEventMode = "buttonEventMode";
-       public static final String minutes = "minutes";
-       public static final String seconds = "seconds";
-       public static final String startTime = "startTime";
-       public static final String updateMode = "updateMode";
-       public static final String mediaClock = "mediaClock";
-       public static final String initialText = "initialText";
-       public static final String initialPrompt = "initialPrompt";
-       public static final String helpPrompt = "helpPrompt";
-       public static final String timeoutPrompt = "timeoutPrompt";
-       public static final String timeout = "timeout";
-       public static final String choiceSet = "choiceSet";
-       public static final String interactionMode = "interactionMode";
-       public static final String result = "result";
-       public static final String alertText1 = "alertText1";
-       public static final String alertText2 = "alertText2";
-       public static final String alertText3 = "alertText3";
-       public static final String shortPressAvailable = "shortPressAvailable";
-       public static final String longPressAvailable = "longPressAvailable";
-       public static final String upDownAvailable = "upDownAvailable";
-       public static final String width = "width";
-       public static final String height = "height";
-       public static final String characterSet = "characterSet";
-       public static final String displayType = "displayType";
-       public static final String mediaClockFormats = "mediaClockFormats";
-       public static final String textFields = "textFields";
-       public static final String autoActivateID = "autoActivateID";
-       public static final String vehicleDataCapabilities = "vehicleDataCapabilities";
-       public static final String speechCapabilities = "speechCapabilities";
-       public static final String vrCapabilities = "vrCapabilities";
-       public static final String buttonCapabilities = "buttonCapabilities";
-       public static final String displayCapabilities = "displayCapabilities";
-       public static final String hmiZoneCapabilities = "hmiZoneCapabilities";
-       public static final String interactionChoiceSetID = "interactionChoiceSetID";
-       public static final String interactionChoiceSetIDList = "interactionChoiceSetIDList";
-       public static final String audioFileName = "audioFileName";
-       public static final String gpsPositionValid = "gpsPositionValid";
-       public static final String longitudeDegrees = "longitudeDegrees";
-       public static final String latitudeDegrees = "latitudeDegrees";
-       public static final String utcYear = "utcYear";
-       public static final String utcMonth = "utcMonth";
-       public static final String utcDay = "utcDay";
-       public static final String utcHours = "utcHours";
-       public static final String utcMinutes = "utcMinutes";
-       public static final String utcSeconds = "utcSeconds";
-       public static final String compassDirection = "compassDirection";
-       public static final String pdop = "pdop";
-       public static final String vdop = "vdop";
-       public static final String hdop = "hdop";
-       public static final String actual = "actual";
-       public static final String satellites = "satellites";
-       public static final String dimension = "dimension";
-       public static final String altitude = "altitude";
-       public static final String heading = "heading";
-       public static final String speed = "speed";
-       public static final String number = "number";
-       public static final String SmartDeviceLinkFileName = "SmartDeviceLinkFileName";
-       public static final String localFileName = "localFileName";
-       public static final String maxDuration = "maxDuration";
-       public static final String timerMode = "timerMode";
-       public static final String status = "status";
-       public static final String pressure = "pressure";
-       public static final String hours = "hours";
-       public static final String rows = "rows";
-       public static final String pressureTellTale = "pressureTellTale";
-       public static final String leftFront = "leftFront";
-       public static final String rightFront = "rightFront";
-       public static final String leftRear = "leftRear";
-       public static final String rightRear = "rightRear";
-       public static final String innerLeftRear = "innerLeftRear";
-       public static final String innerRightRear = "innerRightRear";
-       public static final String VehicleData = "VehicleData";
-       public static final String alignment = "alignment";
-       public static final String mediaTrack = "mediaTrack";
-       public static final String properties = "properties";
-       public static final String choiceID = "choiceID";
-       public static final String bitsPerSample = "bitsPerSample";
-       public static final String hmiLevel = "hmiLevel";
-       public static final String audioStreamingState = "audioStreamingState";
-       public static final String systemContext = "systemContext";
-       public static final String SmartDeviceLinkChoice = "SmartDeviceLinkChoice";
-       public static final String SmartDeviceLinkCommand = "SmartDeviceLinkCommand";
-       public static final String URL = "URL";
-       public static final String PermissionGroupName = "PermissionGroupName";
-       public static final String PermissionGroupStatus = "PermissionGroupStatus";
-       public static final String PermissionGroupItems = "PermissionGroupItems";
-       public static final String audioPacket = "audioPacket";
-       public static final String audioPassThruDisplayText1 = "audioPassThruDisplayText1";
-       public static final String audioPassThruDisplayText2 = "audioPassThruDisplayText2";
-       public static final String bitRate = "bitRate";
-       public static final String rpm = "rpm";
-       public static final String fuelLevel = "fuelLevel";
-       public static final String avgFuelEconomy = "avgFuelEconomy";
-       public static final String batteryVoltage = "batteryVoltage";
-       public static final String externalTemperature = "externalTemperature";
-       public static final String vin = "vin";
-       public static final String prndl = "prndl";
-       public static final String tirePressure = "tirePressure";
-       public static final String batteryPackVoltage = "batteryPackVoltage";
-       public static final String batteryPackCurrent = "batteryPackCurrent";
-       public static final String batteryPackTemperature = "batteryPackTemperature";
-       public static final String engineTorque = "engineTorque";
-       public static final String odometer = "odometer";
-       public static final String tripOdometer = "tripOdometer";
-       public static final String genericbinary = "genericbinary";
-       public static final String GPSData = "GPSData";
-       public static final String gps = "gps";
-       public static final String dataType = "dataType";
-       public static final String identifier = "identifier";
-       public static final String statusByte = "statusByte";
-       public static final String dataResult = "dataResult";
-       public static final String ecuName = "ecuName";
-       public static final String didLocation = "didLocation";
-       public static final String value = "value";
-       public static final String softButtonName = "softButtonName";
-       public static final String imageSupported = "imageSupported";
-       public static final String systemAction = "systemAction";
-       public static final String image = "image";
-       public static final String imageType = "imageType";
-       public static final String fileData = "fileData";
-       public static final String scrollableMessageBody = "scrollableMessageBody";
-       public static final String softButtons = "softButtons";
-       public static final String customButtonID = "customButtonID";
-       public static final String vrHelp = "vrHelp";
-       public static final String customButtonName = "customButtonName";
-       public static final String navigationText = "navigationText";
-       public static final String turnIcon = "turnIcon";
-       public static final String navigationText1 = "navigationText1";
-       public static final String navigationText2 = "navigationText2";
-       public static final String eta = "eta";
-       public static final String totalDistance = "totalDistance";
-       public static final String distanceToManeuver = "distanceToManeuver";
-       public static final String distanceToManeuverScale = "distanceToManeuverScale";
-       public static final String maneuverComplete = "maneuverComplete";
-       public static final String turnList = "turnList";
-       public static final String Timeout = "Timeout";
-}
+package com.smartdevicelink.proxy.constants;\r
+\r
+import java.lang.reflect.Field;\r
+import java.util.Hashtable;\r
+\r
+public class Names {\r
+       public static final String request = "request";\r
+       public static final String response = "response";\r
+       public static final String notification = "notification";\r
+       public static final String function_name = "name";\r
+       public static final String parameters = "parameters";\r
+       public static final String bulkData = "bulkData";\r
+\r
+       public static final String RegisterAppInterface = "RegisterAppInterface";\r
+       public static final String UnregisterAppInterface = "UnregisterAppInterface";\r
+       public static final String Alert = "Alert";\r
+       public static final String Show = "Show";\r
+       public static final String Speak = "Speak";\r
+       public static final String AddCommand = "AddCommand";\r
+       public static final String DeleteCommand = "DeleteCommand";\r
+       public static final String AddSubMenu = "AddSubMenu";\r
+       public static final String DeleteSubMenu = "DeleteSubMenu";\r
+       public static final String CreateInteractionChoiceSet = "CreateInteractionChoiceSet";\r
+       public static final String DeleteInteractionChoiceSet = "DeleteInteractionChoiceSet";\r
+       public static final String PerformInteraction = "PerformInteraction";\r
+       public static final String DialNumber = "DialNumber";\r
+       public static final String EncodedSyncPData = "EncodedSyncPData";\r
+       public static final String SyncPData = "SyncPData";\r
+       public static final String SubscribeButton = "SubscribeButton";\r
+       public static final String UnsubscribeButton = "UnsubscribeButton";\r
+       public static final String SubscribeVehicleData = "SubscribeVehicleData";\r
+       public static final String UnsubscribeVehicleData = "UnsubscribeVehicleData";\r
+       public static final String SetMediaClockTimer = "SetMediaClockTimer";\r
+       public static final String SetGlobalProperties = "SetGlobalProperties";\r
+       public static final String GenericResponse = "GenericResponse";\r
+       public static final String ScrollableMessage = "ScrollableMessage";\r
+       public static final String GetDID = "GetDID";\r
+       public static final String GetDTCs = "GetDTCs";\r
+       public static final String ReadDID = "ReadDID";\r
+       public static final String OnVehicleData = "OnVehicleData";\r
+       public static final String GetFile = "GetFile";\r
+       public static final String PutFile = "PutFile";\r
+       public static final String DeleteFile = "DeleteFile";\r
+       public static final String ListFiles = "ListFiles";\r
+       public static final String EndAudioCapture = "EndAudioCapture";\r
+       public static final String GetVehicleData = "GetVehicleData";\r
+       public static final String ResetGlobalProperties = "ResetGlobalProperties";\r
+       public static final String PerformAudioCapture = "PerformAudioCapture";\r
+       public static final String SetAppIcon = "SetAppIcon";\r
+       public static final String ChangeRegistration = "ChangeRegistration";\r
+       public static final String SetDisplayLayout = "SetDisplayLayout";\r
+       public static final String OnLanguageChange = "OnLanguageChange";\r
+       public static final String hmiDisplayLanguage = "hmiDisplayLanguage";\r
+       public static final String displayLayout = "displayLayout";\r
+       public static final String ttsName = "ttsName";\r
+       public static final String hmiDisplayLanguageDesired = "hmiDisplayLanguageDesired";\r
+       public static final String appHMIType = "appHMIType";\r
+       public static final String appID = "appID";\r
+       public static final String vrHelpTitle = "vrHelpTitle";\r
+       public static final String graphic = "graphic";\r
+       public static final String customPresets = "customPresets";\r
+       public static final String softButtonCapabilities = "softButtonCapabilities";\r
+       public static final String presetBankCapabilities = "presetBankCapabilities";\r
+       public static final String vehicleType = "vehicleType";\r
+       public static final String make = "make";\r
+       public static final String model = "model";\r
+       public static final String modelYear = "modelYear";\r
+       public static final String trim = "trim";\r
+       public static final String allowed = "allowed";\r
+       public static final String userDisallowed = "userDisallowed";\r
+       public static final String rpcName = "rpcName";\r
+       public static final String hmiPermissions = "hmiPermissions";\r
+       public static final String parameterPermissions = "parameterPermissions";\r
+       public static final String permissionItem = "permissionItem";\r
+       public static final String numTicks = "numTicks";\r
+       public static final String sliderHeader = "sliderHeader";\r
+       public static final String sliderFooter = "sliderFooter";\r
+       public static final String PerformAudioPassThru = "PerformAudioPassThru";\r
+       public static final String PerformAudioPassThruResponse = "PerformAudioPassThruResponse";\r
+       public static final String EndAudioPassThru = "EndAudioPassThru";\r
+       public static final String EndAudioPassThruResponse = "EndAudioPassThruResponse";\r
+       public static final String OnAudioPassThru = "OnAudioPassThru";\r
+       public static final String ShowConstantTBT = "ShowConstantTBT";\r
+       public static final String AlertManeuver = "AlertManeuver";\r
+       public static final String UpdateTurnList = "UpdateTurnList";\r
+       \r
+       public static final String OnCommand = "OnCommand";\r
+       public static final String OnDataPublished = "OnDataPublished";\r
+       public static final String OnButtonPress = "OnButtonPress";\r
+       public static final String OnButtonEvent = "OnButtonEvent";\r
+       public static final String OnHMIStatus = "OnHMIStatus";\r
+       public static final String OnTBTClientState = "OnTBTClientState";\r
+       public static final String OnEncodedSyncPData = "OnEncodedSyncPData";\r
+       public static final String onEncodedSyncPDataResponse = "onEncodedSyncPDataResponse";\r
+       public static final String OnSyncPData = "OnSyncPData";\r
+       public static final String onOnSyncPData = "onOnSyncPData";\r
+       public static final String onSyncPDataResponse = "onSyncPDataResponse";\r
+       public static final String onOnEncodedSyncPData = "onOnEncodedSyncPData";\r
+       public static final String OnDriverDistraction = "OnDriverDistraction";\r
+       public static final String OnAppInterfaceUnregistered = "OnAppInterfaceUnregistered";\r
+       public static final String OnProxyClosed = "OnProxyClosed";\r
+       public static final String OnProxyError = "OnProxyError";\r
+       public static final String OnProxyOpened = "OnProxyOpened";\r
+       public static final String OnProxyUnusable = "OnProxyUnusable";\r
+       public static final String OnHMILevelChange = "OnHMILevelChange";\r
+       public static final String OnSmartDeviceLinkChoiceChosen = "OnSmartDeviceLinkChoiceChosen";\r
+       public static final String OnPermissionsChange = "OnPermissionsChange";\r
+       public static final String OnScreenPresetsAvailable = "OnScreenPresetsAvailable";\r
+       public static final String isHighlighted = "isHighlighted";\r
+       public static final String softButtonID = "softButtonID";\r
+       public static final String fileType = "fileType";\r
+       public static final String persistentFile = "persistentFile";\r
+       public static final String spaceAvailable = "spaceAvailable";\r
+       public static final String filenames = "filenames";\r
+       public static final String cmdIcon = "cmdIcon";\r
+       public static final String Slider = "Slider";\r
+       public static final String sliderPosition = "sliderPosition";\r
+       public static final String samplingRate = "samplingRate";\r
+       public static final String audioType = "audioType";\r
+       public static final String satRadioESN = "satRadioESN";\r
+       public static final String dtc = "dtc";\r
+       public static final String tryAgainTime = "tryAgainTime";\r
+\r
+       public static final String success = "success";\r
+       public static final String resultCode = "resultCode";\r
+       public static final String info = "info";\r
+       \r
+       public static final String fordURL = "fordURL";\r
+       public static final String payload = "payload";\r
+       public static final String reason = "reason";\r
+       public static final String state = "state";\r
+       public static final String cmdID = "cmdID";\r
+       public static final String menuParams = "menuParams";\r
+       public static final String parentID = "parentID";\r
+       public static final String position = "position";\r
+       public static final String menuName = "menuName";\r
+       public static final String vrCommands = "vrCommands";\r
+       public static final String language = "language";\r
+       public static final String languageDesired = "languageDesired";\r
+       public static final String triggerSource = "triggerSource";\r
+       public static final String subscriptionType = "subscriptionType";\r
+       public static final String data = "data";\r
+       public static final String correlationID = "correlationID";\r
+       public static final String smartDeviceLinkMsgVersion = "syncMsgVersion";\r
+       public static final String majorVersion = "majorVersion";\r
+       public static final String minorVersion = "minorVersion";\r
+       public static final String appName = "appName";\r
+       public static final String ngnMediaScreenAppName = "ngnMediaScreenAppName";\r
+       public static final String isMediaApplication = "isMediaApplication";\r
+       public static final String vrSynonyms = "vrSynonyms";\r
+       public static final String usesVehicleData = "usesVehicleData";\r
+       public static final String text = "text";\r
+       public static final String type = "type";\r
+       public static final String ttsChunks = "ttsChunks";\r
+       public static final String playTone = "playTone";\r
+       public static final String duration = "duration";\r
+       public static final String mainField1 = "mainField1";\r
+       public static final String mainField2 = "mainField2";\r
+       public static final String mainField3 = "mainField3";\r
+       public static final String mainField4 = "mainField4";\r
+       public static final String statusBar = "statusBar";\r
+       public static final String name = "name";\r
+       public static final String menuID = "menuID";\r
+       public static final String longPress = "longPress";\r
+       public static final String shortPress = "shortPress";\r
+       public static final String buttonName = "buttonName";\r
+       public static final String buttonPressMode = "buttonPressMode";\r
+       public static final String buttonEventMode = "buttonEventMode";\r
+       public static final String minutes = "minutes";\r
+       public static final String seconds = "seconds";\r
+       public static final String startTime = "startTime";\r
+       public static final String updateMode = "updateMode";\r
+       public static final String mediaClock = "mediaClock";\r
+       public static final String initialText = "initialText";\r
+       public static final String initialPrompt = "initialPrompt";\r
+       public static final String helpPrompt = "helpPrompt";\r
+       public static final String timeoutPrompt = "timeoutPrompt";\r
+       public static final String timeout = "timeout";\r
+       public static final String choiceSet = "choiceSet";\r
+       public static final String interactionMode = "interactionMode";\r
+       public static final String result = "result";\r
+       public static final String alertText1 = "alertText1";\r
+       public static final String alertText2 = "alertText2";\r
+       public static final String alertText3 = "alertText3";\r
+       public static final String shortPressAvailable = "shortPressAvailable";\r
+       public static final String longPressAvailable = "longPressAvailable";\r
+       public static final String upDownAvailable = "upDownAvailable";\r
+       public static final String width = "width";\r
+       public static final String height = "height";\r
+       public static final String characterSet = "characterSet";\r
+       public static final String displayType = "displayType";\r
+       public static final String mediaClockFormats = "mediaClockFormats";\r
+       public static final String textFields = "textFields";\r
+       public static final String autoActivateID = "autoActivateID";\r
+       public static final String vehicleDataCapabilities = "vehicleDataCapabilities";\r
+       public static final String speechCapabilities = "speechCapabilities";\r
+       public static final String vrCapabilities = "vrCapabilities";\r
+       public static final String audioPassThruCapabilities = "audioPassThruCapabilities";\r
+       public static final String buttonCapabilities = "buttonCapabilities";\r
+       public static final String displayCapabilities = "displayCapabilities";\r
+       public static final String hmiZoneCapabilities = "hmiZoneCapabilities";\r
+       public static final String interactionChoiceSetID = "interactionChoiceSetID";\r
+       public static final String interactionChoiceSetIDList = "interactionChoiceSetIDList";\r
+       public static final String audioFileName = "audioFileName";\r
+       public static final String gpsPositionValid = "gpsPositionValid";\r
+       public static final String longitudeDegrees = "longitudeDegrees";\r
+       public static final String latitudeDegrees = "latitudeDegrees";\r
+       public static final String utcYear = "utcYear";\r
+       public static final String utcMonth = "utcMonth";\r
+       public static final String utcDay = "utcDay";\r
+       public static final String utcHours = "utcHours";\r
+       public static final String utcMinutes = "utcMinutes";\r
+       public static final String utcSeconds = "utcSeconds";\r
+       public static final String compassDirection = "compassDirection";\r
+       public static final String pdop = "pdop";\r
+       public static final String vdop = "vdop";\r
+       public static final String hdop = "hdop";\r
+       public static final String actual = "actual";\r
+       public static final String satellites = "satellites";\r
+       public static final String dimension = "dimension";\r
+       public static final String altitude = "altitude";\r
+       public static final String heading = "heading";\r
+       public static final String speed = "speed";\r
+       public static final String number = "number";\r
+       public static final String smartDeviceLinkFileName = "syncFileName";\r
+       public static final String localFileName = "localFileName";\r
+       public static final String maxDuration = "maxDuration";\r
+       public static final String timerMode = "timerMode";\r
+       public static final String status = "status";\r
+       public static final String pressure = "pressure";\r
+       public static final String hours = "hours";\r
+       public static final String rows = "rows";\r
+       public static final String pressureTellTale = "pressureTellTale";\r
+       public static final String leftFront = "leftFront";\r
+       public static final String rightFront = "rightFront";\r
+       public static final String leftRear = "leftRear";\r
+       public static final String rightRear = "rightRear";\r
+       public static final String innerLeftRear = "innerLeftRear";\r
+       public static final String innerRightRear = "innerRightRear";\r
+       public static final String VehicleData = "VehicleData";\r
+       public static final String alignment = "alignment";\r
+       public static final String mediaTrack = "mediaTrack";\r
+       public static final String properties = "properties";\r
+       public static final String choiceID = "choiceID";\r
+       public static final String bitsPerSample = "bitsPerSample";\r
+       public static final String hmiLevel = "hmiLevel";\r
+       public static final String audioStreamingState = "audioStreamingState";\r
+       public static final String systemContext = "systemContext";\r
+       public static final String smartDeviceLinkChoice = "smartDeviceLinkChoice";\r
+       public static final String smartDeviceLinkCommand = "smartDeviceLinkCommand";\r
+       public static final String URL = "URL";\r
+       public static final String Timeout = "Timeout";\r
+       public static final String PermissionGroupName = "PermissionGroupName";\r
+       public static final String PermissionGroupStatus = "PermissionGroupStatus";\r
+       public static final String PermissionGroupItems = "PermissionGroupItems";\r
+       public static final String audioPacket = "audioPacket";\r
+       public static final String audioPassThruDisplayText1 = "audioPassThruDisplayText1";\r
+       public static final String audioPassThruDisplayText2 = "audioPassThruDisplayText2";\r
+       public static final String bitRate = "bitRate";\r
+       public static final String rpm = "rpm";\r
+       public static final String fuelLevel = "fuelLevel";\r
+       public static final String avgFuelEconomy = "avgFuelEconomy";\r
+       public static final String batteryVoltage = "batteryVoltage";\r
+       public static final String externalTemperature = "externalTemperature";\r
+       public static final String vin = "vin";\r
+       public static final String prndl = "prndl";\r
+       public static final String tirePressure = "tirePressure";\r
+       public static final String batteryPackVoltage = "batteryPackVoltage";\r
+       public static final String batteryPackCurrent = "batteryPackCurrent";\r
+       public static final String batteryPackTemperature = "batteryPackTemperature";\r
+       public static final String engineTorque = "engineTorque";\r
+       public static final String odometer = "odometer";\r
+       public static final String tripOdometer = "tripOdometer";\r
+       public static final String genericbinary = "genericbinary";\r
+       public static final String GPSData = "GPSData";\r
+       public static final String gps = "gps";\r
+       public static final String fuelLevel_State = "fuelLevel_State";\r
+       public static final String instantFuelConsumption = "instantFuelConsumption";\r
+       public static final String beltStatus = "beltStatus";\r
+       public static final String bodyInformation = "bodyInformation";\r
+       public static final String deviceStatus = "deviceStatus";\r
+       public static final String driverBraking = "driverBraking";\r
+       public static final String wiperStatus = "wiperStatus";\r
+       public static final String fuelEconomy = "fuelEconomy";\r
+       public static final String engineOilLife = "engineOilLife";\r
+       public static final String headLampStatus = "headLampStatus";\r
+       public static final String brakeTorque = "brakeTorque";\r
+       public static final String turboBoost = "turboBoost";\r
+       public static final String coolantTemp = "coolantTemp";\r
+       public static final String airFuelRatio = "airFuelRatio";\r
+       public static final String coolingHeadTemp = "coolingHeadTemp";\r
+       public static final String oilTemp = "oilTemp";\r
+       public static final String intakeAirTemp = "intakeAirTemp";\r
+       public static final String gearShiftAdvice = "gearShiftAdvice";\r
+       public static final String acceleration = "acceleration";\r
+       public static final String accPedalPosition = "accPedalPosition";\r
+       public static final String clutchPedalPosition = "clutchPedalPosition";\r
+       public static final String reverseGearStatus = "reverseGearStatus";\r
+       public static final String accTorque = "accTorque";\r
+       public static final String evInfo = "evInfo";\r
+       public static final String ambientLightStatus = "ambientLightStatus";\r
+       public static final String dataType = "dataType";\r
+       public static final String identifier = "identifier";\r
+       public static final String statusByte = "statusByte";\r
+       public static final String didResult = "didResult";\r
+       public static final String ecuName = "ecuName";\r
+       public static final String didLocation = "didLocation";\r
+       public static final String value = "value";\r
+       public static final String softButtonName = "softButtonName";\r
+       public static final String imageSupported = "imageSupported";\r
+       public static final String systemAction = "systemAction";\r
+       public static final String image = "image";\r
+       public static final String imageType = "imageType";\r
+       public static final String fileData = "fileData";\r
+       public static final String scrollableMessageBody = "scrollableMessageBody";\r
+       public static final String softButtons = "softButtons";\r
+       public static final String customButtonID = "customButtonID";\r
+       public static final String vrHelp = "vrHelp";\r
+       public static final String customButtonName = "customButtonName";\r
+       public static final String navigationText = "navigationText";\r
+       public static final String turnIcon = "turnIcon";\r
+       public static final String navigationText1 = "navigationText1";\r
+       public static final String navigationText2 = "navigationText2";\r
+       public static final String eta = "eta";\r
+       public static final String totalDistance = "totalDistance";\r
+       public static final String distanceToManeuver = "distanceToManeuver";\r
+       public static final String distanceToManeuverScale = "distanceToManeuverScale";\r
+       public static final String maneuverComplete = "maneuverComplete";\r
+       public static final String turnList = "turnList";\r
+\r
+    public static final String driverBeltDeployed = "driverBeltDeployed";\r
+    public static final String passengerBeltDeployed = "passengerBeltDeployed";\r
+    public static final String passengerBuckleBelted = "passengerBuckleBelted";\r
+    public static final String driverBuckleBelted = "driverBuckleBelted";\r
+    public static final String leftRow2BuckleBelted = "leftRow2BuckleBelted";\r
+    public static final String passengerChildDetected = "passengerChildDetected";\r
+    public static final String rightRow2BuckleBelted = "rightRow2BuckleBelted";\r
+    public static final String middleRow2BuckleBelted = "middleRow2BuckleBelted";\r
+    public static final String middleRow3BuckleBelted = "middleRow3BuckleBelted";\r
+    public static final String leftRow3BuckleBelted = "leftRow3BuckleBelted";\r
+    public static final String rightRow3BuckleBelted = "rightRow3BuckleBelted";\r
+    public static final String rearInflatableBelted = "rearInflatableBelted";\r
+    public static final String leftRearInflatableBelted = "leftRearInflatableBelted";\r
+    public static final String rightRearInflatableBelted = "rightRearInflatableBelted";\r
+    public static final String middleRow1BeltDeployed = "middleRow1BeltDeployed";\r
+    public static final String middleRow1BuckleBelted = "middleRow1BuckleBelted";\r
+\r
+    public static final String graphicSupported = "graphicSupported";\r
+    public static final String muteAudio = "muteAudio";\r
+    public static final String parkBrakeActive = "parkBrakeActive";\r
+    public static final String ignitionStableStatus = "ignitionStableStatus";\r
+    public static final String ignitionStatus = "ignitionStatus";\r
+    \r
+    public static final String voiceRecOn = "voiceRecOn";\r
+    public static final String btIconOn = "btIconOn";\r
+    public static final String callActive = "callActive";\r
+    public static final String phoneRoaming = "phoneRoaming";\r
+    public static final String textMsgAvailable = "textMsgAvailable";\r
+    public static final String battLevelStatus = "battLevelStatus";\r
+    public static final String stereoAudioOutputMuted = "stereoAudioOutputMuted";\r
+    public static final String monoAudioOutputMuted = "monoAudioOutputMuted";\r
+    public static final String signalLevelStatus = "signalLevelStatus";\r
+    public static final String primaryAudioSource = "primaryAudioSource";\r
+    public static final String eCallEventActive = "eCallEventActive";\r
+\r
+    public static final String fuelEconomySinceLastReset = "fuelEconomySinceLastReset";\r
+    public static final String currentTripFuelEconomy = "currentTripFuelEconomy";\r
+    public static final String averageTripFuelEconomy = "averageTripFuelEconomy";\r
+    public static final String currentCycleFuelEconomy = "currentCycleFuelEconomy";\r
+\r
+    public static final String lightSwitchStatus = "lightSwitchStatus";\r
+    public static final String highBeamsOn = "highBeamsOn";\r
+\r
+    public static final String electricFuelConsumption = "electricFuelConsumption";\r
+    public static final String stateOfCharge = "stateOfCharge";\r
+    public static final String fuelMaintenanceMode = "fuelMaintenanceMode";\r
+    public static final String distanceToEmpty = "distanceToEmpty";\r
+    \r
+    public static final String dtcMask = "dtcMask";\r
+    \r
+    public static final String GetVehicleDataExtend = "com.smartdevicelink.proxy.extend.rpc.GetVehicleDataResponseExtend";\r
+    public static final String SubscribeVehicleDataExtend = "com.smartdevicelink.proxy.extend.rpc.SubscribeVehicleDataResponseExtend";\r
+    public static final String UnsubscribeVehicleDataExtend = "com.smartdevicelink.proxy.extend.rpc.UnsubscribeVehicleDataResponseExtend";\r
+    public static final String OnVehicleDataExtend = "com.smartdevicelink.proxy.extend.rpc.OnVehicleDataExtend";\r
+    public static final String VersionExtend = "com.smartdevicelink.proxy.extend.proxy.VersionExtend";\r
+    public static final String ListenerExtend = "com.smartdevicelink.proxy.extend.interfaces.IProxyListenerExtend";\r
+    \r
+    public static final Hashtable<String, Object> getNamesList()\r
+    {\r
+               Hashtable <String, Object> returnHash = new Hashtable<String, Object>();\r
+       for (Field field : Names.class.getDeclaredFields())\r
+               {\r
+                       String sName = field.getName();\r
+                       try {\r
+                               Object oValue = field.get(sName);\r
+                               returnHash.put(sName, oValue);\r
+                               \r
+                       } catch (IllegalArgumentException e) {\r
+                               // TODO Auto-generated catch block\r
+                               e.printStackTrace();\r
+                       } catch (IllegalAccessException e) {\r
+                               // TODO Auto-generated catch block\r
+                               e.printStackTrace();\r
+                       }                       \r
+               }\r
+       return returnHash;\r
+    }\r
+}\r
index 64177ad..7ba574f 100755 (executable)
@@ -1,8 +1,48 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.interfaces;
-
-public interface IProxyListenerALM extends IProxyListenerBase {
-
-}
+package com.smartdevicelink.proxy.interfaces;\r
+\r
+public interface IProxyListenerALM extends IProxyListenerBase {\r
+       // Adds Advanced Life-cycle Management call-backs to the IProxyListenerAbstract interface\r
+       \r
+       /**\r
+        * **MOVED TO IProxyListenerBase** - onOnHMIStatus() being called indicates that the proxy has entered a state in which the \r
+        * application may create SMARTDEVICELINK related resources (addCommands, ChoiceSets). \r
+        */\r
+       //public void onOnHMIStatus(OnHMIStatus notification);\r
+       \r
+       /**\r
+        * **MOVED TO IProxyListenerBase** - onProxyClosed() being called indicates that the app is no longer registered with SMARTDEVICELINK\r
+        * All resources on SMARTDEVICELINK (addCommands and ChoiceSets) have been deleted and will have to be\r
+        * recreated upon the next onReadyForInitialization() call-back. \r
+        */\r
+       //public void onProxyClosed(String info, Exception e);\r
+       \r
+       /**\r
+        * **MOVED TO IProxyListenerBase** - onError() being called indicates that the proxy has experienced an unrecoverable error.\r
+        * A new proxy object must be initiated to reestablish connection with SMARTDEVICELINK.\r
+        * \r
+        * @param info - Any info present about the error that occurred.\r
+        * @param e - Any exception thrown by the error.\r
+        */\r
+       //public void onError(String info, Exception e);\r
+       \r
+       /**\r
+        * **Deprecated** - onSmartDeviceLinkInterfaceAvailable() being called indicates that the proxy now has access to SMARTDEVICELINK's HMI. \r
+        * Monitor the onFocusChange call-back to determine which level of HMI is available to the proxy.\r
+        * \r
+        * @param isFirstAvailability - Indicates this is the first onSmartDeviceLinkInterfaceAvailable in this lifecycle.\r
+        */\r
+       // HMI (Background, Limited, Full) from Unavailable  = onSmartDeviceLinkInterfaceAvailable(Boolean isFirstAvailability);\r
+\r
+       /**\r
+        * **Deprecated** - onSmartDeviceLinkInterfaceUnavailable() being called indicates that the proxy does NOT have access to SMARTDEVICELINK's HIM.\r
+        */\r
+       // HMI None onSmartDeviceLinkInterfaceUnavailable();\r
+       \r
+       /**\r
+        * **Deprecated** - ALM HMI states converted back to HMI Levels\r
+        * \r
+        * HMI Full = onSmartDeviceLinkInFocus(Boolean isFirstSmartDeviceLinkInFocus);\r
+        * HMI Limited = onSmartDeviceLinkInFocusLimited();\r
+        * HMI Background = onSmartDeviceLinkLostFocus();\r
+        */\r
+}\r
index c4b5078..2be639c 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.interfaces;
-
-import com.smartdevicelink.proxy.rpc.AddCommandResponse;
-import com.smartdevicelink.proxy.rpc.AddSubMenuResponse;
-import com.smartdevicelink.proxy.rpc.AlertResponse;
-import com.smartdevicelink.proxy.rpc.CreateInteractionChoiceSetResponse;
-import com.smartdevicelink.proxy.rpc.DeleteCommandResponse;
-import com.smartdevicelink.proxy.rpc.DeleteInteractionChoiceSetResponse;
-import com.smartdevicelink.proxy.rpc.DeleteSubMenuResponse;
-import com.smartdevicelink.proxy.rpc.EncodedSyncPDataResponse;
-import com.smartdevicelink.proxy.rpc.GenericResponse;
-import com.smartdevicelink.proxy.rpc.OnButtonEvent;
-import com.smartdevicelink.proxy.rpc.OnButtonPress;
-import com.smartdevicelink.proxy.rpc.OnCommand;
-import com.smartdevicelink.proxy.rpc.OnDriverDistraction;
-import com.smartdevicelink.proxy.rpc.OnEncodedSyncPData;
-import com.smartdevicelink.proxy.rpc.OnHMIStatus;
-import com.smartdevicelink.proxy.rpc.OnPermissionsChange;
-import com.smartdevicelink.proxy.rpc.OnTBTClientState;
-import com.smartdevicelink.proxy.rpc.PerformInteractionResponse;
-import com.smartdevicelink.proxy.rpc.ResetGlobalPropertiesResponse;
-import com.smartdevicelink.proxy.rpc.SetGlobalPropertiesResponse;
-import com.smartdevicelink.proxy.rpc.SetMediaClockTimerResponse;
-import com.smartdevicelink.proxy.rpc.ShowResponse;
-import com.smartdevicelink.proxy.rpc.SpeakResponse;
-import com.smartdevicelink.proxy.rpc.SubscribeButtonResponse;
-import com.smartdevicelink.proxy.rpc.UnsubscribeButtonResponse;
-
-
-public interface IProxyListenerBase {
-
-       /**
-        * onOnHMIStatus being called indicates that there has been an HMI Level change,
-        * system context change or audio streaming state change.
-        * 
-        * @param notification - Contains information about the HMI Level,
-        * system context and audio streaming state.
-        */
-       public void onOnHMIStatus(OnHMIStatus notification);
-
-       /**
-        * onProxyClosed has different functionality for the different models.
-        * In the non-ALM model this indicates that the proxy has experienced an unrecoverable error.
-        * A new proxy object must be initiated to reestablish connection with SmartDeviceLink.
-        * In the ALM model this indicates that the app is no longer registered with SmartDeviceLink
-        * All resources on SmartDeviceLink (addCommands and ChoiceSets) have been deleted and will have to be
-        * recreated upon the next onReadyForInitialization() call-back. 
-        * 
-        * @param info - Includes information about the reason the proxy has been closed.
-        * @param e - The exception that occurred. 
-        */
-       public void onProxyClosed(String info, Exception e);
-       
-       /**
-        * onProxyError() being called indicates that the SmartDeviceLink Proxy experenced an error.
-        * 
-        * @param info - Includes information about the Exception that occurred.
-        * @param e - The exception that occurred. 
-        */
-       public void onError(String info, Exception e);
-       
-       
-       /**
-        * onGenericResponse() being called indicates that SmartDeviceLink could not determine the
-        * type of request it is responding to. This is usually result of an unknown RPC Request
-        * being sent.
-        * 
-        * @param response - Includes detailed information about the response.
-        */
-       public void onGenericResponse(GenericResponse response);
-       
-       /**
-        * onOnCommand() being called indicates that the user selected a command on SmartDeviceLink.
-        * 
-        * @param notification - Contains information about the command chosen.
+package com.smartdevicelink.proxy.interfaces;\r
+\r
+import com.smartdevicelink.proxy.rpc.AddCommandResponse;\r
+import com.smartdevicelink.proxy.rpc.AddSubMenuResponse;\r
+import com.smartdevicelink.proxy.rpc.AlertManeuverResponse;\r
+import com.smartdevicelink.proxy.rpc.AlertResponse;\r
+import com.smartdevicelink.proxy.rpc.ChangeRegistrationResponse;\r
+import com.smartdevicelink.proxy.rpc.CreateInteractionChoiceSetResponse;\r
+import com.smartdevicelink.proxy.rpc.DeleteCommandResponse;\r
+import com.smartdevicelink.proxy.rpc.DeleteFileResponse;\r
+import com.smartdevicelink.proxy.rpc.DeleteInteractionChoiceSetResponse;\r
+import com.smartdevicelink.proxy.rpc.DeleteSubMenuResponse;\r
+import com.smartdevicelink.proxy.rpc.DialNumberResponse;\r
+import com.smartdevicelink.proxy.rpc.EndAudioPassThruResponse;\r
+import com.smartdevicelink.proxy.rpc.GenericResponse;\r
+import com.smartdevicelink.proxy.rpc.GetDTCsResponse;\r
+import com.smartdevicelink.proxy.rpc.GetVehicleDataResponse;\r
+import com.smartdevicelink.proxy.rpc.ListFilesResponse;\r
+import com.smartdevicelink.proxy.rpc.OnAudioPassThru;\r
+import com.smartdevicelink.proxy.rpc.OnButtonEvent;\r
+import com.smartdevicelink.proxy.rpc.OnButtonPress;\r
+import com.smartdevicelink.proxy.rpc.OnCommand;\r
+import com.smartdevicelink.proxy.rpc.OnDriverDistraction;\r
+import com.smartdevicelink.proxy.rpc.OnHMIStatus;\r
+import com.smartdevicelink.proxy.rpc.OnLanguageChange;\r
+import com.smartdevicelink.proxy.rpc.OnPermissionsChange;\r
+import com.smartdevicelink.proxy.rpc.OnTBTClientState;\r
+import com.smartdevicelink.proxy.rpc.OnVehicleData;\r
+import com.smartdevicelink.proxy.rpc.PerformAudioPassThruResponse;\r
+import com.smartdevicelink.proxy.rpc.PerformInteractionResponse;\r
+import com.smartdevicelink.proxy.rpc.PutFileResponse;\r
+import com.smartdevicelink.proxy.rpc.ReadDIDResponse;\r
+import com.smartdevicelink.proxy.rpc.ResetGlobalPropertiesResponse;\r
+import com.smartdevicelink.proxy.rpc.ScrollableMessageResponse;\r
+import com.smartdevicelink.proxy.rpc.SetAppIconResponse;\r
+import com.smartdevicelink.proxy.rpc.SetDisplayLayoutResponse;\r
+import com.smartdevicelink.proxy.rpc.SetGlobalPropertiesResponse;\r
+import com.smartdevicelink.proxy.rpc.SetMediaClockTimerResponse;\r
+import com.smartdevicelink.proxy.rpc.ShowConstantTBTResponse;\r
+import com.smartdevicelink.proxy.rpc.ShowResponse;\r
+import com.smartdevicelink.proxy.rpc.SliderResponse;\r
+import com.smartdevicelink.proxy.rpc.SpeakResponse;\r
+import com.smartdevicelink.proxy.rpc.SubscribeButtonResponse;\r
+import com.smartdevicelink.proxy.rpc.SubscribeVehicleDataResponse;\r
+import com.smartdevicelink.proxy.rpc.UnsubscribeButtonResponse;\r
+import com.smartdevicelink.proxy.rpc.UnsubscribeVehicleDataResponse;\r
+import com.smartdevicelink.proxy.rpc.UpdateTurnListResponse;\r
+\r
+\r
+public interface IProxyListenerBase  {\r
+\r
+       /**\r
+        * onOnHMIStatus being called indicates that there has been an HMI Level change,\r
+        * system context change or audio streaming state change.\r
+        * \r
+        * @param notification - Contains information about the HMI Level,\r
+        * system context and audio streaming state.\r
+        */\r
+       public void onOnHMIStatus(OnHMIStatus notification);\r
+\r
+       /**\r
+        * onProxyClosed has different functionality for the different models.\r
+        * In the non-ALM model this indicates that the proxy has experienced an unrecoverable error.\r
+        * A new proxy object must be initiated to reestablish connection with SMARTDEVICELINK.\r
+        * In the ALM model this indicates that the app is no longer registered with SMARTDEVICELINK\r
+        * All resources on SMARTDEVICELINK (addCommands and ChoiceSets) have been deleted and will have to be\r
+        * recreated upon the next onReadyForInitialization() call-back. \r
+        * \r
+        * @param info - Includes information about the reason the proxy has been closed.\r
+        * @param e - The exception that occurred. \r
+        */\r
+       public void onProxyClosed(String info, Exception e);\r
+       \r
+       /**\r
+        * onProxyError() being called indicates that the SMARTDEVICELINK Proxy experenced an error.\r
+        * \r
+        * @param info - Includes information about the Exception that occurred.\r
+        * @param e - The exception that occurred. \r
+        */\r
+       public void onError(String info, Exception e);\r
+       \r
+       \r
+       /**\r
+        * onGenericResponse() being called indicates that SMARTDEVICELINK could not determine the\r
+        * type of request it is responding to. This is usually result of an unknown RPC Request\r
+        * being sent.\r
+        * \r
+        * @param response - Includes detailed information about the response.\r
+        */\r
+       public void onGenericResponse(GenericResponse response);\r
+       \r
+       /**\r
+        * onOnCommand() being called indicates that the user selected a command on SMARTDEVICELINK.\r
+        * \r
+        * @param notification - Contains information about the command chosen.\r
+        */\r
+       public void onOnCommand(OnCommand notification);\r
+       \r
+       /**\r
+        * onAddCommandResponse() being called indicates that SMARTDEVICELINK has responded to\r
+        * a request to add a command.\r
+        * \r
+        * @param response - Contains information about the response sent from SMARTDEVICELINK.\r
+        */\r
+       public void onAddCommandResponse(AddCommandResponse response);\r
+       \r
+       /**\r
+        * onAddSubMenuResponse() being called indicates that SMARTDEVICELINK has responded to\r
+        * a request to add a command.\r
+        * \r
+        * @param response - Contains information about the response sent from SMARTDEVICELINK.\r
+        */\r
+       public void onAddSubMenuResponse(AddSubMenuResponse response);\r
+       \r
+       /**\r
+        * onCreateInteractionChoiceSetResponse() being called indicates that SMARTDEVICELINK has\r
+        * responded to a request to add an interactionChoiceSet.\r
+        * \r
+        * @param response - Contains information about the response sent from SMARTDEVICELINK.\r
+        */\r
+       public void onCreateInteractionChoiceSetResponse(CreateInteractionChoiceSetResponse response);\r
+       \r
+       /**\r
+        * onAlertResponse being called indicates that SMARTDEVICELINK has\r
+        * responded to a request to alert the user. \r
+        * \r
+        * @param response - Contains information about the response sent from SMARTDEVICELINK.\r
+        */\r
+       public void onAlertResponse(AlertResponse response);\r
+       \r
+       /**\r
+        * onDeleteCommandResponse being called indicates that SMARTDEVICELINK has\r
+        * responded to a request to delete a command. \r
+        * \r
+        * @param response - Contains information about the response sent from SMARTDEVICELINK.\r
+        */\r
+       public void onDeleteCommandResponse(DeleteCommandResponse response);\r
+       \r
+       /**\r
+        * onDeleteCommandResponse being called indicates that SMARTDEVICELINK has\r
+        * responded to a request to delete an interaction choice set. \r
+        * \r
+        * @param response - Contains information about the response sent from SMARTDEVICELINK.\r
+        */\r
+       public void onDeleteInteractionChoiceSetResponse(DeleteInteractionChoiceSetResponse response);\r
+       \r
+       /**\r
+        * onDeleteCommandResponse being called indicates that SMARTDEVICELINK has\r
+        * responded to a request to delete a submenu. \r
+        * \r
+        * @param response - Contains information about the response sent from SMARTDEVICELINK.\r
+        */\r
+       public void onDeleteSubMenuResponse(DeleteSubMenuResponse response);\r
+       \r
+       /**\r
+        * onPerformInteractionResponse being called indicates that SMARTDEVICELINK has\r
+        * responded to a request to perform an interaction. \r
+        * \r
+        * @param response - Contains information about the response sent from SMARTDEVICELINK.\r
+        */\r
+       public void onPerformInteractionResponse(PerformInteractionResponse response);\r
+       \r
+       /**\r
+        * onResetGlobalPropertiesResponse being called indicates that SMARTDEVICELINK has\r
+        * responded to a request to reset global properties. \r
+        * \r
+        * @param response - Contains information about the response sent from SMARTDEVICELINK.\r
+        */\r
+       public void onResetGlobalPropertiesResponse(ResetGlobalPropertiesResponse response);\r
+       \r
+       /**\r
+        * onSetGlobalPropertiesResponse being called indicates that SMARTDEVICELINK has\r
+        * responded to a request to set global properties. \r
+        * \r
+        * @param response - Contains information about the response sent from SMARTDEVICELINK.\r
+        */\r
+       public void onSetGlobalPropertiesResponse(SetGlobalPropertiesResponse response);\r
+       \r
+       /**\r
+        * onSetMediaClockTimerResponse being called indicates that SMARTDEVICELINK has\r
+        * responded to a request to set the media clock timer. \r
+        * \r
+        * @param response - Contains information about the response sent from SMARTDEVICELINK.\r
+        */\r
+       public void onSetMediaClockTimerResponse(SetMediaClockTimerResponse response);\r
+       \r
+       /**\r
+        * onShowResponse being called indicates that SMARTDEVICELINK has\r
+        * responded to a request to display information to the user. \r
+        * \r
+        * @param response - Contains information about the response sent from SMARTDEVICELINK.\r
+        */\r
+       public void onShowResponse(ShowResponse response);\r
+       \r
+       /**\r
+        * onSpeakResponse being called indicates that SMARTDEVICELINK has\r
+        * responded to a request to speak information to the user. \r
+        * \r
+        * @param response - Contains information about the response sent from SMARTDEVICELINK.\r
+        */\r
+       public void onSpeakResponse(SpeakResponse response);\r
+       \r
+       /**\r
+        * onButtonEvent being called indicates that a button event has occurred. \r
+        * \r
+        * @param notification - Contains information about the notification sent from SMARTDEVICELINK.\r
+        */\r
+       public void onOnButtonEvent(OnButtonEvent notification);\r
+\r
+       /**\r
+        * onButtonPress being called indicates that SMARTDEVICELINK has a button has \r
+        * been pressed by the user. \r
+        * \r
+        * @param notification - Contains information about the notification sent from SMARTDEVICELINK.\r
+        */\r
+       public void onOnButtonPress(OnButtonPress notification);\r
+       \r
+       /**\r
+        * onSubscribeButtonResponse being called indicates that SMARTDEVICELINK has\r
+        * responded to a request to subscribe to button events and button presses. \r
+        * \r
+        * @param response - Contains information about the response sent from SMARTDEVICELINK.\r
+        */\r
+       public void onSubscribeButtonResponse(SubscribeButtonResponse response);\r
+       \r
+       /**\r
+        * onUnsubscribeButtonResponse being called indicates that SMARTDEVICELINK has\r
+        * responded to a request to unsubscribe from button events and button presses. \r
+        * \r
+        * @param response - Contains information about the response sent from SMARTDEVICELINK.\r
+        */\r
+       public void onUnsubscribeButtonResponse(UnsubscribeButtonResponse response);\r
+\r
+       /**\r
+        * onOnPermissionsChange being called indicates that your app permissions have \r
+        * changed due to a policy table change. This can mean your app has received additional\r
+        * permissions OR lost permissions.\r
+        * \r
+        * @param notification - Contains information about the changed permissions.\r
         */
-       public void onOnCommand(OnCommand notification);
-       
-       /**
-        * onAddCommandResponse() being called indicates that SmartDeviceLink has responded to
-        * a request to add a command.
-        * 
-        * @param response - Contains information about the response sent from SmartDeviceLink.
-        */
-       public void onAddCommandResponse(AddCommandResponse response);
-       
-       /**
-        * onAddSubMenuResponse() being called indicates that SmartDeviceLink has responded to
-        * a request to add a command.
-        * 
-        * @param response - Contains information about the response sent from SmartDeviceLink.
-        */
-       public void onAddSubMenuResponse(AddSubMenuResponse response);
-       
-       /**
-        * onCreateInteractionChoiceSetResponse() being called indicates that SmartDeviceLink has
-        * responded to a request to add an interactionChoiceSet.
-        * 
-        * @param response - Contains information about the response sent from SmartDeviceLink.
-        */
-       public void onCreateInteractionChoiceSetResponse(CreateInteractionChoiceSetResponse response);
-       
-       /**
-        * onAlertResponse being called indicates that SmartDeviceLink has
-        * responded to a request to alert the user. 
-        * 
-        * @param response - Contains information about the response sent from SmartDeviceLink.
-        */
-       public void onAlertResponse(AlertResponse response);
-       
-       /**
-        * onDeleteCommandResponse being called indicates that SmartDeviceLink has
-        * responded to a request to delete a command. 
-        * 
-        * @param response - Contains information about the response sent from SmartDeviceLink.
-        */
-       public void onDeleteCommandResponse(DeleteCommandResponse response);
-       
-       /**
-        * onDeleteCommandResponse being called indicates that SmartDeviceLink has
-        * responded to a request to delete an interaction choice set. 
-        * 
-        * @param response - Contains information about the response sent from SmartDeviceLink.
-        */
-       public void onDeleteInteractionChoiceSetResponse(DeleteInteractionChoiceSetResponse response);
-       
-       /**
-        * onDeleteCommandResponse being called indicates that SmartDeviceLink has
-        * responded to a request to delete a submenu. 
-        * 
-        * @param response - Contains information about the response sent from SmartDeviceLink.
-        */
-       public void onDeleteSubMenuResponse(DeleteSubMenuResponse response);
-       
-       /**
-        * onEncodedSyncPDataResponse being called indicates that SmartDeviceLink has
-        * responded to a request containing encodedSmartDeviceLinkPData. 
-        * 
-        * @param response - Contains information about the response sent from SmartDeviceLink.
-        */
-       public void onEncodedSyncPDataResponse(EncodedSyncPDataResponse response);
-       
-       /**
-        * onPerformInteractionResponse being called indicates that SmartDeviceLink has
-        * responded to a request to perform an interaction. 
-        * 
-        * @param response - Contains information about the response sent from SmartDeviceLink.
-        */
-       public void onPerformInteractionResponse(PerformInteractionResponse response);
-       
-       /**
-        * onResetGlobalPropertiesResponse being called indicates that SmartDeviceLink has
-        * responded to a request to reset global properties. 
-        * 
-        * @param response - Contains information about the response sent from SmartDeviceLink.
-        */
-       public void onResetGlobalPropertiesResponse(ResetGlobalPropertiesResponse response);
-       
-       /**
-        * onSetGlobalPropertiesResponse being called indicates that SmartDeviceLink has
-        * responded to a request to set global properties. 
-        * 
-        * @param response - Contains information about the response sent from SmartDeviceLink.
-        */
-       public void onSetGlobalPropertiesResponse(SetGlobalPropertiesResponse response);
-       
-       /**
-        * onSetMediaClockTimerResponse being called indicates that SmartDeviceLink has
-        * responded to a request to set the media clock timer. 
-        * 
-        * @param response - Contains information about the response sent from SmartDeviceLink.
-        */
-       public void onSetMediaClockTimerResponse(SetMediaClockTimerResponse response);
-       
-       /**
-        * onShowResponse being called indicates that SmartDeviceLink has
-        * responded to a request to display information to the user. 
-        * 
-        * @param response - Contains information about the response sent from SmartDeviceLink.
-        */
-       public void onShowResponse(ShowResponse response);
-       
-       /**
-        * onSpeakResponse being called indicates that SmartDeviceLink has
-        * responded to a request to speak information to the user. 
-        * 
-        * @param response - Contains information about the response sent from SmartDeviceLink.
-        */
-       public void onSpeakResponse(SpeakResponse response);
-       
-       /**
-        * onButtonEvent being called indicates that a button event has occurred. 
-        * 
-        * @param response - Contains information about the notification sent from SmartDeviceLink.
-        */
-       public void onOnButtonEvent(OnButtonEvent notification);
+       public void onOnPermissionsChange(OnPermissionsChange notification);
+       \r
+       public void onSubscribeVehicleDataResponse(SubscribeVehicleDataResponse response);\r
+       \r
+       public void onUnsubscribeVehicleDataResponse(UnsubscribeVehicleDataResponse response);\r
+       \r
+       public void onGetVehicleDataResponse(GetVehicleDataResponse response);\r
+       \r
+       public void onReadDIDResponse(ReadDIDResponse response);\r
+       \r
+       public void onGetDTCsResponse(GetDTCsResponse response);\r
+       \r
+       public void onOnVehicleData(OnVehicleData notification);
+       \r
+       public void onPerformAudioPassThruResponse(PerformAudioPassThruResponse response);\r
+       \r
+       public void onEndAudioPassThruResponse(EndAudioPassThruResponse response);\r
+       \r
+       public void onOnAudioPassThru(OnAudioPassThru notification);
 
-       /**
-        * onButtonPress being called indicates that SmartDeviceLink has a button has 
-        * been pressed by the user. 
-        * 
-        * @param response - Contains information about the notification sent from SmartDeviceLink.
-        */
-       public void onOnButtonPress(OnButtonPress notification);
+       public void onPutFileResponse(PutFileResponse response);\r
        
-       /**
-        * onSubscribeButtonResponse being called indicates that SmartDeviceLink has
-        * responded to a request to subscribe to button events and button presses. 
-        * 
-        * @param response - Contains information about the response sent from SmartDeviceLink.
-        */
-       public void onSubscribeButtonResponse(SubscribeButtonResponse response);
+       public void onDeleteFileResponse(DeleteFileResponse response);\r
+       \r
+       public void onListFilesResponse(ListFilesResponse response);\r
+\r
+       public void onSetAppIconResponse(SetAppIconResponse response);
+       \r
+       public void onScrollableMessageResponse(ScrollableMessageResponse response);
+\r
+       public void onChangeRegistrationResponse(ChangeRegistrationResponse response);\r
+\r
+       public void onSetDisplayLayoutResponse(SetDisplayLayoutResponse response);\r
+       \r
+       public void onOnLanguageChange(OnLanguageChange notification);\r
        
-       /**
-        * onUnsubscribeButtonResponse being called indicates that SmartDeviceLink has
-        * responded to a request to unsubscribe from button events and button presses. 
-        * 
-        * @param response - Contains information about the response sent from SmartDeviceLink.
-        */
-       public void onUnsubscribeButtonResponse(UnsubscribeButtonResponse response);
-
-       /**
-        * onOnPermissionsChange being called indicates that your app permissions have 
-        * changed due to a policy table change. This can mean your app has received additional
-        * permissions OR lost permissions.
-        * 
-        * @param notification - Contains information about the changed permissions.
-        */
-       public void onOnPermissionsChange(OnPermissionsChange notification);
-
-       public void onOnDriverDistraction(OnDriverDistraction notification);
-       public void onOnEncodedSyncPData(OnEncodedSyncPData notification);
-       public void onOnTBTClientState(OnTBTClientState notification);
-}
+       public void onSliderResponse(SliderResponse response);\r
+\r
+       public void onAlertManeuverResponse(AlertManeuverResponse response);\r
+       \r
+       public void onShowConstantTBTResponse(ShowConstantTBTResponse response);\r
+       \r
+       public void onUpdateTurnListResponse(UpdateTurnListResponse response);\r
+       \r
+       public void onDialNumberResponse(DialNumberResponse response);\r
+       \r
+       public void onOnDriverDistraction(OnDriverDistraction notification);\r
+               \r
+       public void onOnTBTClientState(OnTBTClientState notification);  \r
+               
+}\r
index 9d150fd..70f5445 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-import java.util.Vector;
-
-import com.smartdevicelink.proxy.RPCRequest;
-import com.smartdevicelink.proxy.constants.Names;
-
-public class AddCommand extends RPCRequest {
-
-    public AddCommand() {
-        super("AddCommand");
-    }
-    public AddCommand(Hashtable hash) {
-        super(hash);
-    }
-    public Integer getCmdID() {
-        return (Integer) parameters.get( Names.cmdID );
-    }
-    public void setCmdID( Integer cmdID ) {
-        if (cmdID != null) {
-            parameters.put(Names.cmdID, cmdID );
-        }
-    }
-    public MenuParams getMenuParams() {
-        Object obj = parameters.get(Names.menuParams);
-        if (obj instanceof MenuParams) {
-               return (MenuParams)obj;
-        }
-        else if (obj instanceof Hashtable) {
-               return new MenuParams((Hashtable)obj);
-        }
-        return null;
-    }
-    public void setMenuParams( MenuParams menuParams ) {
-        if (menuParams != null) {
-            parameters.put(Names.menuParams, menuParams );
-        }
-    }
-    public Vector<String> getVrCommands() {
-       if (parameters.get(Names.vrCommands) instanceof Vector<?>) {
-               Vector<?> list = (Vector<?>)parameters.get(Names.vrCommands);
-               if (list != null && list.size() > 0) {
-                       Object obj = list.get(0);
-                       if (obj instanceof String) {
-                               return (Vector<String>)list;
-                       }
-               }
-       }
-       return null;
-    }
-    public void setVrCommands( Vector<String> vrCommands ) {
-        if (vrCommands != null) {
-            parameters.put(Names.vrCommands, vrCommands );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+* <p>\r
+* This class will add a command to the application's Command Menu\r
+* </p>\r
+* <p>\r
+* <b>Note:</b> A command will be added to the end of the list of elements in\r
+* the Command Menu under the following conditions:\r
+* </p>\r
+* <ul>\r
+* <li>When a Command is added with no MenuParams value provided</li>\r
+* <li>When a MenuParams value is provided with a MenuParam.position value\r
+* greater than or equal to the number of menu items currently defined in the\r
+* menu specified by the MenuParam.parentID value</li>\r
+* </ul>\r
+* <br/>\r
+* <p>\r
+* The set of choices which the application builds using AddCommand can be a\r
+* mixture of:\r
+* </p>\r
+* <ul>\r
+* <li>Choices having only VR synonym definitions, but no MenuParams definitions\r
+* </li>\r
+* <li>Choices having only MenuParams definitions, but no VR synonym definitions\r
+* </li>\r
+* <li>Choices having both MenuParams and VR synonym definitions</li>\r
+* </ul>\r
+* <p>\r
+ * <b>HMILevel needs to be FULL, LIMITED or BACKGROUD</b>\r
+* </p>\r
+* \r
+* @since SmartDeviceLink 1.0\r
+* @see DeleteCommand\r
+* @see AddSubMenu\r
+* @see DeleteSubMenu\r
+*/\r
+\r
+public class AddCommand extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new AddCommand object\r
+        */\r
+       public AddCommand() {\r
+        super("AddCommand");\r
+    }\r
+       \r
+       /**\r
+       * <p>\r
+       * Constructs a new AddCommand object indicated by the Hashtable\r
+       * parameter\r
+       * </p>\r
+       * \r
+       * @param hash\r
+       *            The Hashtable to use\r
+       */\r
+    public AddCommand(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+       /**\r
+        * <p>\r
+        * Returns an <i>Integer</i> object representing the Command ID that you want to add\r
+        * </p>\r
+        * \r
+        * @return Integer -an integer representation a Unique Command ID\r
+        */\r
+    public Integer getCmdID() {\r
+        return (Integer) parameters.get(Names.cmdID);\r
+    }\r
+       /**\r
+        * Sets an Unique Command ID that identifies the command. Is returned in an\r
+        * <i>{@linkplain OnCommand}</i> notification to identify the command\r
+        * selected by the user\r
+        * <p>\r
+        * \r
+        * @param cmdID\r
+        *            an integer object representing a Command ID\r
+        *            <p>\r
+        *            <b>Notes:</b> Min Value: 0; Max Value: 2000000000\r
+        */\r
+    public void setCmdID(Integer cmdID) {\r
+        if (cmdID != null) {\r
+            parameters.put(Names.cmdID, cmdID);\r
+        } else {\r
+               parameters.remove(Names.cmdID);\r
+        }\r
+    }\r
+       /**\r
+        * <p>\r
+        * Returns a <I>MenuParams</I> object which will defined the command and how\r
+        * it is added to the Command Menu\r
+        * </p>\r
+        * \r
+        * @return MenuParams -a MenuParams object\r
+        */\r
+    public MenuParams getMenuParams() {\r
+        Object obj = parameters.get(Names.menuParams);\r
+        if (obj instanceof MenuParams) {\r
+               return (MenuParams) obj;\r
+        }\r
+        else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new MenuParams((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.menuParams, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+       /**\r
+        * <p>\r
+        * Sets Menu parameters<br/>\r
+        * If provided, this will define the command and how it is added to the\r
+        * Command Menu<br/>\r
+        * If null, commands will not be accessible through the HMI application menu\r
+        * </p>\r
+        * \r
+        * @param menuParams\r
+        *            a menuParams object\r
+        */    \r
+    public void setMenuParams(MenuParams menuParams) {\r
+        if (menuParams != null) {\r
+            parameters.put(Names.menuParams, menuParams);\r
+        } else {\r
+               parameters.remove(Names.menuParams);\r
+        }\r
+    }\r
+       /**\r
+        * <p>\r
+        * Gets Voice Recognition Commands\r
+        * </p>\r
+        * \r
+        * @return Vector<String> -(Vector<String>) indicating one or more VR phrases\r
+        */    \r
+    public Vector<String> getVrCommands() {\r
+       if (parameters.get(Names.vrCommands) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.vrCommands);\r
+               if (list != null && list.size() > 0) {\r
+                       Object obj = list.get(0);\r
+                       if (obj instanceof String) {\r
+                               return (Vector<String>)list;\r
+                       }\r
+               }\r
+       }\r
+       return null;\r
+    }\r
+       /**\r
+        * <p>\r
+        * Sets Voice Recognition Commands <br/>\r
+        * If provided, defines one or more VR phrases the recognition of any of\r
+        * which triggers the <i>{@linkplain OnCommand}</i> notification with this\r
+        * cmdID<br/>\r
+        * If null, commands will not be accessible by voice commands (when the user\r
+        * hits push-to-talk)\r
+        * </p>\r
+        * \r
+        * @param vrCommands\r
+        *            Vector<String> indicating one or more VR phrases\r
+        *            <p>\r
+        *            <b>Notes: </b>Optional only if menuParams is provided. If\r
+        *            provided, array must contain at least one non-empty (not null,\r
+        *            not zero-length, not whitespace only) element\r
+        */\r
+    public void setVrCommands( Vector<String> vrCommands ) {\r
+        if (vrCommands != null) {\r
+            parameters.put(Names.vrCommands, vrCommands );\r
+        } else {\r
+               parameters.remove(Names.vrCommands);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets the image to be shown along with a command </p>\r
+        * \r
+        * @return Image -an Image object\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public Image getCmdIcon() {\r
+       Object obj = parameters.get(Names.cmdIcon);\r
+        if (obj instanceof Image) {\r
+            return (Image) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new Image((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.cmdIcon, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * Sets the Image<br/>\r
+        * If provided, defines the image to be be shown along with a  command\r
+        * @param cmdIcon\r
+        *            an Image obj representing the Image obj shown along with a\r
+        *            command\r
+        *            <p>\r
+        *            <b>Notes: </b>If omitted on supported displays, no (or the\r
+        *            default if applicable) icon will be displayed\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public void setCmdIcon(Image cmdIcon) {\r
+        if (cmdIcon != null) {\r
+            parameters.put(Names.cmdIcon, cmdIcon);\r
+        } else {\r
+               parameters.remove(Names.cmdIcon);\r
+        }\r
+    }\r
+}\r
index ce3c681..b607ff1 100755 (executable)
@@ -1,19 +1,22 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCResponse;
-
-public class AddCommandResponse extends RPCResponse {
-
-    public AddCommandResponse() {
-        super("AddCommand");
-    }
-    public AddCommandResponse(Hashtable hash) {
-        super(hash);
-    }
-}
-
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Add Command Response is sent, when AddCommand has been called\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class AddCommandResponse extends RPCResponse {\r
+\r
+    public AddCommandResponse() {\r
+        super("AddCommand");\r
+    }\r
+\r
+    public AddCommandResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}\r
+\r
index 67811db..4b437cc 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCRequest;
-import com.smartdevicelink.proxy.constants.Names;
-
-public class AddSubMenu extends RPCRequest {
-
-    public AddSubMenu() {
-        super("AddSubMenu");
-    }
-    public AddSubMenu(Hashtable hash) {
-        super(hash);
-    }
-    public Integer getMenuID() {
-        return (Integer) parameters.get( Names.menuID );
-    }
-    public void setMenuID( Integer menuID ) {
-        if (menuID != null) {
-            parameters.put(Names.menuID, menuID );
-        }
-    }
-    public Integer getPosition() {
-        return (Integer) parameters.get( Names.position );
-    }
-    public void setPosition( Integer position ) {
-        if (position != null) {
-            parameters.put(Names.position, position );
-        }
-    }
-    public String getMenuName() {
-        return (String) parameters.get( Names.menuName );
-    }
-    public void setMenuName( String menuName ) {
-        if (menuName != null) {
-            parameters.put(Names.menuName, menuName );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Add a SubMenu to the Command Menu\r
+ * <p>\r
+ * A SubMenu can only be added to the Top Level Menu (i.e.a SunMenu cannot be\r
+ * added to a SubMenu), and may only contain commands as children\r
+ * <p>\r
+ * <p>\r
+ * <b>HMILevel needs to be FULL, LIMITED or BACKGROUD</b>\r
+ * </p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ * @see DeleteSubMenu\r
+ * @see AddCommand\r
+ * @see DeleteCommand\r
+ */\r
+public class AddSubMenu extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new AddSubMenu object\r
+        */\r
+       public AddSubMenu() {\r
+        super("AddSubMenu");\r
+    }\r
+       /**\r
+        * Constructs a new AddSubMenu object indicated by the Hashtable parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public AddSubMenu(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+       /**\r
+        * Returns an <i>Integer</i> object representing the Menu ID that identifies\r
+        * a sub menu\r
+        * <p>\r
+        * \r
+        * @return Integer -an integer representing the Menu ID that identifies a sub\r
+        *         menu\r
+        */\r
+    public Integer getMenuID() {\r
+        return (Integer) parameters.get( Names.menuID );\r
+    }\r
+       /**\r
+        * Sets a Menu ID that identifies a sub menu. This value is used in\r
+        * {@linkplain AddCommand} to which SubMenu is the parent of the command\r
+        * being added\r
+        * <p>\r
+        * \r
+        * @param menuID\r
+        *            an integer object representing a Menu ID\r
+        *            <p>\r
+        *            <b>Notes:</b> Min Value: 0; Max Value: 2000000000\r
+        */    \r
+    public void setMenuID( Integer menuID ) {\r
+        if (menuID != null) {\r
+            parameters.put(Names.menuID, menuID );\r
+        }\r
+    }\r
+       /**\r
+        * Returns an <i>Integer</i> object representing the position of menu\r
+        * <p>\r
+        * \r
+        * @return Integer -the value representing the relative position of menus\r
+        */    \r
+    public Integer getPosition() {\r
+        return (Integer) parameters.get( Names.position );\r
+    }\r
+       /**\r
+        * Sets a position of menu\r
+        * \r
+        * @param position\r
+        *            An Integer object representing the position within the items\r
+        *            of the top level Command Menu. 0 will insert at the front, 1\r
+        *            will insert after the first existing element, etc. Position of\r
+        *            any submenu will always be located before the return and exit\r
+        *            options\r
+        *            <p>\r
+        *            <b>Notes: </b><br/>\r
+        *            <ul>\r
+        *            <li>\r
+        *            Min Value: 0; Max Value: 1000</li>\r
+        *            <li>If position is greater or equal than the number of items\r
+        *            on top level, the sub menu will be appended by the end</li>\r
+        *            <li>If this parameter is omitted, the entry will be added at\r
+        *            the end of the list</li>\r
+        *            </ul>\r
+        */    \r
+    public void setPosition( Integer position ) {\r
+        if (position != null) {\r
+            parameters.put(Names.position, position );\r
+        }\r
+    }\r
+       /**\r
+        * Returns String which is displayed representing this submenu item\r
+        * \r
+        * @return String -a Submenu item's name\r
+        */\r
+    public String getMenuName() {\r
+        return (String) parameters.get( Names.menuName );\r
+    }\r
+       /**\r
+        * Sets a menuName which is displayed representing this submenu item\r
+        * \r
+        * @param menuName\r
+        *            String which will be displayed representing this submenu item\r
+        */    \r
+    public void setMenuName( String menuName ) {\r
+        if (menuName != null) {\r
+            parameters.put(Names.menuName, menuName );\r
+        }\r
+    }\r
+}\r
index 4698227..ba5ef52 100755 (executable)
@@ -1,18 +1,19 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCResponse;
-
-public class AddSubMenuResponse extends RPCResponse {
-
-    public AddSubMenuResponse() {
-        super("AddSubMenu");
-    }
-    public AddSubMenuResponse(Hashtable hash) {
-        super(hash);
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Add SubMenu Response is sent, when AddSubMenu has been called\r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class AddSubMenuResponse extends RPCResponse {\r
+\r
+    public AddSubMenuResponse() {\r
+        super("AddSubMenu");\r
+    }\r
+    public AddSubMenuResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
index c626bb5..f8737e7 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-import java.util.Vector;
-
-import com.smartdevicelink.proxy.RPCRequest;
-import com.smartdevicelink.proxy.constants.Names;
-
-public class Alert extends RPCRequest {
-
-    public Alert() {
-        super("Alert");
-    }
-    public Alert(Hashtable hash) {
-        super(hash);
-    }
-    public String getAlertText1() {
-        return (String) parameters.get( Names.alertText1 );
-    }
-    public void setAlertText1( String alertText1 ) {
-        if (alertText1 != null) {
-            parameters.put(Names.alertText1, alertText1 );
-        }
-    }
-    public String getAlertText2() {
-        return (String) parameters.get( Names.alertText2 );
-    }
-    public void setAlertText2( String alertText2 ) {
-        if (alertText2 != null) {
-            parameters.put(Names.alertText2, alertText2 );
-        }
-    }
-    public Vector<TTSChunk> getTtsChunks() {
-        if (parameters.get(Names.ttsChunks) instanceof Vector<?>) {
-               Vector<?> list = (Vector<?>)parameters.get(Names.ttsChunks);
-               if (list != null && list.size() > 0) {
-                   Object obj = list.get(0);
-                   if (obj instanceof TTSChunk) {
-                       return (Vector<TTSChunk>) list;
-                   } else if (obj instanceof Hashtable) {
-                       Vector<TTSChunk> newList = new Vector<TTSChunk>();
-                       for (Object hashObj : list) {
-                           newList.add(new TTSChunk((Hashtable)hashObj));
-                       }
-                       return newList;
-                   }
-               }
-        }
-        return null;
-    }
-    public void setTtsChunks( Vector<TTSChunk> ttsChunks ) {
-        if (ttsChunks != null) {
-            parameters.put(Names.ttsChunks, ttsChunks );
-        }
-    }
-    public Integer getDuration() {
-        return (Integer) parameters.get( Names.duration );
-    }
-    public void setDuration( Integer duration ) {
-        if (duration != null) {
-            parameters.put(Names.duration, duration );
-        }
-    }
-    public Boolean getPlayTone() {
-        return (Boolean) parameters.get( Names.playTone );
-    }
-    public void setPlayTone( Boolean playTone ) {
-        if (playTone != null) {
-            parameters.put(Names.playTone, playTone );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Provides information to the user using either TTS, the Display or both and\r
+ * can include a system-generated alert tone\r
+ * <p>\r
+ * <ul>\r
+ * <li>The displayed portion of the Alert, if any, will persist until the\r
+ * specified timeout has elapsed, or the Alert is preempted</li>\r
+ * <li>An Alert will preempt (abort) any SmartDeviceLink Operation that is in-progress,\r
+ * except an already-in-progress Alert</li>\r
+ * <li>An Alert cannot be preempted by any SmartDeviceLink Operation</li>\r
+ * <li>An Alert can be preempted by a user action (button push)</li>\r
+ * <li>An Alert will fail if it is issued while another Alert is in progress</li>\r
+ * <li>Although each Alert parameter is optional, in fact each Alert request\r
+ * must supply at least one of the following parameters:<br/>\r
+ * <ul>\r
+ * <li>alertText1</li>\r
+ * <li>alertText2</li>\r
+ * <li>alertText3</li>\r
+ * <li>ttsChunks</li>\r
+ * </ul>\r
+ * </li>\r
+ * </ul>\r
+ * <br/>\r
+ * <b>HMILevel needs to be FULL or LIMITED.</b><br/>\r
+ * <b>If the app has been granted function group Notification the HMILevel can\r
+ * also be BACKGROUND</b><br/>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ * @see Show\r
+ * @see Speak\r
+ */\r
+public class Alert extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new Alert object\r
+        */    \r
+       public Alert() {\r
+        super("Alert");\r
+    }\r
+       /**\r
+        * Constructs a new Alert object indicated by the Hashtable parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */     \r
+    public Alert(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+       /**\r
+        * Gets the text which is displayed in the first field of the display during\r
+        * the Alert\r
+        * \r
+        * @return String - a String value representing the text which is displayed\r
+        *         in the first field during the Alert\r
+        */    \r
+    public String getAlertText1() {\r
+        return (String) parameters.get(Names.alertText1);\r
+    }\r
+       /**\r
+        * Sets the String to be displayed in the first field of the display during\r
+        * the Alert\r
+        * \r
+        * @param alertText1\r
+        *            String Value\r
+        *            <p>\r
+        *            <b>Notes: </b><br/>\r
+        *            <ul>\r
+        *            <li>Length is limited to what is indicated in <i>\r
+        *            {@linkplain RegisterAppInterface}</i> response</li>\r
+        *            <li>If omitted, top display line will be cleared</li>\r
+        *            <li>Text is always centered</li>\r
+        *            </ul>\r
+        */    \r
+    public void setAlertText1(String alertText1) {\r
+        if (alertText1 != null) {\r
+            parameters.put(Names.alertText1, alertText1);\r
+        } else {\r
+               parameters.remove(Names.alertText1);\r
+        }\r
+    }\r
+       /**\r
+        * Gets the text which is displayed in the second field of the display\r
+        * during the Alert\r
+        * \r
+        * @return String -a String value representing the text which is displayed\r
+        *         in the second field during the Alert\r
+        */    \r
+    public String getAlertText2() {\r
+        return (String) parameters.get(Names.alertText2);\r
+    }\r
+       /**\r
+        * Sets the String to be displayed in the second field of the display during\r
+        * the Alert\r
+        * \r
+        * @param alertText2\r
+        *            String Value\r
+        *            <p>\r
+        *            <b>Notes: </b><br/>\r
+        *            <ul>\r
+        *            <li>Only permitted if HMI supports a second display line</li>\r
+        *            <li>Length is limited to what is indicated in <i>\r
+        *            {@linkplain RegisterAppInterface}</i> response</li>\r
+        *            <li>If omitted, second display line will be cleared</li>\r
+        *            <li>Text is always centered</li>\r
+        *            </ul>\r
+        */    \r
+    public void setAlertText2(String alertText2) {\r
+        if (alertText2 != null) {\r
+            parameters.put(Names.alertText2, alertText2);\r
+        } else {\r
+               parameters.remove(Names.alertText2);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets the text which is displayed in the third field of the display during\r
+        * the Alert\r
+        * \r
+        * @return String -a String value representing the text which is displayed\r
+        *         in the third field during the Alert\r
+        * \r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public String getAlertText3() {\r
+        return (String) parameters.get(Names.alertText3);\r
+    }\r
+\r
+       /**\r
+        * Sets the String to be displayed in the third field of the display during\r
+        * the Alert\r
+        * \r
+        * @param alertText3\r
+        *            String Value\r
+        *            <p>\r
+        *            <b>Notes: </b><br/>\r
+        *            <ul>\r
+        *            <li>Only permitted if HMI supports a third display line</li>\r
+        *            <li>Length is limited to what is indicated in <i>\r
+        *            {@linkplain RegisterAppInterface}</i> response</li>\r
+        *            <li>If omitted, third display line will be cleared</li>\r
+        *            <li>Text is always centered</li>\r
+        *            </ul>\r
+        * \r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public void setAlertText3(String alertText3) {\r
+        if (alertText3 != null) {\r
+            parameters.put(Names.alertText3, alertText3);\r
+        } else {\r
+               parameters.remove(Names.alertText3);\r
+        }\r
+    }\r
+       /**\r
+        * Gets TTSChunk[], the Array of type TTSChunk which, taken together,\r
+        * specify what is to be spoken to the user\r
+        * \r
+        * @return Vector -a Vector<TTSChunk> value specify what is to be spoken to\r
+        *         the user\r
+        */    \r
+    public Vector<TTSChunk> getTtsChunks() {\r
+        if (parameters.get(Names.ttsChunks) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.ttsChunks);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof TTSChunk) {\r
+                       return (Vector<TTSChunk>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<TTSChunk> newList = new Vector<TTSChunk>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new TTSChunk((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+       /**\r
+        * Sets array of type TTSChunk which, taken together, specify what is to be\r
+        * spoken to the user\r
+        * \r
+        * @param ttsChunks\r
+        *            <p>\r
+        *            <b>Notes: </b>Array must have a least one element\r
+        */    \r
+    public void setTtsChunks(Vector<TTSChunk> ttsChunks) {\r
+        if (ttsChunks != null) {\r
+            parameters.put(Names.ttsChunks, ttsChunks);\r
+        } else {\r
+               parameters.remove(Names.ttsChunks);\r
+        }\r
+    }\r
+       /**\r
+        * Gets the duration of the displayed portion of the alert, in milliseconds\r
+        * \r
+        * @return Integer -an Integer value representing the duration of the\r
+        *         displayed portion of the alert, in milliseconds\r
+        */    \r
+    public Integer getDuration() {\r
+        return (Integer) parameters.get(Names.duration);\r
+    }\r
+       /**\r
+        * Sets the duration of the displayed portion of the alert, in milliseconds.\r
+        * After this amount of time has passed, the display fields alertText1 and\r
+        * alertText2 will revert to what was displayed in those fields before the\r
+        * alert began\r
+        * <p>\r
+        * \r
+        * @param duration\r
+        *            the Integer values representing the duration time, in\r
+        *            milliseconds\r
+        *            <p>\r
+        *            <b>Notes: </b><br/>\r
+        *            <ul>\r
+        *            <li>Min Value: 3000; Max Value: 10000</li>\r
+        *            <li>If omitted, the default is 5000 milliseconds</li>\r
+        *            </ul>\r
+        */    \r
+    public void setDuration(Integer duration) {\r
+        if (duration != null) {\r
+            parameters.put(Names.duration, duration);\r
+        } else {\r
+               parameters.remove(Names.duration);\r
+        }\r
+    }\r
+       /**\r
+        * Gets a Boolean value representing the alert tone\r
+        * \r
+        * @return Boolean -If TRUE, means an alert tone will be played before the\r
+        *         TTS (if any) is spoken\r
+        */    \r
+    public Boolean getPlayTone() {\r
+        return (Boolean) parameters.get(Names.playTone);\r
+    }\r
+       /**\r
+        * Sets whether the alert tone should be played before the TTS (if any) is\r
+        * spoken\r
+        * \r
+        * @param playTone\r
+        *            a Boolean value which specifies whether the alert tone should\r
+        *            be played before the TTS (if any) is spoken\r
+        *            <p>\r
+        *            <b>Notes: </b>If omitted, default is true\r
+        */    \r
+    public void setPlayTone(Boolean playTone) {\r
+        if (playTone != null) {\r
+            parameters.put(Names.playTone, playTone);\r
+        } else {\r
+               parameters.remove(Names.playTone);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets the SoftButton Vector object\r
+        * \r
+        * @return Vector<SoftButton> -a Vector<SoftButton> representing the Vector\r
+        *         object\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public Vector<SoftButton> getSoftButtons() {\r
+        if (parameters.get(Names.softButtons) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.softButtons);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof SoftButton) {\r
+                       return (Vector<SoftButton>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<SoftButton> newList = new Vector<SoftButton>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new SoftButton((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * Sets the SoftButtons\r
+        * \r
+        * @param softButtons\r
+        *            a Vector<SoftButton> value\r
+        *            <p>\r
+        *            <b>Notes: </b><br/>\r
+        *            <ul>\r
+        *            <li>If omitted on supported displays, the alert will not have\r
+        *            any SoftButton</li>\r
+        *            <li>ArrayMin: 0</li>\r
+        *            <li>ArrayMax: 4</li>\r
+        *            </ul>\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public void setSoftButtons(Vector<SoftButton> softButtons) {\r
+        if (softButtons != null) {\r
+            parameters.put(Names.softButtons, softButtons);\r
+        } else {\r
+               parameters.remove(Names.softButtons);\r
+        }\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/AlertManeuver.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/AlertManeuver.java
new file mode 100755 (executable)
index 0000000..a6b9e55
--- /dev/null
@@ -0,0 +1,124 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * This will bring up an alert with information related to the next navigation\r
+ * maneuver including potential voice navigation instructions. Shown information\r
+ * will be taken from the ShowConstantTBT function\r
+ * <p>\r
+ * Function Group: Navigation\r
+ * <p>\r
+ * <b>HMILevel needs to be FULL, LIMITED or BACKGROUND</b>\r
+ * <p>\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ * @see ShowConstantTBT\r
+ */\r
+public class AlertManeuver extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new AlertManeuver object\r
+        */\r
+    public AlertManeuver() {\r
+        super("AlertManeuver");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new AlertManeuver object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public AlertManeuver(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+\r
+       /**\r
+        * Sets an array of text chunks of type TTSChunk\r
+        * \r
+        * @param ttsChunks\r
+        *            a Vector<TTSChunk> value representing an array of text chunks\r
+        *            of type TTSChunk\r
+        *            <p>\r
+        *            <b>Notes: </b>Minsize=1; Maxsize=100\r
+        */\r
+    public void setTtsChunks(Vector<TTSChunk> ttsChunks) {\r
+        if (ttsChunks != null) {\r
+            parameters.put(Names.ttsChunks, ttsChunks);\r
+        } else {\r
+               parameters.remove(Names.ttsChunks);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets an array of text chunks of type TTSChunk\r
+        * \r
+        * @return Vector<TTSChunk> -a Vector<TTSChunk> value representing an array\r
+        *         of text chunks of type TTSChunk\r
+        */\r
+    public Vector<TTSChunk> getTtsChunks() {\r
+        if (parameters.get(Names.ttsChunks) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.ttsChunks);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof TTSChunk) {\r
+                       return (Vector<TTSChunk>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<TTSChunk> newList = new Vector<TTSChunk>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new TTSChunk((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * Sets soft buttons. If omitted on supported displays, only the system\r
+        * defined "Close" SoftButton will be displayed\r
+        * \r
+        * @param softButtons\r
+        *            a Vector<SoftButton> value\r
+        *            <p>\r
+        *            <b>Notes: </b>Minsize=0; Maxsize=3\r
+        */\r
+    public void setSoftButtons(Vector<SoftButton> softButtons) {\r
+        if (softButtons != null) {\r
+            parameters.put(Names.softButtons, softButtons);\r
+        } else {\r
+               parameters.remove(Names.softButtons);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a Vector<SoftButton>\r
+        * @return Vector<SoftButton> -a Vector<SoftButton> value\r
+        */\r
+    public Vector<SoftButton> getSoftButtons() {\r
+        if (parameters.get(Names.softButtons) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.softButtons);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof SoftButton) {\r
+                       return (Vector<SoftButton>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<SoftButton> newList = new Vector<SoftButton>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new SoftButton((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/AlertManeuverResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/AlertManeuverResponse.java
new file mode 100755 (executable)
index 0000000..e710e32
--- /dev/null
@@ -0,0 +1,20 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Alert Maneuver Response is sent, when AlertManeuver has been called\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class AlertManeuverResponse extends RPCResponse {\r
+\r
+    public AlertManeuverResponse() {\r
+        super("AlertManeuver");\r
+    }\r
+    public AlertManeuverResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
index d2a208b..4559dd9 100755 (executable)
@@ -1,18 +1,43 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCResponse;
-
-public class AlertResponse extends RPCResponse {
-
-    public AlertResponse() {
-        super("Alert");
-    }
-    public AlertResponse(Hashtable hash) {
-        super(hash);
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Alert Response is sent, when Alert has been called\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class AlertResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new AlertResponse object\r
+        */\r
+    public AlertResponse() {\r
+        super("Alert");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new AlertResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public AlertResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public Integer getTryAgainTime() {\r
+        return (Integer) parameters.get(Names.tryAgainTime);\r
+    }\r
+    public void setTryAgainTime(Integer tryAgainTime) {\r
+        if (tryAgainTime != null) {\r
+            parameters.put(Names.tryAgainTime, tryAgainTime);\r
+        } else {\r
+               parameters.remove(Names.tryAgainTime);\r
+        }\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/AudioPassThruCapabilities.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/AudioPassThruCapabilities.java
new file mode 100755 (executable)
index 0000000..c820446
--- /dev/null
@@ -0,0 +1,155 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.AudioType;\r
+import com.smartdevicelink.proxy.rpc.enums.BitsPerSample;\r
+import com.smartdevicelink.proxy.rpc.enums.SamplingRate;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Describes different audio type configurations for PerformAudioPassThru, e.g. {8kHz,8-bit,PCM}\r
+ * <p><b>Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>samplingRate</td>\r
+ *                     <td>SamplingRate</td>\r
+ *                     <td>Describes the sampling rate for AudioPassThru\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>bitsPerSample</td>\r
+ *                     <td>BitsPerSample</td>\r
+ *                     <td>Describes the sample depth in bit for AudioPassThru\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>audioType</td>\r
+ *                     <td>AudioType</td>\r
+ *                     <td>Describes the audiotype for AudioPassThru\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *  </table>\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class AudioPassThruCapabilities extends RPCStruct {\r
+       \r
+       /**\r
+        * Constructs a newly allocated AudioPassThruCapabilities object\r
+        */\r
+    public AudioPassThruCapabilities() {}\r
+    \r
+    /**\r
+     * Constructs a newly allocated AudioPassThruCapabilities object indicated by the Hashtable parameter\r
+     * @param hash The Hashtable to use\r
+     */\r
+    public AudioPassThruCapabilities(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    \r
+    /**\r
+     * set the sampling rate for AudioPassThru\r
+     * @param samplingRate the sampling rate for AudioPassThru\r
+     */\r
+    public void setSamplingRate(SamplingRate samplingRate) {\r
+       if (samplingRate != null) {\r
+               store.put(Names.samplingRate, samplingRate);\r
+       } else {\r
+               store.remove(Names.samplingRate);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get the sampling rate for AudioPassThru\r
+     * @return  the sampling rate for AudioPassThru\r
+     */\r
+    public SamplingRate getSamplingRate() {\r
+        Object obj = store.get(Names.samplingRate);\r
+        if (obj instanceof SamplingRate) {\r
+            return (SamplingRate) obj;\r
+        } else if (obj instanceof String) {\r
+               SamplingRate theCode = null;\r
+            try {\r
+                theCode = SamplingRate.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.samplingRate, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    \r
+    /**\r
+     * set the sample depth in bit for AudioPassThru\r
+     * @param bitsPerSample the sample depth in bit for AudioPassThru\r
+     */\r
+    public void setBitsPerSample(BitsPerSample bitsPerSample) {\r
+       if (bitsPerSample != null) {\r
+               store.put(Names.bitsPerSample, bitsPerSample);\r
+       } else {\r
+               store.remove(Names.bitsPerSample);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get  the sample depth in bit for AudioPassThru\r
+     * @return the sample depth in bit for AudioPassThru\r
+     */\r
+    public BitsPerSample getBitsPerSample() {\r
+        Object obj = store.get(Names.bitsPerSample);\r
+        if (obj instanceof BitsPerSample) {\r
+            return (BitsPerSample) obj;\r
+        } else if (obj instanceof String) {\r
+               BitsPerSample theCode = null;\r
+            try {\r
+                theCode = BitsPerSample.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.bitsPerSample, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    \r
+    /**\r
+     * set the audiotype for AudioPassThru\r
+     * @param audioType the audiotype for AudioPassThru\r
+     */\r
+    public void setAudioType(AudioType audioType) {\r
+       if (audioType != null) {\r
+               store.put(Names.audioType, audioType);\r
+       } else {\r
+               store.remove(Names.audioType);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get the audiotype for AudioPassThru\r
+     * @return the audiotype for AudioPassThru\r
+     */\r
+    public AudioType getAudioType() {\r
+        Object obj = store.get(Names.audioType);\r
+        if (obj instanceof AudioType) {\r
+            return (AudioType) obj;\r
+        } else if (obj instanceof String) {\r
+               AudioType theCode = null;\r
+            try {\r
+                theCode = AudioType.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.audioType, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/BeltStatus.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/BeltStatus.java
new file mode 100755 (executable)
index 0000000..5ac0cef
--- /dev/null
@@ -0,0 +1,347 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.VehicleDataEventStatus;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+public class BeltStatus extends RPCStruct {\r
+\r
+    public BeltStatus() { }\r
+    public BeltStatus(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+\r
+    public void setDriverBeltDeployed(VehicleDataEventStatus driverBeltDeployed) {\r
+        if (driverBeltDeployed != null) {\r
+            store.put(Names.driverBeltDeployed, driverBeltDeployed);\r
+        } else {\r
+               store.remove(Names.driverBeltDeployed);\r
+        }\r
+    }\r
+    public VehicleDataEventStatus getDriverBeltDeployed() {\r
+        Object obj = store.get(Names.driverBeltDeployed);\r
+        if (obj instanceof VehicleDataEventStatus) {\r
+            return (VehicleDataEventStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataEventStatus theCode = null;\r
+            try {\r
+                theCode = VehicleDataEventStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.driverBeltDeployed, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setPassengerBeltDeployed(VehicleDataEventStatus passengerBeltDeployed) {\r
+        if (passengerBeltDeployed != null) {\r
+            store.put(Names.passengerBeltDeployed, passengerBeltDeployed);\r
+        } else {\r
+               store.remove(Names.passengerBeltDeployed);\r
+        }\r
+    }\r
+    public VehicleDataEventStatus getPassengerBeltDeployed() {\r
+        Object obj = store.get(Names.passengerBeltDeployed);\r
+        if (obj instanceof VehicleDataEventStatus) {\r
+            return (VehicleDataEventStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataEventStatus theCode = null;\r
+            try {\r
+                theCode = VehicleDataEventStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.passengerBeltDeployed, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setPassengerBuckleBelted(VehicleDataEventStatus passengerBuckleBelted) {\r
+        if (passengerBuckleBelted != null) {\r
+            store.put(Names.passengerBuckleBelted, passengerBuckleBelted);\r
+        } else {\r
+               store.remove(Names.passengerBuckleBelted);\r
+        }\r
+    }\r
+    public VehicleDataEventStatus getPassengerBuckleBelted() {\r
+        Object obj = store.get(Names.passengerBuckleBelted);\r
+        if (obj instanceof VehicleDataEventStatus) {\r
+            return (VehicleDataEventStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataEventStatus theCode = null;\r
+            try {\r
+                theCode = VehicleDataEventStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.passengerBuckleBelted, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setDriverBuckleBelted(VehicleDataEventStatus driverBuckleBelted) {\r
+        if (driverBuckleBelted != null) {\r
+            store.put(Names.driverBuckleBelted, driverBuckleBelted);\r
+        } else {\r
+               store.remove(Names.driverBuckleBelted);\r
+        }\r
+    }\r
+    public VehicleDataEventStatus getDriverBuckleBelted() {\r
+        Object obj = store.get(Names.driverBuckleBelted);\r
+        if (obj instanceof VehicleDataEventStatus) {\r
+            return (VehicleDataEventStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataEventStatus theCode = null;\r
+            try {\r
+                theCode = VehicleDataEventStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.driverBuckleBelted, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setLeftRow2BuckleBelted(VehicleDataEventStatus leftRow2BuckleBelted) {\r
+        if (leftRow2BuckleBelted != null) {\r
+            store.put(Names.leftRow2BuckleBelted, leftRow2BuckleBelted);\r
+        } else {\r
+               store.remove(Names.leftRow2BuckleBelted);\r
+        }\r
+    }\r
+    public VehicleDataEventStatus getLeftRow2BuckleBelted() {\r
+        Object obj = store.get(Names.leftRow2BuckleBelted);\r
+        if (obj instanceof VehicleDataEventStatus) {\r
+            return (VehicleDataEventStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataEventStatus theCode = null;\r
+            try {\r
+                theCode = VehicleDataEventStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.leftRow2BuckleBelted, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setPassengerChildDetected(VehicleDataEventStatus passengerChildDetected) {\r
+        if (passengerChildDetected != null) {\r
+            store.put(Names.passengerChildDetected, passengerChildDetected);\r
+        } else {\r
+               store.remove(Names.passengerChildDetected);\r
+        }\r
+    }\r
+    public VehicleDataEventStatus getPassengerChildDetected() {\r
+        Object obj = store.get(Names.passengerChildDetected);\r
+        if (obj instanceof VehicleDataEventStatus) {\r
+            return (VehicleDataEventStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataEventStatus theCode = null;\r
+            try {\r
+                theCode = VehicleDataEventStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.passengerChildDetected, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setRightRow2BuckleBelted(VehicleDataEventStatus rightRow2BuckleBelted) {\r
+        if (rightRow2BuckleBelted != null) {\r
+            store.put(Names.rightRow2BuckleBelted, rightRow2BuckleBelted);\r
+        } else {\r
+               store.remove(Names.rightRow2BuckleBelted);\r
+        }\r
+    }\r
+    public VehicleDataEventStatus getRightRow2BuckleBelted() {\r
+        Object obj = store.get(Names.rightRow2BuckleBelted);\r
+        if (obj instanceof VehicleDataEventStatus) {\r
+            return (VehicleDataEventStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataEventStatus theCode = null;\r
+            try {\r
+                theCode = VehicleDataEventStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.rightRow2BuckleBelted, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setMiddleRow2BuckleBelted(VehicleDataEventStatus middleRow2BuckleBelted) {\r
+        if (middleRow2BuckleBelted != null) {\r
+            store.put(Names.middleRow2BuckleBelted, middleRow2BuckleBelted);\r
+        } else {\r
+               store.remove(Names.middleRow2BuckleBelted);\r
+        }\r
+    }\r
+    public VehicleDataEventStatus getMiddleRow2BuckleBelted() {\r
+        Object obj = store.get(Names.middleRow2BuckleBelted);\r
+        if (obj instanceof VehicleDataEventStatus) {\r
+            return (VehicleDataEventStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataEventStatus theCode = null;\r
+            try {\r
+                theCode = VehicleDataEventStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.middleRow2BuckleBelted, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setMiddleRow3BuckleBelted(VehicleDataEventStatus middleRow3BuckleBelted) {\r
+        if (middleRow3BuckleBelted != null) {\r
+            store.put(Names.middleRow3BuckleBelted, middleRow3BuckleBelted);\r
+        } else {\r
+               store.remove(Names.middleRow3BuckleBelted);\r
+        }\r
+    }\r
+    public VehicleDataEventStatus getMiddleRow3BuckleBelted() {\r
+        Object obj = store.get(Names.middleRow3BuckleBelted);\r
+        if (obj instanceof VehicleDataEventStatus) {\r
+            return (VehicleDataEventStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataEventStatus theCode = null;\r
+            try {\r
+                theCode = VehicleDataEventStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.middleRow3BuckleBelted, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setLeftRow3BuckleBelted(VehicleDataEventStatus leftRow3BuckleBelted) {\r
+        if (leftRow3BuckleBelted != null) {\r
+            store.put(Names.leftRow3BuckleBelted, leftRow3BuckleBelted);\r
+        } else {\r
+               store.remove(Names.leftRow3BuckleBelted);\r
+        }\r
+    }\r
+    public VehicleDataEventStatus getLeftRow3BuckleBelted() {\r
+        Object obj = store.get(Names.leftRow3BuckleBelted);\r
+        if (obj instanceof VehicleDataEventStatus) {\r
+            return (VehicleDataEventStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataEventStatus theCode = null;\r
+            try {\r
+                theCode = VehicleDataEventStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.leftRow3BuckleBelted, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setRightRow3BuckleBelted(VehicleDataEventStatus rightRow3BuckleBelted) {\r
+        if (rightRow3BuckleBelted != null) {\r
+            store.put(Names.rightRow3BuckleBelted, rightRow3BuckleBelted);\r
+        } else {\r
+               store.remove(Names.rightRow3BuckleBelted);\r
+        }\r
+    }\r
+    public VehicleDataEventStatus getRightRow3BuckleBelted() {\r
+        Object obj = store.get(Names.rightRow3BuckleBelted);\r
+        if (obj instanceof VehicleDataEventStatus) {\r
+            return (VehicleDataEventStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataEventStatus theCode = null;\r
+            try {\r
+                theCode = VehicleDataEventStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.rightRow3BuckleBelted, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setLeftRearInflatableBelted(VehicleDataEventStatus rearInflatableBelted) {\r
+        if (rearInflatableBelted != null) {\r
+            store.put(Names.rearInflatableBelted, rearInflatableBelted);\r
+        } else {\r
+               store.remove(Names.rearInflatableBelted);\r
+        }\r
+    }\r
+    public VehicleDataEventStatus getLeftRearInflatableBelted() {\r
+        Object obj = store.get(Names.rearInflatableBelted);\r
+        if (obj instanceof VehicleDataEventStatus) {\r
+            return (VehicleDataEventStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataEventStatus theCode = null;\r
+            try {\r
+                theCode = VehicleDataEventStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.rearInflatableBelted, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setRightRearInflatableBelted(VehicleDataEventStatus rightRearInflatableBelted) {\r
+        if (rightRearInflatableBelted != null) {\r
+            store.put(Names.rightRearInflatableBelted, rightRearInflatableBelted);\r
+        } else {\r
+               store.remove(Names.rightRearInflatableBelted);\r
+        }\r
+    }\r
+    public VehicleDataEventStatus getRightRearInflatableBelted() {\r
+        Object obj = store.get(Names.rightRearInflatableBelted);\r
+        if (obj instanceof VehicleDataEventStatus) {\r
+            return (VehicleDataEventStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataEventStatus theCode = null;\r
+            try {\r
+                theCode = VehicleDataEventStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.rightRearInflatableBelted, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setMiddleRow1BeltDeployed(VehicleDataEventStatus middleRow1BeltDeployed) {\r
+        if (middleRow1BeltDeployed != null) {\r
+            store.put(Names.middleRow1BeltDeployed, middleRow1BeltDeployed);\r
+        } else {\r
+               store.remove(Names.middleRow1BeltDeployed);\r
+        }\r
+    }\r
+    public VehicleDataEventStatus getMiddleRow1BeltDeployed() {\r
+        Object obj = store.get(Names.middleRow1BeltDeployed);\r
+        if (obj instanceof VehicleDataEventStatus) {\r
+            return (VehicleDataEventStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataEventStatus theCode = null;\r
+            try {\r
+                theCode = VehicleDataEventStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.middleRow1BeltDeployed, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setMiddleRow1BuckleBelted(VehicleDataEventStatus middleRow1BuckleBelted) {\r
+        if (middleRow1BuckleBelted != null) {\r
+            store.put(Names.middleRow1BuckleBelted, middleRow1BuckleBelted);\r
+        } else {\r
+               store.remove(Names.middleRow1BuckleBelted);\r
+        }\r
+    }\r
+    public VehicleDataEventStatus getMiddleRow1BuckleBelted() {\r
+        Object obj = store.get(Names.middleRow1BuckleBelted);\r
+        if (obj instanceof VehicleDataEventStatus) {\r
+            return (VehicleDataEventStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataEventStatus theCode = null;\r
+            try {\r
+                theCode = VehicleDataEventStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.middleRow1BuckleBelted, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/BodyInformation.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/BodyInformation.java
new file mode 100755 (executable)
index 0000000..475fc7c
--- /dev/null
@@ -0,0 +1,72 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.IgnitionStableStatus;\r
+import com.smartdevicelink.proxy.rpc.enums.IgnitionStatus;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+public class BodyInformation extends RPCStruct {\r
+\r
+    public BodyInformation() { }\r
+    public BodyInformation(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+\r
+    public void setParkBrakeActive(Boolean parkBrakeActive) {\r
+        if (parkBrakeActive != null) {\r
+               store.put(Names.parkBrakeActive, parkBrakeActive);\r
+        } else {\r
+               store.remove(Names.parkBrakeActive);\r
+        }\r
+    }\r
+    public Boolean getParkBrakeActive() {\r
+        return (Boolean) store.get(Names.parkBrakeActive);\r
+    }\r
+    public void setIgnitionStableStatus(IgnitionStableStatus ignitionStableStatus) {\r
+        if (ignitionStableStatus != null) {\r
+            store.put(Names.ignitionStableStatus, ignitionStableStatus);\r
+        } else {\r
+               store.remove(Names.ignitionStableStatus);\r
+        }\r
+    }\r
+    public IgnitionStableStatus getIgnitionStableStatus() {\r
+        Object obj = store.get(Names.ignitionStableStatus);\r
+        if (obj instanceof IgnitionStableStatus) {\r
+            return (IgnitionStableStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               IgnitionStableStatus theCode = null;\r
+            try {\r
+                theCode = IgnitionStableStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.ignitionStableStatus, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setIgnitionStatus(IgnitionStatus ignitionStatus) {\r
+        if (ignitionStatus != null) {\r
+            store.put(Names.ignitionStatus, ignitionStatus);\r
+        } else {\r
+               store.remove(Names.ignitionStatus);\r
+        }\r
+    }\r
+    public IgnitionStatus getIgnitionStatus() {\r
+        Object obj = store.get(Names.ignitionStatus);\r
+        if (obj instanceof IgnitionStatus) {\r
+            return (IgnitionStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               IgnitionStatus theCode = null;\r
+            try {\r
+                theCode = IgnitionStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.ignitionStatus, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+}
\ No newline at end of file
index a16f31c..0c4906e 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCStruct;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.ButtonName;
-import com.smartdevicelink.util.DebugTool;
-
-public class ButtonCapabilities extends RPCStruct {
-
-    public ButtonCapabilities() { }
-    public ButtonCapabilities(Hashtable hash) {
-        super(hash);
-    }
-    public ButtonName getName() {
-        Object obj = store.get(Names.name);
-        if (obj instanceof ButtonName) {
-            return (ButtonName) obj;
-        } else if (obj instanceof String) {
-            ButtonName theCode = null;
-            try {
-                theCode = ButtonName.valueForString((String) obj);
-            } catch (Exception e) {
-                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.name, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setName( ButtonName name ) {
-        if (name != null) {
-            store.put(Names.name, name );
-        }
-    }
-    public Boolean getShortPressAvailable() {
-        return (Boolean) store.get( Names.shortPressAvailable );
-    }
-    public void setShortPressAvailable( Boolean shortPressAvailable ) {
-        if (shortPressAvailable != null) {
-            store.put(Names.shortPressAvailable, shortPressAvailable );
-        }
-    }
-    public Boolean getLongPressAvailable() {
-        return (Boolean) store.get( Names.longPressAvailable );
-    }
-    public void setLongPressAvailable( Boolean longPressAvailable ) {
-        if (longPressAvailable != null) {
-            store.put(Names.longPressAvailable, longPressAvailable );
-        }
-    }
-    public Boolean getUpDownAvailable() {
-        return (Boolean) store.get( Names.upDownAvailable );
-    }
-    public void setUpDownAvailable( Boolean upDownAvailable ) {
-        if (upDownAvailable != null) {
-            store.put(Names.upDownAvailable, upDownAvailable );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.ButtonName;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Provides information about the capabilities of a SMARTDEVICELINK HMI button.\r
+ * <p><b> Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>name</td>\r
+ *                     <td>ButtonName</td>\r
+ *                     <td>The name of theSMARTDEVICELINK HMI button.</td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>shortPressAvailable</td>\r
+ *                     <td>Boolean</td>\r
+ *                     <td>The button supports a SHORT press. See ButtonPressMode for more information.</td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ *     <tr>\r
+ *                     <td>longPressAvailable</td>\r
+ *                     <td>Boolean</td>\r
+ *                     <td>The button supports a LONG press. See ButtonPressMode for more information.</td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ *     <tr>\r
+ *                     <td>upDownAvailable</td>\r
+ *                     <td>Boolean</td>\r
+ *                     <td>The button supports "button down" and "button up". When the button is depressed, the <i>{@linkplain OnButtonEvent}</i> notification will be invoked with a value of BUTTONDOWN.\r
+ *                  <p> When the button is released, the <i>{@linkplain OnButtonEvent}</i> notification will be invoked with a value of BUTTONUP.</td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ * </table>\r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class ButtonCapabilities extends RPCStruct {\r
+       /**\r
+        * Constructs a newly allocated ButtonCapabilities object\r
+        */\r
+    public ButtonCapabilities() { }\r
+    /**\r
+     * Constructs a newly allocated ButtonCapabilities object indicated by the Hashtable parameter\r
+     * @param hash The Hashtable to use\r
+     */\r
+    public ButtonCapabilities(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * Get the name of theSMARTDEVICELINK HMI button.\r
+     * @return ButtonName the name of the Button\r
+     */    \r
+    public ButtonName getName() {\r
+        Object obj = store.get(Names.name);\r
+        if (obj instanceof ButtonName) {\r
+            return (ButtonName) obj;\r
+        } else if (obj instanceof String) {\r
+            ButtonName theCode = null;\r
+            try {\r
+                theCode = ButtonName.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.name, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Set the name of theSMARTDEVICELINK HMI button.\r
+     * @param name the name of button\r
+     */    \r
+    public void setName( ButtonName name ) {\r
+        if (name != null) {\r
+            store.put(Names.name, name );\r
+        }\r
+    }\r
+    /**\r
+     * Whether the button supports a SHORT press. See <i>{@linkplain com.smartdevicelink.proxy.rpc.enums.ButtonPressMode}</i> for more information.\r
+     * @return True if support otherwise False.\r
+     */    \r
+    public Boolean getShortPressAvailable() {\r
+        return (Boolean) store.get( Names.shortPressAvailable );\r
+    }\r
+    /**\r
+     * Set the button supports a SHORT press. See <i>{@linkplain com.smartdevicelink.proxy.rpc.enums.ButtonPressMode}</i> for more information.\r
+     * @param shortPressAvailable True if support otherwise False.\r
+     */    \r
+    public void setShortPressAvailable( Boolean shortPressAvailable ) {\r
+        if (shortPressAvailable != null) {\r
+            store.put(Names.shortPressAvailable, shortPressAvailable );\r
+        }\r
+    }\r
+    /**\r
+     * Whether the button supports a LONG press. See <i>{@linkplain com.smartdevicelink.proxy.rpc.enums.ButtonPressMode}</i> for more information.\r
+     * @return True if support otherwise False.\r
+     */\r
+    public Boolean getLongPressAvailable() {\r
+        return (Boolean) store.get( Names.longPressAvailable );\r
+    }\r
+    /**\r
+     * Set the button supports a LONG press. See <i>{@linkplain com.smartdevicelink.proxy.rpc.enums.ButtonPressMode}</i> for more information.\r
+     * @param longPressAvailable True if support otherwise False.\r
+     */    \r
+    public void setLongPressAvailable( Boolean longPressAvailable ) {\r
+        if (longPressAvailable != null) {\r
+            store.put(Names.longPressAvailable, longPressAvailable );\r
+        }\r
+    }\r
+    /**\r
+     * Whether the button supports "button down" and "button up". When the button is depressed, the <i>{@linkplain OnButtonEvent}</i> notification will be invoked with a value of BUTTONDOWN.\r
+     * @return True if support otherwise False.\r
+     */    \r
+    public Boolean getUpDownAvailable() {\r
+        return (Boolean) store.get( Names.upDownAvailable );\r
+    }\r
+    /**\r
+     * Set the button supports "button down" and "button up". When the button is depressed, the <i>{@linkplain OnButtonEvent}</i> notification will be invoked with a value of BUTTONDOWN.\r
+     * @param upDownAvailable True if support otherwise False.\r
+     */    \r
+    public void setUpDownAvailable( Boolean upDownAvailable ) {\r
+        if (upDownAvailable != null) {\r
+            store.put(Names.upDownAvailable, upDownAvailable );\r
+        }\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ChangeRegistration.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ChangeRegistration.java
new file mode 100755 (executable)
index 0000000..243ec2b
--- /dev/null
@@ -0,0 +1,114 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.Language;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * If the app recognizes during the app registration that the SmartDeviceLink HMI language\r
+ * (voice/TTS and/or display) does not match the app language, the app will be\r
+ * able (but does not need) to change this registration with changeRegistration\r
+ * prior to app being brought into focus\r
+ * <p>\r
+ * Function Group: Base\r
+ * <p>\r
+ * <b>HMILevel can by any</b>\r
+ * <p>\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ * @see RegisterAppInterface\r
+ */\r
+public class ChangeRegistration extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new ChangeRegistration object\r
+        */\r
+    public ChangeRegistration() {\r
+        super("ChangeRegistration");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new ChangeRegistration object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public ChangeRegistration(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+\r
+       /**\r
+        * Sets language\r
+        * \r
+        * @param language\r
+        *            a language value\r
+        */\r
+    public void setLanguage(Language language) {\r
+        if (language != null) {\r
+            parameters.put(Names.language, language);\r
+        } else {\r
+               parameters.remove(Names.language);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets language\r
+        * \r
+        * @return Language -a Language value\r
+        */\r
+    public Language getLanguage() {\r
+       Object obj = parameters.get(Names.language);\r
+        if (obj instanceof Language) {\r
+            return (Language) obj;\r
+        } else if (obj instanceof String) {\r
+               Language theCode = null;\r
+            try {\r
+                theCode = Language.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.language, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * Sets HMI display language\r
+        * \r
+        * @param hmiDisplayLanguage\r
+        *            a Language value\r
+        */\r
+    public void setHmiDisplayLanguage(Language hmiDisplayLanguage) {\r
+        if (hmiDisplayLanguage != null) {\r
+            parameters.put(Names.hmiDisplayLanguage, hmiDisplayLanguage);\r
+        } else {\r
+               parameters.remove(Names.hmiDisplayLanguage);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets HMI display language\r
+        * \r
+        * @return Language -a Language value\r
+        */\r
+    public Language getHmiDisplayLanguage() {\r
+       Object obj = parameters.get(Names.hmiDisplayLanguage);\r
+        if (obj instanceof Language) {\r
+            return (Language) obj;\r
+        } else if (obj instanceof String) {\r
+               Language theCode = null;\r
+            try {\r
+                theCode = Language.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.hmiDisplayLanguage, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ChangeRegistrationResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ChangeRegistrationResponse.java
new file mode 100755 (executable)
index 0000000..097c3bf
--- /dev/null
@@ -0,0 +1,32 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Change Registration Response is sent, when ChangeRegistration has been called\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class ChangeRegistrationResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new ChangeRegistrationResponse object\r
+        */\r
+    public ChangeRegistrationResponse() {\r
+        super("ChangeLanguageRegistration");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new ChangeRegistrationResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public ChangeRegistrationResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
index 67c211b..a48610a 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-import java.util.Vector;
-
-import com.smartdevicelink.proxy.RPCStruct;
-import com.smartdevicelink.proxy.constants.Names;
-
-public class Choice extends RPCStruct {
-
-    public Choice() { }
-    public Choice(Hashtable hash) {
-        super(hash);
-    }
-    public Integer getChoiceID() {
-        return (Integer) store.get( Names.choiceID );
-    }
-    public void setChoiceID( Integer choiceID ) {
-        if (choiceID != null) {
-            store.put(Names.choiceID, choiceID );
-        }
-    }
-    public String getMenuName() {
-        return (String) store.get( Names.menuName );
-    }
-    public void setMenuName( String menuName ) {
-        if (menuName != null) {
-            store.put(Names.menuName, menuName );
-        }
-    }
-    public Vector<String> getVrCommands() {
-        if (store.get(Names.vrCommands) instanceof Vector<?>) {
-               Vector<?> list = (Vector<?>)store.get( Names.vrCommands );
-               if (list != null && list.size() > 0) {
-                       Object obj = list.get(0);
-                       if (obj instanceof String) {
-                       return (Vector<String>) list;                           
-                       }
-               }
-        }
-        return null;
-    }
-    public void setVrCommands( Vector<String> vrCommands ) {
-        if (vrCommands != null) {
-            store.put(Names.vrCommands, vrCommands );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * A choice is an option which a user can select either via the menu or via voice recognition (VR) during an application initiated interaction.\r
+ * <p><b> Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>choiceID</td>\r
+ *                     <td>Int16</td>\r
+ *                     <td>Application-scoped identifier that uniquely identifies this choice.\r
+ *             <br/>Min: 0\r
+ *                             <br/>Max: 65535\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>menuName</td>\r
+ *                     <td>String</td>\r
+ *                     <td>Text which appears in menu, representing this choice.\r
+ *                             <br/>Min: 1\r
+ *                             <br/>Max: 100\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ *     <tr>\r
+ *                     <td>vrCommands</td>\r
+ *                     <td>String[]</td>\r
+ *                     <td>An array of strings to be used as VR synonyms for this choice. If this array is provided, it must have at least one non-empty element</td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ *     <tr>\r
+ *                     <td>image</td>\r
+ *                     <td>Image</td>\r
+ *                     <td>Either a static hex icon value or a binary image file  name identifier (sent by PutFile).</td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ * </table>\r
+ * \r
+  * @since SmartDeviceLink 1.0\r
+ */\r
+public class Choice extends RPCStruct {\r
+       /**\r
+        * Constructs a newly allocated Choice object\r
+        */\r
+    public Choice() { }\r
+    /**\r
+     * Constructs a newly allocated Choice object indicated by the Hashtable parameter\r
+     * @param hash The Hashtable to use\r
+     */    \r
+    public Choice(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * Get the application-scoped identifier that uniquely identifies this choice.\r
+     * @return choiceID Min: 0  Max: 65535\r
+     */    \r
+    public Integer getChoiceID() {\r
+        return (Integer) store.get(Names.choiceID);\r
+    }\r
+    /**\r
+     * Set the application-scoped identifier that uniquely identifies this choice.\r
+     * @param choiceID Min: 0  Max: 65535\r
+     */    \r
+    public void setChoiceID(Integer choiceID) {\r
+        if (choiceID != null) {\r
+            store.put(Names.choiceID, choiceID);\r
+        }\r
+    }\r
+    /**\r
+     * Text which appears in menu, representing this choice.\r
+     *                         <br/>Min: 1\r
+     *                         <br/>Max: 100\r
+     * @return menuName the menu name\r
+     */    \r
+    public String getMenuName() {\r
+        return (String) store.get(Names.menuName);\r
+    }\r
+    /**\r
+     * Text which appears in menu, representing this choice.\r
+     *                         <br/>Min: 1\r
+     *                         <br/>Max: 100\r
+     * @param menuName the menu name\r
+     */    \r
+    public void setMenuName(String menuName) {\r
+        if (menuName != null) {\r
+            store.put(Names.menuName, menuName);\r
+        }\r
+    }\r
+    /**\r
+     * Get an array of strings to be used as VR synonyms for this choice. If this array is provided, it must have at least one non-empty element\r
+     * @return vrCommands Vector\r
+     * @since SmartDeviceLink 2.0\r
+     */    \r
+    public Vector<String> getVrCommands() {\r
+        if (store.get(Names.vrCommands) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)store.get( Names.vrCommands);\r
+               if (list != null && list.size() > 0) {\r
+                       Object obj = list.get(0);\r
+                       if (obj instanceof String) {\r
+                       return (Vector<String>) list;                           \r
+                       }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Set an array of strings to be used as VR synonyms for this choice. If this array is provided, it must have at least one non-empty element\r
+     * @param vrCommands the Vector of  vrCommands\r
+     * @since SmartDeviceLink 2.0\r
+     */    \r
+    public void setVrCommands(Vector<String> vrCommands) {\r
+        if (vrCommands != null) {\r
+            store.put(Names.vrCommands, vrCommands);\r
+        }\r
+    }\r
+    /**\r
+     * Set the image\r
+     * @param image the image of the choice\r
+     */    \r
+    public void setImage(Image image) {\r
+        if (image != null) {\r
+            store.put(Names.image, image);\r
+        } else {\r
+               store.remove(Names.image);\r
+        }\r
+    }\r
+    /**\r
+     * Get the image\r
+     * @return the image of the choice\r
+     */    \r
+    public Image getImage() {\r
+       Object obj = store.get(Names.image);\r
+        if (obj instanceof Image) {\r
+            return (Image) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new Image((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.image, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+}\r
index 12c1977..d86095d 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-import java.util.Vector;
-
-import com.smartdevicelink.proxy.RPCRequest;
-import com.smartdevicelink.proxy.constants.Names;
-
-public class CreateInteractionChoiceSet extends RPCRequest {
-
-    public CreateInteractionChoiceSet() {
-        super("CreateInteractionChoiceSet");
-    }
-    public CreateInteractionChoiceSet(Hashtable hash) {
-        super(hash);
-    }
-    public Integer getInteractionChoiceSetID() {
-        return (Integer) parameters.get( Names.interactionChoiceSetID );
-    }
-    public void setInteractionChoiceSetID( Integer interactionChoiceSetID ) {
-        if (interactionChoiceSetID != null) {
-            parameters.put(Names.interactionChoiceSetID, interactionChoiceSetID );
-        }
-    }
-    public Vector<Choice> getChoiceSet() {
-        if (parameters.get(Names.choiceSet) instanceof Vector<?>) {
-               Vector<?> list = (Vector<?>)parameters.get(Names.choiceSet);
-               if (list != null && list.size() > 0) {
-                   Object obj = list.get(0);
-                   if (obj instanceof Choice) {
-                       return (Vector<Choice>) list;
-                   } else if (obj instanceof Hashtable) {
-                       Vector<Choice> newList = new Vector<Choice>();
-                       for (Object hashObj : list) {
-                           newList.add(new Choice((Hashtable)hashObj));
-                       }
-                       return newList;
-                   }
-               }
-        }
-        return null;
-    }
-    public void setChoiceSet( Vector<Choice> choiceSet ) {
-        if (choiceSet != null) {
-            parameters.put(Names.choiceSet, choiceSet );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Creates a Choice Set which can be used in subsequent <i>\r
+ * {@linkplain PerformInteraction}</i> Operations.\r
+ * <p>\r
+ * Function Group: Base \r
+ * <p>\r
+ * <b>HMILevel needs to be FULL, LIMITED or BACKGROUND</b>\r
+ * </p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ * @see DeleteInteractionChoiceSet\r
+ * @see PerformInteraction\r
+ */\r
+public class CreateInteractionChoiceSet extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new CreateInteractionChoiceSet object\r
+        */    \r
+       public CreateInteractionChoiceSet() {\r
+        super("CreateInteractionChoiceSet");\r
+    }\r
+       /**\r
+        * Constructs a new CreateInteractionChoiceSet object indicated by the\r
+        * Hashtable parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */     \r
+    public CreateInteractionChoiceSet(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+       /**\r
+        * Gets the Choice Set unique ID\r
+        * \r
+        * @return Integer -an Integer representing the Choice Set ID\r
+        */    \r
+    public Integer getInteractionChoiceSetID() {\r
+        return (Integer) parameters.get( Names.interactionChoiceSetID );\r
+    }\r
+       /**\r
+        * Sets a unique ID that identifies the Choice Set\r
+        * \r
+        * @param interactionChoiceSetID\r
+        *            an Integer value representing the Choice Set ID\r
+        *            <p>\r
+        *            <b>Notes: </b>Min Value: 0; Max Value: 2000000000\r
+        */    \r
+    public void setInteractionChoiceSetID( Integer interactionChoiceSetID ) {\r
+        if (interactionChoiceSetID != null) {\r
+            parameters.put(Names.interactionChoiceSetID, interactionChoiceSetID );\r
+        }\r
+    }\r
+       /**\r
+        * Gets Choice Set Array of one or more elements\r
+        * \r
+        * @return Vector<Choice> -a Vector<Choice> representing the array of one or\r
+        *         more elements\r
+        */    \r
+    public Vector<Choice> getChoiceSet() {\r
+        if (parameters.get(Names.choiceSet) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.choiceSet);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof Choice) {\r
+                       return (Vector<Choice>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<Choice> newList = new Vector<Choice>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new Choice((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+       /**\r
+        * Sets a Choice Set that is an Array of one or more elements\r
+        * \r
+        * @param choiceSet\r
+        *            a Vector<Choice> representing the array of one or more\r
+        *            elements\r
+        *            <p>\r
+        *            <b>Notes: </b>Min Value: 1; Max Value: 100\r
+        */    \r
+    public void setChoiceSet( Vector<Choice> choiceSet ) {\r
+        if (choiceSet != null) {\r
+            parameters.put(Names.choiceSet, choiceSet );\r
+        }\r
+    }\r
+}\r
index d75c32f..bca2d1b 100755 (executable)
@@ -1,18 +1,21 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCResponse;
-
-public class CreateInteractionChoiceSetResponse extends RPCResponse {
-
-    public CreateInteractionChoiceSetResponse() {
-        super("CreateInteractionChoiceSet");
-    }
-    public CreateInteractionChoiceSetResponse(Hashtable hash) {
-        super(hash);
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Create Interaction ChoiceSet Response is sent, when CreateInteractionChoiceSet\r
+ * has been called\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class CreateInteractionChoiceSetResponse extends RPCResponse {\r
+\r
+    public CreateInteractionChoiceSetResponse() {\r
+        super("CreateInteractionChoiceSet");\r
+    }\r
+    public CreateInteractionChoiceSetResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DIDResult.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DIDResult.java
new file mode 100755 (executable)
index 0000000..303f2e2
--- /dev/null
@@ -0,0 +1,47 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.VehicleDataResultCode;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+public class DIDResult extends RPCStruct {\r
+       \r
+    public DIDResult() {}\r
+    public DIDResult(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public void setResultCode(VehicleDataResultCode resultCode) {\r
+       if (resultCode != null) {\r
+               store.put(Names.resultCode, resultCode);\r
+       } else {\r
+               store.remove(Names.resultCode);\r
+       }\r
+    }\r
+    public VehicleDataResultCode getResultCode() {\r
+        Object obj = store.get(Names.resultCode);\r
+        if (obj instanceof VehicleDataResultCode) {\r
+            return (VehicleDataResultCode) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataResultCode theCode = null;\r
+            try {\r
+                theCode = VehicleDataResultCode.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.resultCode, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setData(String data) {\r
+       if (data != null) {\r
+               store.put(Names.data, data);\r
+       } else {\r
+               store.remove(Names.data);\r
+       }\r
+    }\r
+    public String getData() {\r
+       return (String) store.get(Names.data);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DTC.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DTC.java
new file mode 100755 (executable)
index 0000000..488a24e
--- /dev/null
@@ -0,0 +1,86 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * String containing hexadecimal identifier as well as other common names.\r
+ * <p><b>Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>statusByte</td>\r
+ *                     <td>String</td>\r
+ *                     <td>Hexadecimal byte string\r
+ *                              <ul>\r
+ *                                     <li>Maxlength = 500</li>\r
+ *                              </ul> \r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *  </table>\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class DTC extends RPCStruct {\r
+\r
+       /**\r
+        * Constructs a newly allocated DTC object\r
+        */\r
+    public DTC() { }\r
+    \r
+    /**\r
+     * Constructs a newly allocated DTC object indicated by the Hashtable parameter\r
+     * @param hash The Hashtable to use\r
+     */\r
+    public DTC(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    \r
+    /**\r
+     * set identifier\r
+     * @param identifier\r
+     */\r
+    public void setIdentifier(String identifier) {\r
+       if (identifier != null) {\r
+               store.put(Names.identifier, identifier);\r
+       } else {\r
+               store.remove(Names.identifier);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get identifier\r
+     * @return identifier\r
+     */\r
+    public String getIdentifier() {\r
+       return (String) store.get(Names.identifier);\r
+    }\r
+    \r
+    /**\r
+     * set Hexadecimal byte string\r
+     * @param statusByte Hexadecimal byte string\r
+     */\r
+    public void setStatusByte(String statusByte) {\r
+       if (statusByte != null) {\r
+               store.put(Names.statusByte, statusByte);\r
+       } else {\r
+               store.remove(Names.statusByte);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get Hexadecimal byte string\r
+     * @return Hexadecimal byte string\r
+     */\r
+    public String getStatusByte() {\r
+       return (String) store.get(Names.statusByte);\r
+    }\r
+}\r
index 567be3c..631648d 100755 (executable)
@@ -1,27 +1,64 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCRequest;
-import com.smartdevicelink.proxy.constants.Names;
-
-public class DeleteCommand extends RPCRequest {
-
-    public DeleteCommand() {
-        super("DeleteCommand");
-    }
-    public DeleteCommand(Hashtable hash) {
-        super(hash);
-    }
-    public Integer getCmdID() {
-        return (Integer) parameters.get( Names.cmdID );
-    }
-    public void setCmdID( Integer cmdID ) {
-        if (cmdID != null) {
-            parameters.put(Names.cmdID, cmdID );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Removes a command from the Command Menu\r
+ * <p>\r
+ * <b>HMI Status Requirements:</b><br/>\r
+ * HMILevel: FULL, LIMITED or BACKGROUND<br/>\r
+ * AudioStreamingState: N/A<br/>\r
+ * SystemContext: Should not be attempted when VRSESSION or MENU\r
+ * </p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ * @see AddCommand\r
+ * @see AddSubMenu\r
+ * @see DeleteSubMenu\r
+ */\r
+public class DeleteCommand extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new DeleteCommand object\r
+        */\r
+       public DeleteCommand() {\r
+        super("DeleteCommand");\r
+    }\r
+       /**\r
+        * Constructs a new DeleteCommand object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */    \r
+       public DeleteCommand(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+       /**\r
+        * Gets the Command ID that identifies the Command to be deleted from\r
+        * Command Menu\r
+        * \r
+        * @return Integer - Integer value representing Command ID that identifies\r
+        *         the Command to be deleted from Command Menu\r
+        */     \r
+    public Integer getCmdID() {\r
+        return (Integer) parameters.get( Names.cmdID );\r
+    }\r
+       /**\r
+        * Sets the Command ID that identifies the Command to be deleted from Command Menu\r
+        * \r
+        * @param cmdID\r
+        *            an Integer value representing Command ID\r
+        *            <p>\r
+        *            <b>Notes: </b>Min Value: 0; Max Value: 2000000000\r
+        */    \r
+    public void setCmdID( Integer cmdID ) {\r
+        if (cmdID != null) {\r
+            parameters.put(Names.cmdID, cmdID );\r
+        }\r
+    }\r
+}
\ No newline at end of file
index fc53f88..34e8bf1 100755 (executable)
@@ -1,18 +1,20 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCResponse;
-
-public class DeleteCommandResponse extends RPCResponse {
-
-    public DeleteCommandResponse() {
-        super("DeleteCommand");
-    }
-    public DeleteCommandResponse(Hashtable hash) {
-        super(hash);
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Delete Command Response is sent, when DeleteCommand has been called\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class DeleteCommandResponse extends RPCResponse {\r
+\r
+    public DeleteCommandResponse() {\r
+        super("DeleteCommand");\r
+    }\r
+    public DeleteCommandResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DeleteFile.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DeleteFile.java
new file mode 100755 (executable)
index 0000000..9ddc93f
--- /dev/null
@@ -0,0 +1,59 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Used to delete a file resident on the SMARTDEVICELINK module in the app's local cache.\r
+ * Not supported on first generation SMARTDEVICELINK vehicles\r
+ * <p>\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ * @see PutFile\r
+ * @see ListFiles\r
+ */\r
+public class DeleteFile extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new DeleteFile object\r
+        */\r
+    public DeleteFile() {\r
+        super("DeleteFile");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new DeleteFile object indicated by the Hashtable parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public DeleteFile(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+\r
+       /**\r
+        * Sets a file reference name\r
+        * \r
+        * @param smartDeviceLinkFileName\r
+        *            a String value representing a file reference name\r
+        */\r
+    public void setSmartDeviceLinkFileName(String smartDeviceLinkFileName) {\r
+        if (smartDeviceLinkFileName != null) {\r
+            parameters.put(Names.smartDeviceLinkFileName, smartDeviceLinkFileName);\r
+        } else {\r
+               parameters.remove(Names.smartDeviceLinkFileName);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a file reference name\r
+        * \r
+        * @return String -a String value representing a file reference name\r
+        */\r
+    public String getSmartDeviceLinkFileName() {\r
+        return (String) parameters.get(Names.smartDeviceLinkFileName);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DeleteFileResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DeleteFileResponse.java
new file mode 100755 (executable)
index 0000000..8fbb4d0
--- /dev/null
@@ -0,0 +1,31 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Delete File Response is sent, when DeleteFile has been called\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class DeleteFileResponse extends RPCResponse {\r
+\r
+    public DeleteFileResponse() {\r
+        super("DeleteFile");\r
+    }\r
+    public DeleteFileResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public void setSpaceAvailable(Integer spaceAvailable) {\r
+        if (spaceAvailable != null) {\r
+            parameters.put(Names.spaceAvailable, spaceAvailable);\r
+        } else {\r
+               parameters.remove(Names.spaceAvailable);\r
+        }\r
+    }\r
+    public Integer getSpaceAvailable() {\r
+        return (Integer) parameters.get(Names.spaceAvailable);\r
+    }\r
+}
\ No newline at end of file
index 1935d61..51f74c5 100755 (executable)
@@ -1,27 +1,60 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCRequest;
-import com.smartdevicelink.proxy.constants.Names;
-
-public class DeleteInteractionChoiceSet extends RPCRequest {
-
-    public DeleteInteractionChoiceSet() {
-        super("DeleteInteractionChoiceSet");
-    }
-    public DeleteInteractionChoiceSet(Hashtable hash) {
-        super(hash);
-    }
-    public Integer getInteractionChoiceSetID() {
-        return (Integer) parameters.get( Names.interactionChoiceSetID );
-    }
-    public void setInteractionChoiceSetID( Integer interactionChoiceSetID ) {
-        if (interactionChoiceSetID != null) {
-            parameters.put(Names.interactionChoiceSetID, interactionChoiceSetID );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Deletes an existing Choice Set identified by the parameter\r
+ * interactionChoiceSetID. If the specified interactionChoiceSetID is currently\r
+ * in use by an active <i> {@linkplain PerformInteraction}</i> this call to\r
+ * delete the Choice Set will fail returning an IN_USE resultCode\r
+ * <p>\r
+ * Function Group: Base\r
+ * <p>\r
+ * <b>HMILevel needs to be FULL, LIMITED or BACKGROUD</b><br/>\r
+ * </p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ * @see CreateInteractionChoiceSet\r
+ * @see PerformInteraction\r
+ */\r
+public class DeleteInteractionChoiceSet extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new DeleteInteractionChoiceSet object\r
+        */\r
+    public DeleteInteractionChoiceSet() {\r
+        super("DeleteInteractionChoiceSet");\r
+    }\r
+       /**\r
+        * Constructs a new DeleteInteractionChoiceSet object indicated by the\r
+        * Hashtable parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */    \r
+    public DeleteInteractionChoiceSet(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+       /**\r
+        * Gets a unique ID that identifies the Choice Set\r
+        * @return Integer -an Integer value representing the unique Choice Set ID\r
+        */    \r
+    public Integer getInteractionChoiceSetID() {\r
+        return (Integer) parameters.get( Names.interactionChoiceSetID );\r
+    }\r
+       /**\r
+        * Sets a unique ID that identifies the Choice Set\r
+        * @param interactionChoiceSetID a unique ID that identifies the Choice Set\r
+        * <p>\r
+        * <b>Notes: </b>Min Value: 0; Max Value: 2000000000\r
+        */    \r
+    public void setInteractionChoiceSetID( Integer interactionChoiceSetID ) {\r
+        if (interactionChoiceSetID != null) {\r
+            parameters.put(Names.interactionChoiceSetID, interactionChoiceSetID );\r
+        }\r
+    }\r
+}
\ No newline at end of file
index 14b5e07..ea0d8a9 100755 (executable)
@@ -1,18 +1,20 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCResponse;
-
-public class DeleteInteractionChoiceSetResponse extends RPCResponse {
-
-    public DeleteInteractionChoiceSetResponse() {
-        super("DeleteInteractionChoiceSet");
-    }
-    public DeleteInteractionChoiceSetResponse(Hashtable hash) {
-        super(hash);
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Delete Interaction ChoiceSet Response is sent, when DeleteInteractionChoiceSet has been called\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class DeleteInteractionChoiceSetResponse extends RPCResponse {\r
+\r
+    public DeleteInteractionChoiceSetResponse() {\r
+        super("DeleteInteractionChoiceSet");\r
+    }\r
+    public DeleteInteractionChoiceSetResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
index e15218d..ba86fc3 100755 (executable)
@@ -1,27 +1,54 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCRequest;
-import com.smartdevicelink.proxy.constants.Names;
-
-public class DeleteSubMenu extends RPCRequest {
-
-    public DeleteSubMenu() {
-        super("DeleteSubMenu");
-    }
-    public DeleteSubMenu(Hashtable hash) {
-        super(hash);
-    }
-    public Integer getMenuID() {
-        return (Integer) parameters.get( Names.menuID );
-    }
-    public void setMenuID( Integer menuID ) {
-        if (menuID != null) {
-            parameters.put(Names.menuID, menuID );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Deletes a submenu from the Command Menu\r
+ * <p>\r
+ * <b>Notes: </b>When an app deletes a submenu that has child commands, those\r
+ * child commands are also deleted\r
+ * <p>\r
+ * <b>HMILevel needs to be  FULL, LIMITED or BACKGROUND</b>\r
+ * </p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ * @see AddCommand\r
+ * @see AddSubMenu\r
+ * @see DeleteCommand\r
+ */\r
+public class DeleteSubMenu extends RPCRequest {\r
+       /**\r
+       * Constructs a new DeleteSubMenu object\r
+       */\r
+       public DeleteSubMenu() {\r
+        super("DeleteSubMenu");\r
+    }\r
+    /**\r
+     * Constructs a new DeleteSubMenu object indicated by the Hashtable parameter<p>    \r
+     * @param hash The Hashtable to use\r
+     */\r
+    public DeleteSubMenu(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * Gets the Menu ID that identifies the SubMenu to be delete\r
+     * @return Integer -an Integer value representing menuID that identifies the SubMenu to be delete\r
+     */    \r
+    public Integer getMenuID() {\r
+        return (Integer) parameters.get( Names.menuID );\r
+    }\r
+    /**\r
+     * Sets the MenuID that identifies the SubMenu to be delete  \r
+     * @param menuID an Integer value representing menuID that identifies the SubMenu to be delete\r
+     * <p>\r
+     * <b>Notes: </b>Min Value: 0; Max Value: 2000000000\r
+     */    \r
+    public void setMenuID( Integer menuID ) {\r
+        if (menuID != null) {\r
+            parameters.put(Names.menuID, menuID );\r
+        }\r
+    }\r
+}
\ No newline at end of file
index 7dd555f..d8f90e7 100755 (executable)
@@ -1,18 +1,20 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCResponse;
-
-public class DeleteSubMenuResponse extends RPCResponse {
-
-    public DeleteSubMenuResponse() {
-        super("DeleteSubMenu");
-    }
-    public DeleteSubMenuResponse(Hashtable hash) {
-        super(hash);
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Delete SubMenu Response is sent, when DeleteSubMenu has been called\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class DeleteSubMenuResponse extends RPCResponse {\r
+\r
+    public DeleteSubMenuResponse() {\r
+        super("DeleteSubMenu");\r
+    }\r
+    public DeleteSubMenuResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DeviceStatus.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DeviceStatus.java
new file mode 100755 (executable)
index 0000000..1587faf
--- /dev/null
@@ -0,0 +1,356 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.DeviceLevelStatus;\r
+import com.smartdevicelink.proxy.rpc.enums.PrimaryAudioSource;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Describes the status related to a connected mobile device or SMARTDEVICELINK and if or how  it is represented in the vehicle.\r
+ * <p><b>Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>voiceRecOn</td>\r
+ *                     <td>Boolean</td>\r
+ *                     <td>Voice recognition is on\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>btIconOn</td>\r
+ *                     <td>Boolean</td>\r
+ *                     <td>Bluetooth connection established\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>callActive</td>\r
+ *                     <td>Boolean</td>\r
+ *                     <td>A call is being active\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>phoneRoaming</td>\r
+ *                     <td>Boolean</td>\r
+ *                     <td>The phone is in roaming mode\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>textMsgAvailable</td>\r
+ *                     <td>Boolean</td>\r
+ *                     <td>A textmessage is available\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>battLevelStatus</td>\r
+ *                     <td>DeviceLevelStatus</td>\r
+ *                     <td>Battery level status\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>stereoAudioOutputMuted</td>\r
+ *                     <td>Boolean</td>\r
+ *                     <td>Status of the stereo audio output channel\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>monoAudioOutputMuted</td>\r
+ *                     <td>Boolean</td>\r
+ *                     <td>Status of the mono audio output channel\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>signalLevelStatus</td>\r
+ *                     <td>DeviceLevelStatus</td>\r
+ *                     <td>Signal level status\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>primaryAudioSource</td>\r
+ *                     <td>PrimaryAudioSource</td>\r
+ *                     <td>Reflects the current primary audio source of SMARTDEVICELINK (if selected).\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>eCallEventActive</td>\r
+ *                     <td>Boolean</td>\r
+ *                     <td>Reflects, if an eCall event is active\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *  </table>\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class DeviceStatus extends RPCStruct {\r
+\r
+       /**\r
+        * Constructs a newly allocated DeviceStatus object\r
+        */\r
+    public DeviceStatus() {}\r
+    \r
+    /**\r
+     * Constructs a newly allocated DeviceStatus object indicated by the Hashtable parameter\r
+     * @param hash The Hashtable to use\r
+     */\r
+    public DeviceStatus(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    \r
+    /**\r
+     * set the voice recognition on or off\r
+     * @param voiceRecOn\r
+     */\r
+    public void setVoiceRecOn(Boolean voiceRecOn) {\r
+        if (voiceRecOn != null) {\r
+               store.put(Names.voiceRecOn, voiceRecOn);\r
+        } else {\r
+               store.remove(Names.voiceRecOn);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get whether the voice recognition is on\r
+     * @return whether the voice recognition is on\r
+     */\r
+    public Boolean getVoiceRecOn() {\r
+        return (Boolean) store.get(Names.voiceRecOn);\r
+    }\r
+    \r
+    /**\r
+     * set the bluetooth connection established\r
+     * @param btIconOn the bluetooth connection established\r
+     */\r
+    public void setBtIconOn(Boolean btIconOn) {\r
+        if (btIconOn != null) {\r
+               store.put(Names.btIconOn, btIconOn);\r
+        } else {\r
+               store.remove(Names.btIconOn);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get the bluetooth connection established\r
+     * @return the bluetooth connection established\r
+     */\r
+    public Boolean getBtIconOn() {\r
+        return (Boolean) store.get(Names.btIconOn);\r
+    }\r
+    \r
+    /**\r
+     * set a call is being active\r
+     * @param callActive a call is being active\r
+     */\r
+    public void setCallActive(Boolean callActive) {\r
+        if (callActive != null) {\r
+               store.put(Names.callActive, callActive);\r
+        } else {\r
+               store.remove(Names.callActive);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get  a call is being active\r
+     * @return  a call is being active\r
+     */\r
+    public Boolean getCallActive() {\r
+        return (Boolean) store.get(Names.callActive);\r
+    }\r
+    \r
+    /**\r
+     * set the phone is in roaming mode\r
+     * @param phoneRoaming  the phone is in roaming mode\r
+     */\r
+    public void setPhoneRoaming(Boolean phoneRoaming) {\r
+        if (phoneRoaming != null) {\r
+               store.put(Names.phoneRoaming, phoneRoaming);\r
+        } else {\r
+               store.remove(Names.phoneRoaming);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get  the phone is in roaming mode\r
+     * @return  the phone is in roaming mode\r
+     */\r
+    public Boolean getPhoneRoaming() {\r
+        return (Boolean) store.get(Names.phoneRoaming);\r
+    }\r
+    public void setTextMsgAvailable(Boolean textMsgAvailable) {\r
+        if (textMsgAvailable != null) {\r
+               store.put(Names.textMsgAvailable, textMsgAvailable);\r
+        } else {\r
+               store.remove(Names.textMsgAvailable);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get a textmessage is available\r
+     * @return a textmessage is available\r
+     */\r
+    public Boolean getTextMsgAvailable() {\r
+        return (Boolean) store.get(Names.textMsgAvailable);\r
+    }\r
+    \r
+    /**\r
+     * set battery level status\r
+     * @param battLevelStatus battery level status\r
+     */\r
+    public void setBattLevelStatus(DeviceLevelStatus battLevelStatus) {\r
+        if (battLevelStatus != null) {\r
+               store.put(Names.battLevelStatus, battLevelStatus);\r
+        } else {\r
+               store.remove(Names.battLevelStatus);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get battery level status\r
+     * @return battery level status\r
+     */\r
+    public DeviceLevelStatus getBattLevelStatus() {\r
+        Object obj = store.get(Names.battLevelStatus);\r
+        if (obj instanceof DeviceLevelStatus) {\r
+            return (DeviceLevelStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               DeviceLevelStatus theCode = null;\r
+            try {\r
+                theCode = DeviceLevelStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.battLevelStatus, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    \r
+    /**\r
+     * set the status of the stereo audio output channel\r
+     * @param stereoAudioOutputMuted the status of the stereo audio output channel\r
+     */\r
+    public void setStereoAudioOutputMuted(Boolean stereoAudioOutputMuted) {\r
+        if (stereoAudioOutputMuted != null) {\r
+               store.put(Names.stereoAudioOutputMuted, stereoAudioOutputMuted);\r
+        } else {\r
+               store.remove(Names.stereoAudioOutputMuted);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get the status of the stereo audio output channel\r
+     * @return the status of the stereo audio output channel\r
+     */\r
+    public Boolean getStereoAudioOutputMuted() {\r
+        return (Boolean) store.get(Names.stereoAudioOutputMuted);\r
+    }\r
+    \r
+    /**\r
+     * set the status of the mono audio output channel\r
+     * @param monoAudioOutputMuted the status of the mono audio output channel\r
+     */\r
+    public void setMonoAudioOutputMuted(Boolean monoAudioOutputMuted) {\r
+        if (monoAudioOutputMuted != null) {\r
+               store.put(Names.monoAudioOutputMuted, monoAudioOutputMuted);\r
+        } else {\r
+               store.remove(Names.monoAudioOutputMuted);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get the status of the mono audio output channel\r
+     * @return the status of the mono audio output channel\r
+     */\r
+    public Boolean getMonoAudioOutputMuted() {\r
+        return (Boolean) store.get(Names.monoAudioOutputMuted);\r
+    }\r
+    \r
+    /**\r
+     * set signal level status\r
+     * @param signalLevelStatus signal level status\r
+     */\r
+    public void setSignalLevelStatus(DeviceLevelStatus signalLevelStatus) {\r
+        if (signalLevelStatus != null) {\r
+               store.put(Names.signalLevelStatus, signalLevelStatus);\r
+        } else {\r
+               store.remove(Names.signalLevelStatus);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get signal level status\r
+     * @return signal level status\r
+     */\r
+    public DeviceLevelStatus getSignalLevelStatus() {\r
+        Object obj = store.get(Names.signalLevelStatus);\r
+        if (obj instanceof DeviceLevelStatus) {\r
+            return (DeviceLevelStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               DeviceLevelStatus theCode = null;\r
+            try {\r
+                theCode = DeviceLevelStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.signalLevelStatus, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    \r
+    /**\r
+     * set the current primary audio source of SMARTDEVICELINK (if selected).\r
+     * @param primaryAudioSource the current primary audio source of SMARTDEVICELINK (if selected).\r
+     */\r
+    public void setPrimaryAudioSource(PrimaryAudioSource primaryAudioSource) {\r
+        if (primaryAudioSource != null) {\r
+               store.put(Names.primaryAudioSource, primaryAudioSource);\r
+        } else {\r
+               store.remove(Names.primaryAudioSource);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get  the current primary audio source of SMARTDEVICELINK (if selected).\r
+     * @return  the current primary audio source of SMARTDEVICELINK (if selected).\r
+     */\r
+    public PrimaryAudioSource getPrimaryAudioSource() {\r
+        Object obj = store.get(Names.primaryAudioSource);\r
+        if (obj instanceof PrimaryAudioSource) {\r
+            return (PrimaryAudioSource) obj;\r
+        } else if (obj instanceof String) {\r
+               PrimaryAudioSource theCode = null;\r
+            try {\r
+                theCode = PrimaryAudioSource.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.primaryAudioSource, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setECallEventActive(Boolean eCallEventActive) {\r
+        if (eCallEventActive != null) {\r
+               store.put(Names.eCallEventActive, eCallEventActive);\r
+        } else {\r
+               store.remove(Names.eCallEventActive);\r
+        }\r
+    }\r
+    public Boolean getECallEventActive() {\r
+        return (Boolean) store.get(Names.eCallEventActive);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DialNumber.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DialNumber.java
new file mode 100755 (executable)
index 0000000..594da2d
--- /dev/null
@@ -0,0 +1,26 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+public class DialNumber extends RPCRequest {\r
+\r
+    public DialNumber() {\r
+        super("DialNumber");\r
+    }\r
+    public DialNumber(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public String getNumber() {\r
+        return (String) parameters.get(Names.number);\r
+    }\r
+    public void setNumber(String number) {\r
+        if (number != null) {\r
+            parameters.put(Names.number, number);\r
+        } else {\r
+               parameters.remove(Names.number);\r
+        }\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DialNumberResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/DialNumberResponse.java
new file mode 100755 (executable)
index 0000000..bc0b5a2
--- /dev/null
@@ -0,0 +1,15 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+public class DialNumberResponse extends RPCResponse {\r
+\r
+    public DialNumberResponse() {\r
+        super("DialNumber");\r
+    }\r
+    public DialNumberResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
index 69c604d..a098c88 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-import java.util.Vector;
-
-import com.smartdevicelink.proxy.RPCStruct;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.DisplayType;
-import com.smartdevicelink.proxy.rpc.enums.MediaClockFormat;
-import com.smartdevicelink.util.DebugTool;
-
-public class DisplayCapabilities extends RPCStruct {
-
-    public DisplayCapabilities() { }
-    public DisplayCapabilities(Hashtable hash) {
-        super(hash);
-    }
-    public DisplayType getDisplayType() {
-        Object obj = store.get(Names.displayType);
-        if (obj instanceof DisplayType) {
-            return (DisplayType) obj;
-        } else if (obj instanceof String) {
-            DisplayType theCode = null;
-            try {
-                theCode = DisplayType.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.displayType, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setDisplayType( DisplayType displayType ) {
-        if (displayType != null) {
-            store.put(Names.displayType, displayType );
-        }
-    }
-    public Vector<TextField> getTextFields() {
-        if (store.get(Names.textFields) instanceof Vector<?>) {
-               Vector<?> list = (Vector<?>)store.get(Names.textFields);
-               if (list != null && list.size() > 0) {
-                   Object obj = list.get(0);
-                   if (obj instanceof TextField) {
-                       return (Vector<TextField>) list;
-                   } else if (obj instanceof Hashtable) {
-                       Vector<TextField> newList = new Vector<TextField>();
-                       for (Object hashObj : list) {
-                           newList.add(new TextField((Hashtable)hashObj));
-                       }
-                       return newList;
-                   }
-               }
-        }
-        return null;
-    }
-    public void setTextFields( Vector<TextField> textFields ) {
-        if (textFields != null) {
-            store.put(Names.textFields, textFields );
-        }
-    }
-    public Vector<MediaClockFormat> getMediaClockFormats() {
-        if (store.get(Names.mediaClockFormats) instanceof Vector<?>) {
-               Vector<?> list = (Vector<?>)store.get(Names.mediaClockFormats);
-               if (list != null && list.size() > 0) {
-                   Object obj = list.get(0);
-                   if (obj instanceof MediaClockFormat) {
-                       return (Vector<MediaClockFormat>) list;
-                   } else if (obj instanceof String) {
-                       Vector<MediaClockFormat> newList = new Vector<MediaClockFormat>();
-                       for (Object hashObj : list) {
-                           String strFormat = (String)hashObj;
-                           MediaClockFormat toAdd = null;
-                           try {
-                               toAdd = MediaClockFormat.valueForString(strFormat);
-                           } catch (Exception e) {
-                               DebugTool.logError("Failed to parse MediaClockFormat from " + getClass().getSimpleName() + "." + Names.mediaClockFormats, e);
-                           }
-                           if (toAdd != null) {
-                               newList.add(toAdd);
-                           }
-                       }
-                       return newList;
-                   }
-               }
-        }
-        return null;
-    }
-    public void setMediaClockFormats( Vector<MediaClockFormat> mediaClockFormats ) {
-        if (mediaClockFormats != null) {
-            store.put(Names.mediaClockFormats, mediaClockFormats );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.DisplayType;\r
+import com.smartdevicelink.proxy.rpc.enums.MediaClockFormat;\r
+import com.smartdevicelink.util.DebugTool;\r
+/**\r
+ * Contains information about the display for the SMARTDEVICELINK system to which the application is currently connected.\r
+  * <p><b> Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>displayType</td>\r
+ *                     <td>DisplayType</td>\r
+ *                     <td>The type of display\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>textField</td>\r
+ *                     <td>TextField[]</td>\r
+ *                     <td>An array of TextField structures, each of which describes a field in the HMI which the application can write to using operations such as <i>{@linkplain Show}</i>, <i>{@linkplain SetMediaClockTimer}</i>, etc. \r
+ *                                      This array of TextField structures identify all the text fields to which the application can write on the current display (identified by DisplayType ).\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ *     <tr>\r
+ *                     <td>mediaClockFormats</td>\r
+ *                     <td>MediaClockFormat[]</td>\r
+ *                     <td>An array of MediaClockFormat elements, defining the valid string formats used in specifying the contents of the media clock field</td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ *     <tr>\r
+ *                     <td>graphicSupported</td>\r
+ *                     <td>Boolean</td>\r
+ *                     <td>The display's persistent screen supports referencing a static or dynamic image.</td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ * </table>\r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class DisplayCapabilities extends RPCStruct {\r
+       /**\r
+        * Constructs a newly allocated DisplayCapabilities object\r
+        */\r
+    public DisplayCapabilities() { }\r
+    /**\r
+     * Constructs a newly allocated DisplayCapabilities object indicated by the Hashtable parameter\r
+     * @param hash The Hashtable to use\r
+     */    \r
+    public DisplayCapabilities(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * Get the type of display\r
+     * @return the type of display\r
+     */    \r
+    public DisplayType getDisplayType() {\r
+        Object obj = store.get(Names.displayType);\r
+        if (obj instanceof DisplayType) {\r
+            return (DisplayType) obj;\r
+        } else if (obj instanceof String) {\r
+            DisplayType theCode = null;\r
+            try {\r
+                theCode = DisplayType.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.displayType, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Set the type of display\r
+     * @param displayType the display type\r
+     */    \r
+    public void setDisplayType( DisplayType displayType ) {\r
+        if (displayType != null) {\r
+            store.put(Names.displayType, displayType );\r
+        }\r
+    }\r
+    /**\r
+     *Get an array of TextField structures, each of which describes a field in the HMI which the application can write to using operations such as <i>{@linkplain Show}</i>, <i>{@linkplain SetMediaClockTimer}</i>, etc. \r
+     *  This array of TextField structures identify all the text fields to which the application can write on the current display (identified by DisplayType ).\r
+     * @return the Vector of textFields\r
+     */    \r
+    public Vector<TextField> getTextFields() {\r
+        if (store.get(Names.textFields) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)store.get(Names.textFields);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof TextField) {\r
+                       return (Vector<TextField>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<TextField> newList = new Vector<TextField>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new TextField((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Set an array of TextField structures, each of which describes a field in the HMI which the application can write to using operations such as <i>{@linkplain Show}</i>, <i>{@linkplain SetMediaClockTimer}</i>, etc. \r
+     *  This array of TextField structures identify all the text fields to which the application can write on the current display (identified by DisplayType ).\r
+     * @param textFields the Vector of textFields\r
+     */    \r
+    public void setTextFields( Vector<TextField> textFields ) {\r
+        if (textFields != null) {\r
+            store.put(Names.textFields, textFields );\r
+        }\r
+    }\r
+    /**\r
+     * Get an array of MediaClockFormat elements, defining the valid string formats used in specifying the contents of the media clock field\r
+     * @return the Veotor of mediaClockFormat\r
+     */    \r
+    public Vector<MediaClockFormat> getMediaClockFormats() {\r
+        if (store.get(Names.mediaClockFormats) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)store.get(Names.mediaClockFormats);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof MediaClockFormat) {\r
+                       return (Vector<MediaClockFormat>) list;\r
+                   } else if (obj instanceof String) {\r
+                       Vector<MediaClockFormat> newList = new Vector<MediaClockFormat>();\r
+                       for (Object hashObj : list) {\r
+                           String strFormat = (String)hashObj;\r
+                           MediaClockFormat toAdd = null;\r
+                           try {\r
+                               toAdd = MediaClockFormat.valueForString(strFormat);\r
+                           } catch (Exception e) {\r
+                               DebugTool.logError("Failed to parse MediaClockFormat from " + getClass().getSimpleName() + "." + Names.mediaClockFormats, e);\r
+                           }\r
+                           if (toAdd != null) {\r
+                               newList.add(toAdd);\r
+                           }\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Set an array of MediaClockFormat elements, defining the valid string formats used in specifying the contents of the media clock field\r
+     * @param mediaClockFormats the Vector of MediaClockFormat\r
+     */    \r
+    public void setMediaClockFormats( Vector<MediaClockFormat> mediaClockFormats ) {\r
+        if (mediaClockFormats != null) {\r
+            store.put(Names.mediaClockFormats, mediaClockFormats );\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * set the display's persistent screen supports.\r
+     * @param graphicSupported\r
+     * @since SmartDeviceLink 2.0\r
+     */\r
+    public void setGraphicSupported(Boolean graphicSupported) {\r
+       if (graphicSupported != null) {\r
+               store.put(Names.graphicSupported, graphicSupported);\r
+       } else {\r
+               store.remove(Names.graphicSupported);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * Get the display's persistent screen supports.\r
+     * @return Boolean get the value of graphicSupported\r
+     * @since SmartDeviceLink 2.0\r
+     */\r
+    public Boolean getGraphicSupported() {\r
+       return (Boolean) store.get(Names.graphicSupported);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/EVInfo.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/EVInfo.java
new file mode 100755 (executable)
index 0000000..ae09e0f
--- /dev/null
@@ -0,0 +1,69 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.MaintenanceModeStatus;\r
+import com.smartdevicelink.proxy.rpc.enums.VehicleDataActiveStatus;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+public class EVInfo extends RPCStruct {\r
+\r
+    public EVInfo() {}\r
+    public EVInfo(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public void setElectricFuelConsumption(Double electricFuelConsumption) {\r
+        if (electricFuelConsumption != null) {\r
+               store.put(Names.electricFuelConsumption, electricFuelConsumption);\r
+        } else {\r
+               store.remove(Names.electricFuelConsumption);\r
+        }\r
+    }\r
+    public Double getElectricFuelConsumption() {\r
+        return (Double) store.get(Names.electricFuelConsumption);\r
+    }\r
+    public void setStateOfCharge(Double stateOfCharge) {\r
+        if (stateOfCharge != null) {\r
+               store.put(Names.stateOfCharge, stateOfCharge);\r
+        } else {\r
+               store.remove(Names.stateOfCharge);\r
+        }\r
+    }\r
+    public Double getStateOfCharge() {\r
+        return (Double) store.get(Names.stateOfCharge);\r
+    }\r
+    public void setFuelMaintenanceMode(MaintenanceModeStatus fuelMaintenanceMode) {\r
+        if (fuelMaintenanceMode != null) {\r
+               store.put(Names.fuelMaintenanceMode, fuelMaintenanceMode);\r
+        } else {\r
+               store.remove(Names.fuelMaintenanceMode);\r
+        }\r
+    }\r
+    public MaintenanceModeStatus getFuelMaintenanceMode() {\r
+        Object obj = store.get(Names.fuelMaintenanceMode);\r
+        if (obj instanceof MaintenanceModeStatus) {\r
+            return (MaintenanceModeStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               MaintenanceModeStatus theCode = null;\r
+            try {\r
+                theCode = MaintenanceModeStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.fuelMaintenanceMode, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setDistanceToEmpty(Double distanceToEmpty) {\r
+        if (distanceToEmpty != null) {\r
+               store.put(Names.distanceToEmpty, distanceToEmpty);\r
+        } else {\r
+               store.remove(Names.distanceToEmpty);\r
+        }\r
+    }\r
+    public Double getDistanceToEmpty() {\r
+        return (Double) store.get(Names.distanceToEmpty);\r
+    }\r
+}
\ No newline at end of file
index 6bf9ced..ee3ffa8 100755 (executable)
@@ -1,38 +1,38 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-import java.util.Vector;
-
-import com.smartdevicelink.proxy.RPCRequest;
-import com.smartdevicelink.proxy.constants.Names;
-
-public class EncodedSyncPData extends RPCRequest {
-       public EncodedSyncPData() {
-        super("EncodedSyncPData");
-    }
-    
-    public EncodedSyncPData(Hashtable hash) {
-        super(hash);
-    }
-    
-    public Vector<String> getData() {
-        if (parameters.get(Names.data) instanceof Vector<?>) {
-               Vector<?> list = (Vector<?>)parameters.get(Names.data);
-               if (list != null && list.size()>0) {
-                       Object obj = list.get(0);
-                       if (obj instanceof String) {
-                               return (Vector<String>) list;
-                       }
-               }
-        }
-       return null;
-    }
-    public void setData( Vector<String> data ) {
-       if ( data!= null) {
-               parameters.put(Names.data, data );
-       }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+\r
+public class EncodedSyncPData extends RPCRequest {\r
+\r
+       public EncodedSyncPData() {\r
+        super("EncodedSyncPData");\r
+    }\r
+   \r
+    public EncodedSyncPData(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+  \r
+    public Vector<String> getData() {\r
+        if (parameters.get(Names.data) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.data);\r
+               if (list != null && list.size()>0) {\r
+                       Object obj = list.get(0);\r
+                       if (obj instanceof String) {\r
+                               return (Vector<String>) list;\r
+                       }\r
+               }\r
+        }\r
+       return null;\r
+    }\r
+   \r
+    public void setData( Vector<String> data ) {\r
+       if ( data!= null) {\r
+               parameters.put(Names.data, data );\r
+       }\r
+    }\r
+}\r
index 060b3df..6d173f4 100755 (executable)
@@ -1,17 +1,15 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCResponse;
-
-public class EncodedSyncPDataResponse  extends RPCResponse {
-       public EncodedSyncPDataResponse() {
-        super("EncodedSyncPData");
-    }
-    public EncodedSyncPDataResponse(Hashtable hash) {
-        super(hash);
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+\r
+public class EncodedSyncPDataResponse  extends RPCResponse {\r
+       public EncodedSyncPDataResponse() {\r
+        super("EncodedSyncPData");\r
+    }\r
+    public EncodedSyncPDataResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/EndAudioPassThru.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/EndAudioPassThru.java
new file mode 100755 (executable)
index 0000000..a317c47
--- /dev/null
@@ -0,0 +1,37 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+\r
+/**\r
+ * When this request is invoked, the audio capture stops\r
+ * <p>\r
+ * Function Group: AudioPassThru\r
+ * <p>\r
+ * <b>HMILevel needs to be FULL, LIMITED or BACKGROUND</b>\r
+ * </p>\r
+ * @since SmartDeviceLink 2.0\r
+ * @see PerformAudioPassThru\r
+ */\r
+public class EndAudioPassThru extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new EndAudioPassThru object\r
+        */\r
+    public EndAudioPassThru() {\r
+        super("EndAudioPassThru");\r
+    }\r
+    \r
+    /**\r
+        * Constructs a new EndAudioPassThru object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+     */\r
+    public EndAudioPassThru(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/EndAudioPassThruResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/EndAudioPassThruResponse.java
new file mode 100755 (executable)
index 0000000..4cb1010
--- /dev/null
@@ -0,0 +1,23 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * End Audio Pass Thru Response is sent, when EndAudioPassThru has been called\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class EndAudioPassThruResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new EndAudioPassThruResponse object\r
+        */\r
+    public EndAudioPassThruResponse() {\r
+        super("EndAudioPassThru");\r
+    }\r
+    public EndAudioPassThruResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/FuelEconomyInformation.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/FuelEconomyInformation.java
new file mode 100755 (executable)
index 0000000..c36f8b7
--- /dev/null
@@ -0,0 +1,54 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+public class FuelEconomyInformation extends RPCStruct {\r
+\r
+    public FuelEconomyInformation() { }\r
+    public FuelEconomyInformation(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public void setFuelEconomySinceLastReset(Double fuelEconomySinceLastReset) {\r
+        if (fuelEconomySinceLastReset != null) {\r
+               store.put(Names.fuelEconomySinceLastReset, fuelEconomySinceLastReset);\r
+        } else {\r
+               store.remove(Names.fuelEconomySinceLastReset);\r
+        }\r
+    }\r
+    public Double getFuelEconomySinceLastReset() {\r
+        return (Double) store.get(Names.fuelEconomySinceLastReset);\r
+    }\r
+    public void setCurrentTripFuelEconomy(Double currentTripFuelEconomy) {\r
+        if (currentTripFuelEconomy != null) {\r
+               store.put(Names.currentTripFuelEconomy, currentTripFuelEconomy);\r
+        } else {\r
+               store.remove(Names.currentTripFuelEconomy);\r
+        }\r
+    }\r
+    public Double getCurrentTripFuelEconomy() {\r
+        return (Double) store.get(Names.currentTripFuelEconomy);\r
+    }\r
+    public void setAverageTripFuelEconomy(Double averageTripFuelEconomy) {\r
+        if (averageTripFuelEconomy != null) {\r
+               store.put(Names.averageTripFuelEconomy, averageTripFuelEconomy);\r
+        } else {\r
+               store.remove(Names.averageTripFuelEconomy);\r
+        }\r
+    }\r
+    public Double getAverageTripFuelEconomy() {\r
+        return (Double) store.get(Names.averageTripFuelEconomy);\r
+    }\r
+    public void setCurrentCycleFuelEconomy(Double currentCycleFuelEconomy) {\r
+        if (currentCycleFuelEconomy != null) {\r
+               store.put(Names.currentCycleFuelEconomy, currentCycleFuelEconomy);\r
+        } else {\r
+               store.remove(Names.currentCycleFuelEconomy);\r
+        }\r
+    }\r
+    public Double getCurrentCycleFuelEconomy() {\r
+        return (Double) store.get(Names.currentCycleFuelEconomy);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/GPSData.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/GPSData.java
new file mode 100755 (executable)
index 0000000..1865a7e
--- /dev/null
@@ -0,0 +1,524 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.CompassDirection;\r
+import com.smartdevicelink.proxy.rpc.enums.Dimension;\r
+import com.smartdevicelink.proxy.rpc.enums.DisplayType;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Describes the GPS data. Not all data will be available on all carlines.\r
+ * <p><b>Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>longitudeDegrees</td>\r
+ *                     <td>Double</td>\r
+ *                     <td>Minvalue: - 180\r
+ *                                     <b>Maxvalue: 180\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>latitudeDegrees</td>\r
+ *                     <td>Double</td>\r
+ *                     <td>Minvalue: - 90<b>Maxvalue: 90\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>utcYear</td>\r
+ *                     <td>Integer</td>\r
+ *                     <td>Minvalue: 2010<b>Maxvalue: 2100\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>utcMonth</td>\r
+ *                     <td>Integer</td>\r
+ *                     <td>Minvalue: 1<b>Maxvalue: 12\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>utcDay</td>\r
+ *                     <td>Integer</td>\r
+ *                     <td>Minvalue: 1<b>Maxvalue: 31\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>utcHours</td>\r
+ *                     <td>Integer</td>\r
+ *                     <td>Minvalue: 1<b>Maxvalue: 23\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>utcMinutes</td>\r
+ *                     <td>Integer</td>\r
+ *                     <td>Minvalue: 1<b>Maxvalue: 59\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr> \r
+ *             <tr>\r
+ *                     <td>utcSeconds</td>\r
+ *                     <td>Integer</td>\r
+ *                     <td>Minvalue: 1<b>Maxvalue: 59\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr> \r
+ *             <tr>\r
+ *                     <td>pdop</td>\r
+ *                     <td>Integer</td>\r
+ *                     <td>Positional Dilution of Precision<b>Minvalue: 0<b>Maxvalue: 31\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr> \r
+ *             <tr>\r
+ *                     <td>hdop</td>\r
+ *                     <td>Integer</td>\r
+ *                     <td>Horizontal Dilution of Precision<b>Minvalue: 0<b>Maxvalue: 31\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr> \r
+ *             <tr>\r
+ *                     <td>vdop</td>\r
+ *                     <td>Integer</td>\r
+ *                     <td>Vertical  Dilution of Precision<b>Minvalue: 0<b>Maxvalue: 31\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr> \r
+ *             <tr>\r
+ *                     <td>actual</td>\r
+ *                     <td>Boolean</td>\r
+ *                     <td>True, if coordinates are based on satellites.\r
+ *                                     False, if based on dead reckoning\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr> \r
+ *             <tr>\r
+ *                     <td>satellites</td>\r
+ *                     <td>Integer</td>\r
+ *                     <td>Number of satellites in view\r
+ *                                     <b>Minvalue: 0\r
+ *                                     <b>Maxvalue: 31\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr> \r
+ *             <tr>\r
+ *                     <td>altitude</td>\r
+ *                     <td>Integer</td>\r
+ *                     <td>Altitude in meters\r
+ *                                     <b>Minvalue: -10000\r
+ *                                     <b>Maxvalue: 10000\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr> \r
+ *             <tr>\r
+ *                     <td>heading</td>\r
+ *                     <td>Double</td>\r
+ *                     <td>The heading. North is 0, East is 90, etc.\r
+ *                                     <b>Minvalue: 0\r
+ *                                     <b>Maxvalue: 359.99\r
+ *                                     <b>Resolution is 0.01\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr> \r
+ *             <tr>\r
+ *                     <td>speed</td>\r
+ *                     <td>Integer</td>\r
+ *                     <td>The speed in KPH\r
+ *                                     <b>Minvalue: 0\r
+ *                                     <b>Maxvalue: 400\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr> \r
+ *  </table>\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class GPSData extends RPCStruct {\r
+\r
+       /**\r
+        * Constructs a newly allocated GPSData object\r
+        */\r
+    public GPSData() { }\r
+    \r
+    /**\r
+     * Constructs a newly allocated GPSData object indicated by the Hashtable parameter \r
+     * @param hash The Hashtable to use\r
+     */    \r
+    public GPSData(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    \r
+    /**\r
+     * set longitude degrees\r
+     * @param longitudeDegrees\r
+     */\r
+    public void setLongitudeDegrees(Double longitudeDegrees) {\r
+       if (longitudeDegrees != null) {\r
+               store.put(Names.longitudeDegrees, longitudeDegrees);\r
+       } else {\r
+               store.remove(Names.longitudeDegrees);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get longitude degrees \r
+     * @return longitude degrees\r
+     */\r
+    public Double getLongitudeDegrees() {\r
+       return (Double) store.get(Names.longitudeDegrees);\r
+    }\r
+    \r
+    /**\r
+     * set latitude degrees\r
+     * @param latitudeDegrees latitude degrees\r
+     */\r
+    public void setLatitudeDegrees(Double latitudeDegrees) {\r
+       if (latitudeDegrees != null) {\r
+               store.put(Names.latitudeDegrees, latitudeDegrees);\r
+       } else {\r
+               store.remove(Names.latitudeDegrees);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get  latitude degrees\r
+     * @return latitude degrees\r
+     */\r
+    public Double getLatitudeDegrees() {\r
+       return (Double) store.get(Names.latitudeDegrees);\r
+    }\r
+    \r
+    /**\r
+     * set utc year\r
+     * @param utcYear utc year\r
+     */\r
+    public void setUtcYear(Integer utcYear) {\r
+       if (utcYear != null) {\r
+               store.put(Names.utcYear, utcYear);\r
+       } else {\r
+               store.remove(Names.utcYear);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get utc year\r
+     * @return utc year\r
+     */\r
+    public Integer getUtcYear() {\r
+       return (Integer) store.get(Names.utcYear);\r
+    }\r
+    \r
+    /**\r
+     * set utc month\r
+     * @param utcMonth utc month\r
+     */\r
+    public void setUtcMonth(Integer utcMonth) {\r
+       if (utcMonth != null) {\r
+               store.put(Names.utcMonth, utcMonth);\r
+       } else {\r
+               store.remove(Names.utcMonth);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get utc month\r
+     * @return utc month\r
+     */\r
+    public Integer getUtcMonth() {\r
+       return (Integer) store.get(Names.utcMonth);\r
+    }\r
+    \r
+    /**\r
+     * set utc day\r
+     * @param utcDay utc day\r
+     */\r
+    public void setUtcDay(Integer utcDay) {\r
+       if (utcDay != null) {\r
+               store.put(Names.utcDay, utcDay);\r
+       } else {\r
+               store.remove(Names.utcDay);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get utc day\r
+     * @return utc day\r
+     */\r
+    public Integer getUtcDay() {\r
+       return (Integer) store.get(Names.utcDay);\r
+    }\r
+    \r
+    /**\r
+     * set utc hours\r
+     * @param utcHours utc hours\r
+     */\r
+    public void setUtcHours(Integer utcHours) {\r
+       if (utcHours != null) {\r
+               store.put(Names.utcHours, utcHours);\r
+       } else {\r
+               store.remove(Names.utcHours);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get utc hours\r
+     * @return utc hours\r
+     */\r
+    public Integer getUtcHours() {\r
+       return (Integer) store.get(Names.utcHours);\r
+    }\r
+    \r
+    /**\r
+     * set utc minutes\r
+     * @param utcMinutes utc minutes\r
+     */\r
+    public void setUtcMinutes(Integer utcMinutes) {\r
+       if (utcMinutes != null) {\r
+               store.put(Names.utcMinutes, utcMinutes);\r
+       } else {\r
+               store.remove(Names.utcMinutes);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get utc minutes\r
+     * @return utc minutes\r
+     */\r
+    public Integer getUtcMinutes() {\r
+       return (Integer) store.get(Names.utcMinutes);\r
+    }\r
+    \r
+    /**\r
+     * set utc seconds\r
+     * @param utcSeconds utc seconds\r
+     */\r
+    public void setUtcSeconds(Integer utcSeconds) {\r
+       if (utcSeconds != null) {\r
+               store.put(Names.utcSeconds, utcSeconds);\r
+       } else {\r
+               store.remove(Names.utcSeconds);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get utc seconds\r
+     * @return utc seconds\r
+     */\r
+    public Integer getUtcSeconds() {\r
+       return (Integer) store.get(Names.utcSeconds);\r
+    }\r
+    public void setCompassDirection(CompassDirection compassDirection) {\r
+       if (compassDirection != null) {\r
+               store.put(Names.compassDirection, compassDirection);\r
+       } else {\r
+               store.remove(Names.compassDirection);\r
+       }\r
+    }\r
+    public CompassDirection getCompassDirection() {\r
+        Object obj = store.get(Names.compassDirection);\r
+        if (obj instanceof CompassDirection) {\r
+            return (CompassDirection) obj;\r
+        } else if (obj instanceof String) {\r
+               CompassDirection theCode = null;\r
+            try {\r
+                theCode = CompassDirection.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.compassDirection, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    \r
+    /**\r
+     * set the positional dilution of precision\r
+     * @param pdop the positional dilution of precision\r
+     */\r
+    public void setPdop(Double pdop) {\r
+       if (pdop != null) {\r
+               store.put(Names.pdop, pdop);\r
+       } else {\r
+               store.remove(Names.pdop);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get  the positional dilution of precision\r
+     */\r
+    public Double getPdop() {\r
+       return (Double) store.get(Names.pdop);\r
+    }\r
+    \r
+    /**\r
+     * set the horizontal dilution of precision\r
+     * @param hdop the horizontal dilution of precision\r
+     */\r
+    public void setHdop(Double hdop) {\r
+       if (hdop != null) {\r
+               store.put(Names.hdop, hdop);\r
+       } else {\r
+               store.remove(Names.hdop);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get  the horizontal dilution of precision\r
+     * @return the horizontal dilution of precision\r
+     */\r
+    public Double getHdop() {\r
+       return (Double) store.get(Names.hdop);\r
+    }\r
+    \r
+    /**\r
+     * set the vertical dilution of precision\r
+     * @param vdop the vertical dilution of precision\r
+     */\r
+    public void setVdop(Double vdop) {\r
+       if (vdop != null) {\r
+               store.put(Names.vdop, vdop);\r
+       } else {\r
+               store.remove(Names.vdop);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get  the vertical dilution of precision\r
+     * @return the vertical dilution of precision\r
+     */\r
+    public Double getVdop() {\r
+       return (Double) store.get(Names.vdop);\r
+    }\r
+    \r
+    /**\r
+     * set what coordinates based on \r
+     * @param actual True, if coordinates are based on satellites.False, if based on dead reckoning\r
+     */\r
+    public void setActual(Boolean actual) {\r
+       if (actual != null) {\r
+               store.put(Names.actual, actual);\r
+       } else {\r
+               store.remove(Names.actual);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get what coordinates based on \r
+     * @return True, if coordinates are based on satellites.False, if based on dead reckoning\r
+     */\r
+    public Boolean getActual() {\r
+       return (Boolean) store.get(Names.actual);\r
+    }\r
+    \r
+    /**\r
+     * set the number of satellites in view\r
+     * @param satellites the number of satellites in view\r
+     */\r
+    public void setSatellites(Integer satellites) {\r
+       if (satellites != null) {\r
+               store.put(Names.satellites, satellites);\r
+       } else {\r
+               store.remove(Names.satellites);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get  the number of satellites in view\r
+     * @return the number of satellites in view\r
+     */\r
+    public Integer getSatellites() {\r
+       return (Integer) store.get(Names.satellites);\r
+    }\r
+    public void setDimension(Dimension dimension) {\r
+       if (dimension != null) {\r
+               store.put(Names.dimension, dimension);\r
+       } else {\r
+               store.remove(Names.dimension);\r
+       }\r
+    }\r
+    public Dimension getDimension() {\r
+        Object obj = store.get(Names.dimension);\r
+        if (obj instanceof Dimension) {\r
+            return (Dimension) obj;\r
+        } else if (obj instanceof String) {\r
+               Dimension theCode = null;\r
+            try {\r
+                theCode = Dimension.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.dimension, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    \r
+    /**\r
+     * set altitude in meters\r
+     * @param altitude altitude in meters\r
+     */\r
+    public void setAltitude(Double altitude) {\r
+       if (altitude != null) {\r
+               store.put(Names.altitude, altitude);\r
+       } else {\r
+               store.remove(Names.altitude);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get altitude in meters\r
+     * @return altitude in meters\r
+     */\r
+    public Double getAltitude() {\r
+       return (Double) store.get(Names.altitude);\r
+    }\r
+    \r
+    /**\r
+     * set the heading.North is 0, East is 90, etc.\r
+     * @param heading the heading. \r
+     */\r
+    public void setHeading(Double heading) {\r
+       if (heading != null) {\r
+               store.put(Names.heading, heading);\r
+       } else {\r
+               store.remove(Names.heading);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get the heading\r
+     */\r
+    public Double getHeading() {\r
+       return (Double) store.get(Names.heading);\r
+    }\r
+    \r
+    /**\r
+     * set speed in KPH\r
+     * @param speed the speed\r
+     */\r
+    public void setSpeed(Double speed) {\r
+       if (speed != null) {\r
+               store.put(Names.speed, speed);\r
+       } else {\r
+               store.remove(Names.speed);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get the speed in KPH\r
+     * @return the speed in KPH\r
+     */\r
+    public Double getSpeed() {\r
+       return (Double) store.get(Names.speed);\r
+    }\r
+}\r
index 308f17d..55c29f8 100755 (executable)
@@ -1,18 +1,20 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCResponse;
-
-public class GenericResponse extends RPCResponse {
-
-    public GenericResponse() {
-        super("GenericResponse");
-    }
-    public GenericResponse(Hashtable hash) {
-        super(hash);
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Generic Response is sent, when the name of a received msg cannot be\r
+ * retrieved. Only used in case of an error. Currently, only resultCode\r
+ * INVALID_DATA is used.\r
+*/\r
+public class GenericResponse extends RPCResponse {\r
+\r
+    public GenericResponse() {\r
+        super("GenericResponse");\r
+    }\r
+    public GenericResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/GetDTCs.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/GetDTCs.java
new file mode 100755 (executable)
index 0000000..7b7b1a2
--- /dev/null
@@ -0,0 +1,73 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * This RPC allows to request diagnostic module trouble codes from a certain\r
+ * vehicle module\r
+ * <p>\r
+ * Function Group: ProprietaryData\r
+ * <p>\r
+ * <b>HMILevel needs to be FULL, LIMITED or BACKGROUND</b>\r
+ * <p>\r
+ */\r
+public class GetDTCs extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new GetDTCs object\r
+        */\r
+    public GetDTCs() {\r
+        super("GetDTCs");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new GetDTCs object indicated by the Hashtable parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public GetDTCs(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+\r
+       /**\r
+        * Sets a name of the module to receive the DTC form\r
+        * \r
+        * @param ecuName\r
+        *            an Integer value representing a name of the module to receive\r
+        *            the DTC form\r
+        *            <p>\r
+        *            <b>Notes: </b>Minvalue:0; Maxvalue:65535\r
+        */\r
+    public void setEcuName(Integer ecuName) {\r
+       if (ecuName != null) {\r
+               parameters.put(Names.ecuName, ecuName);\r
+       } else {\r
+               parameters.remove(Names.ecuName);\r
+       }\r
+    }\r
+\r
+       /**\r
+        * Gets a name of the module to receive the DTC form\r
+        * \r
+        * @return Integer -an Integer value representing a name of the module to\r
+        *         receive the DTC form\r
+        */\r
+    public Integer getEcuName() {\r
+       return (Integer) parameters.get(Names.ecuName);\r
+    }\r
+    public void setDtcMask(Integer dtcMask) {\r
+       if (dtcMask != null) {\r
+               parameters.put(Names.dtcMask, dtcMask);\r
+       } else {\r
+               parameters.remove(Names.dtcMask);\r
+       }\r
+    }\r
+    public Integer getDtcMask() {\r
+       return (Integer) parameters.get(Names.dtcMask);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/GetDTCsResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/GetDTCsResponse.java
new file mode 100755 (executable)
index 0000000..98e116e
--- /dev/null
@@ -0,0 +1,45 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.HMILevel;\r
+import com.smartdevicelink.proxy.rpc.enums.MediaClockFormat;\r
+import com.smartdevicelink.proxy.rpc.enums.VehicleDataResultCode;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Get DTCs Response is sent, when GetDTCs has been called\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class GetDTCsResponse extends RPCResponse {\r
+\r
+    public GetDTCsResponse() {\r
+        super("GetDTCs");\r
+    }\r
+    public GetDTCsResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public Vector<String> getDtc() {\r
+       if(parameters.get(Names.dtc) instanceof Vector<?>){\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.dtc);\r
+               if(list != null && list.size()>0){\r
+                       Object obj = list.get(0);\r
+                       if(obj instanceof String){\r
+                               return (Vector<String>) list;\r
+       }\r
+    }\r
+            }\r
+        return null;\r
+    }\r
+    public void setDtc(Vector<String> dtc) {\r
+        if (dtc != null) {\r
+            parameters.put(Names.dtc, dtc);\r
+        } else {\r
+               parameters.remove(Names.dtc);\r
+        }\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/GetVehicleData.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/GetVehicleData.java
new file mode 100755 (executable)
index 0000000..7d8668c
--- /dev/null
@@ -0,0 +1,381 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.HMILevel;\r
+import com.smartdevicelink.proxy.rpc.enums.VehicleDataType;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+public class GetVehicleData extends RPCRequest {\r
+\r
+    public GetVehicleData() {\r
+        super("GetVehicleData");\r
+    }\r
+    public GetVehicleData(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public void setGps(Boolean gps) {\r
+        if (gps != null) {\r
+            parameters.put(Names.gps, gps);\r
+        } else {\r
+               parameters.remove(Names.gps);\r
+        }\r
+    }\r
+    public Boolean getGps() {\r
+        return (Boolean) parameters.get(Names.gps);\r
+    }\r
+    public void setSpeed(Boolean speed) {\r
+        if (speed != null) {\r
+            parameters.put(Names.speed, speed);\r
+        } else {\r
+               parameters.remove(Names.speed);\r
+        }\r
+    }\r
+    public Boolean getSpeed() {\r
+        return (Boolean) parameters.get(Names.speed);\r
+    }\r
+    public void setRpm(Boolean rpm) {\r
+        if (rpm != null) {\r
+            parameters.put(Names.rpm, rpm);\r
+        } else {\r
+               parameters.remove(Names.rpm);\r
+        }\r
+    }\r
+    public Boolean getRpm() {\r
+        return (Boolean) parameters.get(Names.rpm);\r
+    }\r
+    public void setFuelLevel(Boolean fuelLevel) {\r
+        if (fuelLevel != null) {\r
+            parameters.put(Names.fuelLevel, fuelLevel);\r
+        } else {\r
+               parameters.remove(Names.fuelLevel);\r
+        }\r
+    }\r
+    public Boolean getFuelLevel() {\r
+        return (Boolean) parameters.get(Names.fuelLevel);\r
+    }\r
+    public void setFuelLevel_State(Boolean fuelLevel_State) {\r
+        if (fuelLevel_State != null) {\r
+            parameters.put(Names.fuelLevel_State, fuelLevel_State);\r
+        } else {\r
+               parameters.remove(Names.fuelLevel_State);\r
+        }\r
+    }\r
+    public Boolean getFuelLevel_State() {\r
+        return (Boolean) parameters.get(Names.fuelLevel_State);\r
+    }\r
+    public void setInstantFuelConsumption(Boolean instantFuelConsumption) {\r
+        if (instantFuelConsumption != null) {\r
+            parameters.put(Names.instantFuelConsumption, instantFuelConsumption);\r
+        } else {\r
+               parameters.remove(Names.instantFuelConsumption);\r
+        }\r
+    }\r
+    public Boolean getInstantFuelConsumption() {\r
+        return (Boolean) parameters.get(Names.instantFuelConsumption);\r
+    }\r
+    public void setExternalTemperature(Boolean externalTemperature) {\r
+        if (externalTemperature != null) {\r
+            parameters.put(Names.externalTemperature, externalTemperature);\r
+        } else {\r
+               parameters.remove(Names.externalTemperature);\r
+        }\r
+    }\r
+    public Boolean getExternalTemperature() {\r
+        return (Boolean) parameters.get(Names.externalTemperature);\r
+    }\r
+    \r
+    public void setVin(Boolean vin) {\r
+        if (vin != null) {\r
+            parameters.put(Names.vin, vin);\r
+        } else {\r
+               parameters.remove(Names.vin);\r
+        }\r
+    }\r
+    public Boolean getVin() {\r
+        return (Boolean) parameters.get(Names.vin);\r
+    }\r
+    \r
+    public void setPrndl(Boolean prndl) {\r
+        if (prndl != null) {\r
+            parameters.put(Names.prndl, prndl);\r
+        } else {\r
+               parameters.remove(Names.prndl);\r
+        }\r
+    }\r
+    public Boolean getPrndl() {\r
+        return (Boolean) parameters.get(Names.prndl);\r
+    }\r
+    public void setTirePressure(Boolean tirePressure) {\r
+        if (tirePressure != null) {\r
+            parameters.put(Names.tirePressure, tirePressure);\r
+        } else {\r
+               parameters.remove(Names.tirePressure);\r
+        }\r
+    }\r
+    public Boolean getTirePressure() {\r
+        return (Boolean) parameters.get(Names.tirePressure);\r
+    }\r
+    public void setOdometer(Boolean odometer) {\r
+        if (odometer != null) {\r
+            parameters.put(Names.odometer, odometer);\r
+        } else {\r
+               parameters.remove(Names.odometer);\r
+        }\r
+    }\r
+    public Boolean getOdometer() {\r
+        return (Boolean) parameters.get(Names.odometer);\r
+    }\r
+    public void setBeltStatus(Boolean beltStatus) {\r
+        if (beltStatus != null) {\r
+            parameters.put(Names.beltStatus, beltStatus);\r
+        } else {\r
+               parameters.remove(Names.beltStatus);\r
+        }\r
+    }\r
+    public Boolean getBeltStatus() {\r
+        return (Boolean) parameters.get(Names.beltStatus);\r
+    }\r
+    public void setBodyInformation(Boolean bodyInformation) {\r
+        if (bodyInformation != null) {\r
+            parameters.put(Names.bodyInformation, bodyInformation);\r
+        } else {\r
+               parameters.remove(Names.bodyInformation);\r
+        }\r
+    }\r
+    public Boolean getBodyInformation() {\r
+        return (Boolean) parameters.get(Names.bodyInformation);\r
+    }\r
+    public void setDeviceStatus(Boolean deviceStatus) {\r
+        if (deviceStatus != null) {\r
+            parameters.put(Names.deviceStatus, deviceStatus);\r
+        } else {\r
+               parameters.remove(Names.deviceStatus);\r
+        }\r
+    }\r
+    public Boolean getDeviceStatus() {\r
+        return (Boolean) parameters.get(Names.deviceStatus);\r
+    }\r
+    public void setDriverBraking(Boolean driverBraking) {\r
+        if (driverBraking != null) {\r
+            parameters.put(Names.driverBraking, driverBraking);\r
+        } else {\r
+               parameters.remove(Names.driverBraking);\r
+        }\r
+    }\r
+    public Boolean getDriverBraking() {\r
+        return (Boolean) parameters.get(Names.driverBraking);\r
+    }\r
+    public void setWiperStatus(Boolean wiperStatus) {\r
+        if (wiperStatus != null) {\r
+            parameters.put(Names.wiperStatus, wiperStatus);\r
+        } else {\r
+               parameters.remove(Names.wiperStatus);\r
+        }\r
+    }\r
+    public Boolean getWiperStatus() {\r
+        return (Boolean) parameters.get(Names.wiperStatus);\r
+    }\r
+    public void setFuelEconomy(Boolean fuelEconomy) {\r
+        if (fuelEconomy != null) {\r
+            parameters.put(Names.fuelEconomy, fuelEconomy);\r
+        } else {\r
+               parameters.remove(Names.fuelEconomy);\r
+        }\r
+    }\r
+    public Boolean getFuelEconomy() {\r
+        return (Boolean) parameters.get(Names.fuelEconomy);\r
+    }\r
+    public void setEngineOilLife(Boolean engineOilLife) {\r
+        if (engineOilLife != null) {\r
+            parameters.put(Names.engineOilLife, engineOilLife);\r
+        } else {\r
+               parameters.remove(Names.engineOilLife);\r
+        }\r
+    }\r
+    public Boolean getEngineOilLife() {\r
+        return (Boolean) parameters.get(Names.engineOilLife);\r
+    }\r
+    public void setHeadLampStatus(Boolean headLampStatus) {\r
+        if (headLampStatus != null) {\r
+            parameters.put(Names.headLampStatus, headLampStatus);\r
+        } else {\r
+               parameters.remove(Names.headLampStatus);\r
+        }\r
+    }\r
+    public Boolean getHeadLampStatus() {\r
+        return (Boolean) parameters.get(Names.headLampStatus);\r
+    }\r
+    public void setBatteryVoltage(Boolean batteryVoltage) {\r
+        if (batteryVoltage != null) {\r
+            parameters.put(Names.batteryVoltage, batteryVoltage);\r
+        } else {\r
+               parameters.remove(Names.batteryVoltage);\r
+        }\r
+    }\r
+    public Boolean getBatteryVoltage() {\r
+        return (Boolean) parameters.get(Names.batteryVoltage);\r
+    }\r
+    public void setBrakeTorque(Boolean brakeTorque) {\r
+        if (brakeTorque != null) {\r
+            parameters.put(Names.brakeTorque, brakeTorque);\r
+        } else {\r
+               parameters.remove(Names.brakeTorque);\r
+        }\r
+    }\r
+    public Boolean getBrakeTorque() {\r
+        return (Boolean) parameters.get(Names.brakeTorque);\r
+    }\r
+    public void setEngineTorque(Boolean engineTorque) {\r
+        if (engineTorque != null) {\r
+            parameters.put(Names.engineTorque, engineTorque);\r
+        } else {\r
+               parameters.remove(Names.engineTorque);\r
+        }\r
+    }\r
+    public Boolean getEngineTorque() {\r
+        return (Boolean) parameters.get(Names.engineTorque);\r
+    }\r
+    public void setTurboBoost(Boolean turboBoost) {\r
+        if (turboBoost != null) {\r
+            parameters.put(Names.turboBoost, turboBoost);\r
+        } else {\r
+               parameters.remove(Names.turboBoost);\r
+        }\r
+    }\r
+    public Boolean getTurboBoost() {\r
+        return (Boolean) parameters.get(Names.turboBoost);\r
+    }\r
+    public void setCoolantTemp(Boolean coolantTemp) {\r
+        if (coolantTemp != null) {\r
+            parameters.put(Names.coolantTemp, coolantTemp);\r
+        } else {\r
+               parameters.remove(Names.coolantTemp);\r
+        }\r
+    }\r
+    public Boolean getCoolantTemp() {\r
+        return (Boolean) parameters.get(Names.coolantTemp);\r
+    }\r
+    public void setAirFuelRatio(Boolean airFuelRatio) {\r
+        if (airFuelRatio != null) {\r
+            parameters.put(Names.airFuelRatio, airFuelRatio);\r
+        } else {\r
+               parameters.remove(Names.airFuelRatio);\r
+        }\r
+    }\r
+    public Boolean getAirFuelRatio() {\r
+        return (Boolean) parameters.get(Names.airFuelRatio);\r
+    }\r
+    public void setCoolingHeadTemp(Boolean coolingHeadTemp) {\r
+        if (coolingHeadTemp != null) {\r
+            parameters.put(Names.coolingHeadTemp, coolingHeadTemp);\r
+        } else {\r
+               parameters.remove(Names.coolingHeadTemp);\r
+        }\r
+    }\r
+    public Boolean getCoolingHeadTemp() {\r
+        return (Boolean) parameters.get(Names.coolingHeadTemp);\r
+    }\r
+    public void setOilTemp(Boolean oilTemp) {\r
+        if (oilTemp != null) {\r
+            parameters.put(Names.oilTemp, oilTemp);\r
+        } else {\r
+               parameters.remove(Names.oilTemp);\r
+        }\r
+    }\r
+    public Boolean getOilTemp() {\r
+        return (Boolean) parameters.get(Names.oilTemp);\r
+    }\r
+    public void setIntakeAirTemp(Boolean intakeAirTemp) {\r
+        if (intakeAirTemp != null) {\r
+            parameters.put(Names.intakeAirTemp, intakeAirTemp);\r
+        } else {\r
+               parameters.remove(Names.intakeAirTemp);\r
+        }\r
+    }\r
+    public Boolean getIntakeAirTemp() {\r
+        return (Boolean) parameters.get(Names.intakeAirTemp);\r
+    }\r
+    public void setGearShiftAdvice(Boolean gearShiftAdvice) {\r
+        if (gearShiftAdvice != null) {\r
+            parameters.put(Names.gearShiftAdvice, gearShiftAdvice);\r
+        } else {\r
+               parameters.remove(Names.gearShiftAdvice);\r
+        }\r
+    }\r
+    public Boolean getGearShiftAdvice() {\r
+        return (Boolean) parameters.get(Names.gearShiftAdvice);\r
+    }\r
+    public void setAcceleration(Boolean acceleration) {\r
+        if (acceleration != null) {\r
+            parameters.put(Names.acceleration, acceleration);\r
+        } else {\r
+               parameters.remove(Names.acceleration);\r
+        }\r
+    }\r
+    public Boolean getAcceleration() {\r
+        return (Boolean) parameters.get(Names.acceleration);\r
+    }\r
+    public void setAccPedalPosition(Boolean accPedalPosition) {\r
+        if (accPedalPosition != null) {\r
+            parameters.put(Names.accPedalPosition, accPedalPosition);\r
+        } else {\r
+               parameters.remove(Names.accPedalPosition);\r
+        }\r
+    }\r
+    public Boolean getAccPedalPosition() {\r
+        return (Boolean) parameters.get(Names.accPedalPosition);\r
+    }\r
+    public void setClutchPedalPosition(Boolean clutchPedalPosition) {\r
+        if (clutchPedalPosition != null) {\r
+            parameters.put(Names.clutchPedalPosition, clutchPedalPosition);\r
+        } else {\r
+               parameters.remove(Names.clutchPedalPosition);\r
+        }\r
+    }\r
+    public Boolean getClutchPedalPosition() {\r
+        return (Boolean) parameters.get(Names.clutchPedalPosition);\r
+    }\r
+    public void setReverseGearStatus(Boolean reverseGearStatus) {\r
+        if (reverseGearStatus != null) {\r
+            parameters.put(Names.reverseGearStatus, reverseGearStatus);\r
+        } else {\r
+               parameters.remove(Names.reverseGearStatus);\r
+        }\r
+    }\r
+    public Boolean getReverseGearStatus() {\r
+        return (Boolean) parameters.get(Names.reverseGearStatus);\r
+    }\r
+    public void setAccTorque(Boolean accTorque) {\r
+        if (accTorque != null) {\r
+            parameters.put(Names.accTorque, accTorque);\r
+        } else {\r
+               parameters.remove(Names.accTorque);\r
+        }\r
+    }\r
+    public Boolean getAccTorque() {\r
+        return (Boolean) parameters.get(Names.accTorque);\r
+    }\r
+    public void setEvInfo(Boolean evInfo) {\r
+        if (evInfo != null) {\r
+            parameters.put(Names.evInfo, evInfo);\r
+        } else {\r
+               parameters.remove(Names.evInfo);\r
+        }\r
+    }\r
+    public Boolean getEvInfo() {\r
+        return (Boolean) parameters.get(Names.evInfo);\r
+    }\r
+    public void setAmbientLightStatus(Boolean ambientLightStatus) {\r
+        if (ambientLightStatus != null) {\r
+            parameters.put(Names.ambientLightStatus, ambientLightStatus);\r
+        } else {\r
+               parameters.remove(Names.ambientLightStatus);\r
+        }\r
+    }\r
+    public Boolean getAmbientLightStatus() {\r
+        return (Boolean) parameters.get(Names.ambientLightStatus);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/GetVehicleDataResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/GetVehicleDataResponse.java
new file mode 100755 (executable)
index 0000000..13341ba
--- /dev/null
@@ -0,0 +1,550 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+\r
+import java.util.Hashtable;\r
+import java.util.Iterator;\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.AmbientLightStatus;\r
+import com.smartdevicelink.proxy.rpc.enums.ComponentVolumeStatus;\r
+import com.smartdevicelink.proxy.rpc.enums.GearShiftAdviceStatus;\r
+import com.smartdevicelink.proxy.rpc.enums.PRNDL;\r
+import com.smartdevicelink.proxy.rpc.enums.VehicleDataActiveStatus;\r
+import com.smartdevicelink.proxy.rpc.enums.VehicleDataEventStatus;\r
+import com.smartdevicelink.proxy.rpc.enums.WiperStatus;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+public class GetVehicleDataResponse extends RPCResponse {\r
+\r
+    public GetVehicleDataResponse() {\r
+        super("GetVehicleData");\r
+    }\r
+    public GetVehicleDataResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public void setGps(GPSData gps) {\r
+       if (gps != null) {\r
+               parameters.put(Names.gps, gps);\r
+       } else {\r
+               parameters.remove(Names.gps);\r
+       }\r
+    }\r
+    public GPSData getGps() {\r
+       Object obj = parameters.get(Names.gps);\r
+        if (obj instanceof GPSData) {\r
+            return (GPSData) obj;\r
+        } else {\r
+               GPSData theCode = null;\r
+            try {\r
+                theCode = new GPSData((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.gps, e);\r
+            }\r
+            return theCode;\r
+        }\r
+    }\r
+    public void setSpeed(Double speed) {\r
+       if (speed != null) {\r
+               parameters.put(Names.speed, speed);\r
+       } else {\r
+               parameters.remove(Names.speed);\r
+       }\r
+    }\r
+    public Double getSpeed() {\r
+       return (Double) parameters.get(Names.speed);\r
+    }\r
+    public void setRpm(Integer rpm) {\r
+       if (rpm != null) {\r
+               parameters.put(Names.rpm, rpm);\r
+       } else {\r
+               parameters.remove(Names.rpm);\r
+       }\r
+    }\r
+    public Integer getRpm() {\r
+       return (Integer) parameters.get(Names.rpm);\r
+    }\r
+    public void setFuelLevel(Double fuelLevel) {\r
+       if (fuelLevel != null) {\r
+               parameters.put(Names.fuelLevel, fuelLevel);\r
+       } else {\r
+               parameters.remove(Names.fuelLevel);\r
+       }\r
+    }\r
+    public Double getFuelLevel() {\r
+       return (Double) parameters.get(Names.fuelLevel);\r
+    }\r
+    public void setFuelLevel_State(ComponentVolumeStatus fuelLevel_State) {\r
+       if (fuelLevel_State != null) {\r
+               parameters.put(Names.fuelLevel_State, fuelLevel_State);\r
+       } else {\r
+               parameters.remove(Names.fuelLevel_State);\r
+       }\r
+    }\r
+    public ComponentVolumeStatus getFuelLevel_State() {\r
+        Object obj = parameters.get(Names.fuelLevel_State);\r
+        if (obj instanceof ComponentVolumeStatus) {\r
+            return (ComponentVolumeStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               ComponentVolumeStatus theCode = null;\r
+            try {\r
+                theCode = ComponentVolumeStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.fuelLevel_State, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setInstantFuelConsumption(Double instantFuelConsumption) {\r
+       if (instantFuelConsumption != null) {\r
+               parameters.put(Names.instantFuelConsumption, instantFuelConsumption);\r
+       } else {\r
+               parameters.remove(Names.instantFuelConsumption);\r
+       }\r
+    }\r
+    public Double getInstantFuelConsumption() {\r
+       return (Double) parameters.get(Names.instantFuelConsumption);\r
+    }\r
+    public void setExternalTemperature(Double externalTemperature) {\r
+       if (externalTemperature != null) {\r
+               parameters.put(Names.externalTemperature, externalTemperature);\r
+       } else {\r
+               parameters.remove(Names.externalTemperature);\r
+       }\r
+    }\r
+    public Double getExternalTemperature() {\r
+       return (Double) parameters.get(Names.externalTemperature);\r
+    }\r
+    public void setVin(String vin) {\r
+       if (vin != null) {\r
+               parameters.put(Names.vin, vin);\r
+       } else {\r
+               parameters.remove(Names.vin);\r
+       }\r
+    }\r
+    public String getVin() {\r
+       return (String) parameters.get(Names.vin);\r
+    }\r
+    public void setPrndl(PRNDL prndl) {\r
+       if (prndl != null) {\r
+               parameters.put(Names.prndl, prndl);\r
+       } else {\r
+               parameters.remove(Names.prndl);\r
+       }\r
+    }\r
+    public PRNDL getPrndl() {\r
+        Object obj = parameters.get(Names.prndl);\r
+        if (obj instanceof PRNDL) {\r
+            return (PRNDL) obj;\r
+        } else if (obj instanceof String) {\r
+               PRNDL theCode = null;\r
+            try {\r
+                theCode = PRNDL.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.prndl, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setTirePressure(TireStatus tirePressure) {\r
+       if (tirePressure != null) {\r
+               parameters.put(Names.tirePressure, tirePressure);\r
+       } else {\r
+               parameters.remove(Names.tirePressure);\r
+       }\r
+    }\r
+    public TireStatus getTirePressure() {\r
+       Object obj = parameters.get(Names.tirePressure);\r
+        if (obj instanceof TireStatus) {\r
+            return (TireStatus) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new TireStatus((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.tirePressure, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setOdometer(Integer odometer) {\r
+       if (odometer != null) {\r
+               parameters.put(Names.odometer, odometer);\r
+       } else {\r
+               parameters.remove(Names.odometer);\r
+       }\r
+    }\r
+    public Integer getOdometer() {\r
+       return (Integer) parameters.get(Names.odometer);\r
+    }\r
+    public void setBeltStatus(BeltStatus beltStatus) {\r
+        if (beltStatus != null) {\r
+            parameters.put(Names.beltStatus, beltStatus);\r
+        } else {\r
+               parameters.remove(Names.beltStatus);\r
+        }\r
+    }\r
+    public BeltStatus getBeltStatus() {\r
+       Object obj = parameters.get(Names.beltStatus);\r
+        if (obj instanceof BeltStatus) {\r
+            return (BeltStatus) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new BeltStatus((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.beltStatus, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setBodyInformation(BodyInformation bodyInformation) {\r
+        if (bodyInformation != null) {\r
+            parameters.put(Names.bodyInformation, bodyInformation);\r
+        } else {\r
+               parameters.remove(Names.bodyInformation);\r
+        }\r
+    }\r
+    public BodyInformation getBodyInformation() {\r
+       Object obj = parameters.get(Names.bodyInformation);\r
+        if (obj instanceof BodyInformation) {\r
+            return (BodyInformation) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new BodyInformation((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.bodyInformation, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setDeviceStatus(DeviceStatus deviceStatus) {\r
+        if (deviceStatus != null) {\r
+            parameters.put(Names.deviceStatus, deviceStatus);\r
+        } else {\r
+               parameters.remove(Names.deviceStatus);\r
+        }\r
+    }\r
+    public DeviceStatus getDeviceStatus() {\r
+       Object obj = parameters.get(Names.deviceStatus);\r
+        if (obj instanceof DeviceStatus) {\r
+            return (DeviceStatus) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new DeviceStatus((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.deviceStatus, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setDriverBraking(VehicleDataEventStatus driverBraking) {\r
+        if (driverBraking != null) {\r
+            parameters.put(Names.driverBraking, driverBraking);\r
+        } else {\r
+               parameters.remove(Names.driverBraking);\r
+        }\r
+    }\r
+    public VehicleDataEventStatus getDriverBraking() {\r
+        Object obj = parameters.get(Names.driverBraking);\r
+        if (obj instanceof VehicleDataEventStatus) {\r
+            return (VehicleDataEventStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataEventStatus theCode = null;\r
+            try {\r
+                theCode = VehicleDataEventStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.driverBraking, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setWiperStatus(WiperStatus wiperStatus) {\r
+        if (wiperStatus != null) {\r
+            parameters.put(Names.wiperStatus, wiperStatus);\r
+        } else {\r
+               parameters.remove(Names.wiperStatus);\r
+        }\r
+    }\r
+    public WiperStatus getWiperStatus() {\r
+        Object obj = parameters.get(Names.wiperStatus);\r
+        if (obj instanceof WiperStatus) {\r
+            return (WiperStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               WiperStatus theCode = null;\r
+            try {\r
+                theCode = WiperStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.wiperStatus, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setFuelEconomy(FuelEconomyInformation fuelEconomy) {\r
+        if (fuelEconomy != null) {\r
+            parameters.put(Names.fuelEconomy, fuelEconomy);\r
+        } else {\r
+               parameters.remove(Names.fuelEconomy);\r
+        }\r
+    }\r
+    public FuelEconomyInformation getFuelEconomy() {\r
+       Object obj = parameters.get(Names.fuelEconomy);\r
+        if (obj instanceof FuelEconomyInformation) {\r
+            return (FuelEconomyInformation) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new FuelEconomyInformation((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.fuelEconomy, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setEngineOilLife(Integer engineOilLife) {\r
+        if (engineOilLife != null) {\r
+            parameters.put(Names.engineOilLife, engineOilLife);\r
+        } else {\r
+               parameters.remove(Names.engineOilLife);\r
+        }\r
+    }\r
+    public Integer getEngineOilLife() {\r
+       return (Integer) parameters.get(Names.engineOilLife);\r
+    }\r
+    public void setHeadLampStatus(HeadLampStatus headLampStatus) {\r
+        if (headLampStatus != null) {\r
+            parameters.put(Names.headLampStatus, headLampStatus);\r
+        } else {\r
+               parameters.remove(Names.headLampStatus);\r
+        }\r
+    }\r
+    public HeadLampStatus getHeadLampStatus() {\r
+       Object obj = parameters.get(Names.headLampStatus);\r
+        if (obj instanceof HeadLampStatus) {\r
+            return (HeadLampStatus) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new HeadLampStatus((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.headLampStatus, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setBatteryVoltage(Double batteryVoltage) {\r
+        if (batteryVoltage != null) {\r
+            parameters.put(Names.batteryVoltage, batteryVoltage);\r
+        } else {\r
+               parameters.remove(Names.batteryVoltage);\r
+        }\r
+    }\r
+    public Double getBatteryVoltage() {\r
+       return (Double) parameters.get(Names.batteryVoltage);\r
+    }\r
+    public void setBrakeTorque(Double brakeTorque) {\r
+        if (brakeTorque != null) {\r
+            parameters.put(Names.brakeTorque, brakeTorque);\r
+        } else {\r
+               parameters.remove(Names.brakeTorque);\r
+        }\r
+    }\r
+    public Double getBrakeTorque() {\r
+       return (Double) parameters.get(Names.brakeTorque);\r
+    }\r
+    public void setEngineTorque(Double engineTorque) {\r
+        if (engineTorque != null) {\r
+            parameters.put(Names.engineTorque, engineTorque);\r
+        } else {\r
+               parameters.remove(Names.engineTorque);\r
+        }\r
+    }\r
+    public Double getEngineTorque() {\r
+       return (Double) parameters.get(Names.engineTorque);\r
+    }\r
+    public void setTurboBoost(Double turboBoost) {\r
+        if (turboBoost != null) {\r
+            parameters.put(Names.turboBoost, turboBoost);\r
+        } else {\r
+               parameters.remove(Names.turboBoost);\r
+        }\r
+    }\r
+    public Double getTurboBoost() {\r
+       return (Double) parameters.get(Names.turboBoost);\r
+    }\r
+    public void setCoolantTemp(Double coolantTemp) {\r
+        if (coolantTemp != null) {\r
+            parameters.put(Names.coolantTemp, coolantTemp);\r
+        } else {\r
+               parameters.remove(Names.coolantTemp);\r
+        }\r
+    }\r
+    public Double getCoolantTemp() {\r
+       return (Double) parameters.get(Names.coolantTemp);\r
+    }\r
+    public void setAirFuelRatio(Double airFuelRatio) {\r
+        if (airFuelRatio != null) {\r
+            parameters.put(Names.airFuelRatio, airFuelRatio);\r
+        } else {\r
+               parameters.remove(Names.airFuelRatio);\r
+        }\r
+    }\r
+    public Double getAirFuelRatio() {\r
+       return (Double) parameters.get(Names.airFuelRatio);\r
+    }\r
+    public void setCoolingHeadTemp(Double coolingHeadTemp) {\r
+        if (coolingHeadTemp != null) {\r
+            parameters.put(Names.coolingHeadTemp, coolingHeadTemp);\r
+        } else {\r
+               parameters.remove(Names.coolingHeadTemp);\r
+        }\r
+    }\r
+    public Double getCoolingHeadTemp() {\r
+       return (Double) parameters.get(Names.coolingHeadTemp);\r
+    }\r
+    public void setOilTemp(Double oilTemp) {\r
+        if (oilTemp != null) {\r
+            parameters.put(Names.oilTemp, oilTemp);\r
+        } else {\r
+               parameters.remove(Names.oilTemp);\r
+        }\r
+    }\r
+    public Double getOilTemp() {\r
+       return (Double) parameters.get(Names.oilTemp);\r
+    }\r
+    public void setIntakeAirTemp(Double intakeAirTemp) {\r
+        if (intakeAirTemp != null) {\r
+            parameters.put(Names.intakeAirTemp, intakeAirTemp);\r
+        } else {\r
+               parameters.remove(Names.intakeAirTemp);\r
+        }\r
+    }\r
+    public Double getIntakeAirTemp() {\r
+       return (Double) parameters.get(Names.intakeAirTemp);\r
+    }\r
+    public void setGearShiftAdvice(GearShiftAdviceStatus gearShiftAdvice) {\r
+        if (gearShiftAdvice != null) {\r
+            parameters.put(Names.gearShiftAdvice, gearShiftAdvice);\r
+        } else {\r
+               parameters.remove(Names.gearShiftAdvice);\r
+        }\r
+    }\r
+    public GearShiftAdviceStatus getGearShiftAdvice() {\r
+        Object obj = parameters.get(Names.gearShiftAdvice);\r
+        if (obj instanceof GearShiftAdviceStatus) {\r
+            return (GearShiftAdviceStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               GearShiftAdviceStatus theCode = null;\r
+            try {\r
+                theCode = GearShiftAdviceStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.gearShiftAdvice, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setAcceleration(Double acceleration) {\r
+        if (acceleration != null) {\r
+            parameters.put(Names.acceleration, acceleration);\r
+        } else {\r
+               parameters.remove(Names.acceleration);\r
+        }\r
+    }\r
+    public Double getAcceleration() {\r
+       return (Double) parameters.get(Names.acceleration);\r
+    }\r
+    public void setAccPedalPosition(Double accPedalPosition) {\r
+        if (accPedalPosition != null) {\r
+            parameters.put(Names.accPedalPosition, accPedalPosition);\r
+        } else {\r
+               parameters.remove(Names.accPedalPosition);\r
+        }\r
+    }\r
+    public Double getAccPedalPosition() {\r
+       return (Double) parameters.get(Names.accPedalPosition);\r
+    }\r
+    public void setClutchPedalPosition(Double clutchPedalPosition) {\r
+        if (clutchPedalPosition != null) {\r
+            parameters.put(Names.clutchPedalPosition, clutchPedalPosition);\r
+        } else {\r
+               parameters.remove(Names.clutchPedalPosition);\r
+        }\r
+    }\r
+    public Double getClutchPedalPosition() {\r
+       return (Double) parameters.get(Names.clutchPedalPosition);\r
+    }\r
+    public void setReverseGearStatus(VehicleDataActiveStatus reverseGearStatus) {\r
+        if (reverseGearStatus != null) {\r
+            parameters.put(Names.reverseGearStatus, reverseGearStatus);\r
+        } else {\r
+               parameters.remove(Names.reverseGearStatus);\r
+        }\r
+    }\r
+    public VehicleDataActiveStatus getReverseGearStatus() {\r
+        Object obj = parameters.get(Names.reverseGearStatus);\r
+        if (obj instanceof VehicleDataActiveStatus) {\r
+            return (VehicleDataActiveStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataActiveStatus theCode = null;\r
+            try {\r
+                theCode = VehicleDataActiveStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.reverseGearStatus, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setAccTorque(Double accTorque) {\r
+        if (accTorque != null) {\r
+            parameters.put(Names.accTorque, accTorque);\r
+        } else {\r
+               parameters.remove(Names.accTorque);\r
+        }\r
+    }\r
+    public Double getAccTorque() {\r
+       return (Double) parameters.get(Names.accTorque);\r
+    }\r
+    public void setEvInfo(EVInfo evInfo) {\r
+        if (evInfo != null) {\r
+            parameters.put(Names.evInfo, evInfo);\r
+        } else {\r
+               parameters.remove(Names.evInfo);\r
+        }\r
+    }\r
+    public EVInfo getEvInfo() {\r
+       Object obj = parameters.get(Names.evInfo);\r
+        if (obj instanceof EVInfo) {\r
+            return (EVInfo) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new EVInfo((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.evInfo, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setAmbientLightStatus(AmbientLightStatus ambientLightStatus) {\r
+        if (ambientLightStatus != null) {\r
+            parameters.put(Names.ambientLightStatus, ambientLightStatus);\r
+        } else {\r
+               parameters.remove(Names.ambientLightStatus);\r
+        }\r
+    }\r
+    public AmbientLightStatus getAmbientLightStatus() {\r
+        Object obj = parameters.get(Names.ambientLightStatus);\r
+        if (obj instanceof AmbientLightStatus) {\r
+            return (AmbientLightStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               AmbientLightStatus theCode = null;\r
+            try {\r
+                theCode = AmbientLightStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.ambientLightStatus, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }    \r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/HMIPermissions.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/HMIPermissions.java
new file mode 100755 (executable)
index 0000000..3f9a734
--- /dev/null
@@ -0,0 +1,147 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.HMILevel;\r
+import com.smartdevicelink.util.DebugTool;\r
+/**\r
+ * Defining sets of HMI levels, which are permitted or prohibited for a given RPC.\r
+ * <p><b>Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>allowed</td>\r
+ *                     <td>HMILevel</td>\r
+ *                     <td>A set of all HMI levels that are permitted for this given RPC.\r
+ *                                     <ul>\r
+ *                                     <li>Min: 0</li>\r
+ *                                     <li>Max: 100</li>\r
+ *                                     </ul>\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>userDisallowed</td>\r
+ *                     <td>HMILevel</td>\r
+ *                     <td>A set of all HMI levels that are prohibated for this given RPC.\r
+ *                                     <ul>\r
+ *                                     <li>Min: 0</li>\r
+ *                                     <li>Max: 100</li>\r
+ *                                     </ul>\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *  </table>\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class HMIPermissions extends RPCStruct {\r
+\r
+       /**\r
+        * Constructs a newly allocated HMIPermissions object\r
+        */\r
+    public HMIPermissions() { }\r
+    \r
+    /**\r
+     * Constructs a newly allocated HMIPermissions object indicated by the Hashtable parameter\r
+     * @param hash The Hashtable to use\r
+     */\r
+    public HMIPermissions(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    \r
+    /**\r
+     * get a set of all HMI levels that are permitted for this given RPC.\r
+     * @return   a set of all HMI levels that are permitted for this given RPC\r
+     */\r
+    public Vector<HMILevel> getAllowed() {\r
+        if (store.get(Names.allowed) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)store.get(Names.allowed);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof HMILevel) {\r
+                       return (Vector<HMILevel>) list;\r
+                   } else if (obj instanceof String) {\r
+                       Vector<HMILevel> newList = new Vector<HMILevel>();\r
+                       for (Object hashObj : list) {\r
+                           String strFormat = (String)hashObj;\r
+                           HMILevel toAdd = null;\r
+                           try {\r
+                               toAdd = HMILevel.valueForString(strFormat);\r
+                           } catch (Exception e) {\r
+                               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.allowed, e);\r
+                           }\r
+                           if (toAdd != null) {\r
+                               newList.add(toAdd);\r
+                           }\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+    \r
+    /**\r
+     * set  HMI level that is permitted for this given RPC.\r
+     * @param allowed HMI level that is permitted for this given RPC\r
+     */\r
+    public void setAllowed(HMILevel allowed) {\r
+        if (allowed != null) {\r
+            store.put(Names.allowed, allowed);\r
+        } else {\r
+               store.remove(Names.allowed);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get a set of all HMI levels that are prohibited for this given RPC\r
+     * @return a set of all HMI levels that are prohibited for this given RPC\r
+     */\r
+    public Vector<HMILevel> getUserDisallowed() {\r
+        if (store.get(Names.userDisallowed) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)store.get(Names.userDisallowed);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof HMILevel) {\r
+                       return (Vector<HMILevel>) list;\r
+                   } else if (obj instanceof String) {\r
+                       Vector<HMILevel> newList = new Vector<HMILevel>();\r
+                       for (Object hashObj : list) {\r
+                           String strFormat = (String)hashObj;\r
+                           HMILevel toAdd = null;\r
+                           try {\r
+                               toAdd = HMILevel.valueForString(strFormat);\r
+                           } catch (Exception e) {\r
+                               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.userDisallowed, e);\r
+                           }\r
+                           if (toAdd != null) {\r
+                               newList.add(toAdd);\r
+                           }\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+    \r
+    /**\r
+     * set a set of all HMI levels that are prohibited for this given RPC\r
+     * @param userDisallowed  HMI level that is prohibited for this given RPC\r
+     */\r
+    public void setUserDisallowed(HMILevel userDisallowed) {\r
+        if (userDisallowed != null) {\r
+            store.put(Names.userDisallowed, userDisallowed);\r
+        } else {\r
+               store.remove(Names.userDisallowed);\r
+       }\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/HeadLampStatus.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/HeadLampStatus.java
new file mode 100755 (executable)
index 0000000..ab28604
--- /dev/null
@@ -0,0 +1,48 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.LightSwitchStatus;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+public class HeadLampStatus extends RPCStruct {\r
+\r
+    public HeadLampStatus() {}\r
+    public HeadLampStatus(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public void setLightSwitchStatus(LightSwitchStatus lightSwitchStatus) {\r
+        if (lightSwitchStatus != null) {\r
+            store.put(Names.lightSwitchStatus, lightSwitchStatus);\r
+        } else {\r
+               store.remove(Names.lightSwitchStatus);\r
+        }\r
+    }\r
+    public LightSwitchStatus getLightSwitchStatus() {\r
+        Object obj = store.get(Names.lightSwitchStatus);\r
+        if (obj instanceof LightSwitchStatus) {\r
+            return (LightSwitchStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               LightSwitchStatus theCode = null;\r
+            try {\r
+                theCode = LightSwitchStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.lightSwitchStatus, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setHighBeamsOn(Boolean highBeamsOn) {\r
+        if (highBeamsOn != null) {\r
+            store.put(Names.highBeamsOn, highBeamsOn);\r
+        } else {\r
+               store.remove(Names.highBeamsOn);\r
+        }\r
+    }\r
+    public Boolean getHighBeamsOn() {\r
+       return (Boolean) store.get(Names.highBeamsOn);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/Image.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/Image.java
new file mode 100755 (executable)
index 0000000..22ea8a8
--- /dev/null
@@ -0,0 +1,106 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.ImageType;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ *Specifies, which image shall be used, e.g. in Alerts or on Softbuttons provided the display supports it.\r
+ *<p><b>Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>value</td>\r
+ *                     <td>String</td>\r
+ *                     <td>Either the static hex icon value or the binary image file name identifier (sent by PutFile).\r
+ *                                     <ul>\r
+ *                                     <li>Min: 0</li>\r
+ *                                     <li>Max: 65535</li>\r
+ *                                     </ul>\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>imageType</td>\r
+ *                     <td>ImageType</td>\r
+ *                     <td>Describes, whether it is a static or dynamic image.</td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *  </table>\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class Image extends RPCStruct {\r
+\r
+       /**\r
+        * Constructs a newly allocated Image object\r
+        */\r
+    public Image() { }\r
+    \r
+    /**\r
+     * Constructs a newly allocated Image object indicated by the Hashtable parameter\r
+     * @param hash The Hashtable to use\r
+     */      \r
+    public Image(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    \r
+    /**\r
+     * set either the static hex icon value or the binary image file name identifier (sent by PutFile)\r
+     * @param value either the static hex icon value or the binary image file name identifier (sent by PutFile)\r
+     */\r
+    public void setValue(String value) {\r
+        if (value != null) {\r
+            store.put(Names.value, value);\r
+        } else {\r
+               store.remove(Names.value);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get either the static hex icon value or the binary image file name identifier (sent by PutFile)\r
+     * @return  either the static hex icon value or the binary image file name identifier (sent by PutFile)\r
+     */\r
+    public String getValue() {\r
+        return (String) store.get(Names.value);\r
+    }\r
+    \r
+    /**\r
+     * set the image type\r
+     * @param imageType whether it is a static or dynamic image\r
+     */\r
+    public void setImageType(ImageType imageType) {\r
+        if (imageType != null) {\r
+            store.put(Names.imageType, imageType);\r
+        } else {\r
+               store.remove(Names.imageType);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get image type\r
+     * @return the image type\r
+     */\r
+    public ImageType getImageType() {\r
+       Object obj = store.get(Names.imageType);\r
+        if (obj instanceof ImageType) {\r
+            return (ImageType) obj;\r
+        } else if (obj instanceof String) {\r
+               ImageType theCode = null;\r
+            try {\r
+                theCode = ImageType.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.imageType, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ListFiles.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ListFiles.java
new file mode 100755 (executable)
index 0000000..514bfdd
--- /dev/null
@@ -0,0 +1,33 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+\r
+/**\r
+ * Requests the current list of resident filenames for the registered app. Not\r
+ * supported on First generation SMARTDEVICELINK vehicles\r
+ * <p>\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class ListFiles extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new ListFiles object\r
+        */\r
+    public ListFiles() {\r
+        super("ListFiles");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new ListFiles object indicated by the Hashtable parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public ListFiles(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ListFilesResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ListFilesResponse.java
new file mode 100755 (executable)
index 0000000..6dfc5aa
--- /dev/null
@@ -0,0 +1,54 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * List Files Response is sent, when ListFiles has been called\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class ListFilesResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new ListFilesResponse object\r
+        */\r
+    public ListFilesResponse() {\r
+        super("ListFiles");\r
+    }\r
+    public ListFilesResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public void setFilenames(Vector<String> filenames) {\r
+        if (filenames != null) {\r
+            parameters.put(Names.filenames, filenames);\r
+        } else {\r
+               parameters.remove(Names.filenames);\r
+        }\r
+    }\r
+    public Vector<String> getFilenames() {\r
+        if (parameters.get(Names.filenames) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.filenames);\r
+               if (list != null && list.size()>0) {\r
+                       Object obj = list.get(0);\r
+                       if (obj instanceof String) {\r
+                               return (Vector<String>) list;\r
+                       }\r
+               }\r
+        }\r
+       return null;\r
+    }\r
+    public void setSpaceAvailable(Integer spaceAvailable) {\r
+        if (spaceAvailable != null) {\r
+            parameters.put(Names.spaceAvailable, spaceAvailable);\r
+        } else {\r
+               parameters.remove(Names.spaceAvailable);\r
+        }\r
+    }\r
+    public Integer getSpaceAvailable() {\r
+        return (Integer) parameters.get(Names.spaceAvailable);\r
+    }\r
+}
\ No newline at end of file
index 5612062..2d4235a 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCStruct;
-import com.smartdevicelink.proxy.constants.Names;
-
-public class MenuParams extends RPCStruct {
-
-    public MenuParams() { }
-    public MenuParams(Hashtable hash) {
-        super(hash);
-    }
-    public Integer getParentID() {
-        return (Integer) store.get( Names.parentID );
-    }
-    public void setParentID( Integer parentID ) {
-        if (parentID != null) {
-            store.put(Names.parentID, parentID );
-        }
-    }
-    public Integer getPosition() {
-        return (Integer) store.get( Names.position );
-    }
-    public void setPosition( Integer position ) {
-        if (position != null) {
-            store.put(Names.position, position );
-        }
-    }
-    public String getMenuName() {
-        return (String) store.get( Names.menuName );
-    }
-    public void setMenuName( String menuName ) {
-        if (menuName != null) {
-            store.put(Names.menuName, menuName );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+/**\r
+ * Used when adding a sub menu to an application menu or existing sub menu.\r
+ * <p><b> Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>parentID</td>\r
+ *                     <td>Int32</td>\r
+ *                     <td>The unique ID of an existing submenu to which a command will be added.\r
+ *                                     If this element is not provided, the command will be added to the top level of the Command Menu.\r
+ *                                     <ul>\r
+ *                                     <li>Min: 0</li>\r
+ *                                     <li>Max: 2000000000</li>\r
+ *                                     </ul>\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+  *            <tr>\r
+ *                     <td>position</td>\r
+ *                     <td>Int16</td>\r
+ *                     <td>Position within the items of the parent Command Menu. 0 will insert at the front, 1 will insert after the first existing element, etc. \r
+ *                                     Position of any submenu will always be located before the return and exit options.\r
+ *                                     <ul>\r
+ *                                             <li>Min Value: 0</li>\r
+ *                                             <li>Max Value: 1000</li>\r
+ *                                             <li>If position is greater or equal than the number of items in the parent Command Menu, the sub menu will be appended to the end of that Command Menu.</li>\r
+ *                                             <li>If this element is omitted, the entry will be added at the end of the parent menu.</li>\r
+ *                                     </ul>\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ *     <tr>\r
+ *                     <td>menuName</td>\r
+ *                     <td>String</td>\r
+ *                     <td>Text which appears in menu, representing this command.\r
+ *                             <ul>\r
+ *                                             <li>Min: 1</li>\r
+ *                                             <li>Max: 100</li>\r
+ *                                     </ul>\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ * </table>\r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class MenuParams extends RPCStruct {\r
+       /**\r
+        * Constructs a newly allocated MenuParams object\r
+        */\r
+    public MenuParams() { }\r
+    /**\r
+     * Constructs a newly allocated MenuParams object indicated by the Hashtable parameter\r
+     * @param hash The Hashtable to use\r
+     */    \r
+    public MenuParams(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * Get the unique ID of an existing submenu to which a command will be added.\r
+     * If this element is not provided, the command will be added to the top level of the Command Menu.\r
+     * @return parentID Min: 0 Max: 2000000000\r
+     */    \r
+    public Integer getParentID() {\r
+        return (Integer) store.get( Names.parentID );\r
+    }\r
+    /**\r
+     * Set the unique ID of an existing submenu to which a command will be added.\r
+     * If this element is not provided, the command will be added to the top level of the Command Menu.\r
+     * @param parentID Min: 0; Max: 2000000000\r
+     */    \r
+    public void setParentID( Integer parentID ) {\r
+        if (parentID != null) {\r
+            store.put(Names.parentID, parentID );\r
+        }\r
+    }\r
+    /**\r
+     * Get the position within the items of the parent Command Menu. 0 will insert at the front, 1 will insert after the first existing element, etc. \r
+     *         Position of any submenu will always be located before the return and exit options.\r
+     *                                         <ul>\r
+     *                                                 <li>Min Value: 0</li>\r
+     *                                                 <li>Max Value: 1000</li>\r
+     *                                                 <li>If position is greater or equal than the number of items in the parent Command Menu, the sub menu will be appended to the end of that Command Menu.</li>\r
+     *                                                 <li>If this element is omitted, the entry will be added at the end of the parent menu.</li>\r
+     *                                         </ul>\r
+     * @return  the position within the items of the parent Command Menu\r
+     */    \r
+    public Integer getPosition() {\r
+        return (Integer) store.get( Names.position );\r
+    }\r
+    /**\r
+     * Set the position within the items of the parent Command Menu. 0 will insert at the front, 1 will insert after the first existing element, etc. \r
+     *         Position of any submenu will always be located before the return and exit options.\r
+     *                                         <ul>\r
+     *                                                 <li>Min Value: 0</li>\r
+     *                                                 <li>Max Value: 1000</li>\r
+     *                                                 <li>If position is greater or equal than the number of items in the parent Command Menu, the sub menu will be appended to the end of that Command Menu.</li>\r
+     *                                                 <li>If this element is omitted, the entry will be added at the end of the parent menu.</li>\r
+     *                                         </ul>\r
+     * @param position Mix: 0 Max: 1000\r
+     */    \r
+    public void setPosition( Integer position ) {\r
+        if (position != null) {\r
+            store.put(Names.position, position );\r
+        }\r
+    }\r
+    /**\r
+     * Get the text which appears in menu, representing this command.\r
+     *                         <ul>\r
+     *                                                 <li>Min: 1</li>\r
+     *                                                 <li>Max: 100</li>\r
+     *                                         </ul>\r
+     * @return menuName the menu name\r
+     */\r
+    \r
+    public String getMenuName() {\r
+        return (String) store.get( Names.menuName );\r
+    }\r
+    /**\r
+     * Set text which appears in menu, representing this command.\r
+     *                         <ul>\r
+     *                                                 <li>Min: 1</li>\r
+     *                                                 <li>Max: 100</li>\r
+     *                                         </ul>\r
+     * @param menuName the menu name\r
+     */\r
+    \r
+    public void setMenuName( String menuName ) {\r
+        if (menuName != null) {\r
+            store.put(Names.menuName, menuName );\r
+        }\r
+    }\r
+}\r
index 1083638..a1cb45d 100755 (executable)
@@ -1,41 +1,86 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCNotification;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.AppInterfaceUnregisteredReason;
-import com.smartdevicelink.util.DebugTool;
-
-public class OnAppInterfaceUnregistered extends RPCNotification {
-
-    public OnAppInterfaceUnregistered() {
-        super("OnAppInterfaceUnregistered");
-    }
-    public OnAppInterfaceUnregistered(Hashtable hash) {
-        super(hash);
-    }
-    public AppInterfaceUnregisteredReason getReason() {
-        Object obj = parameters.get(Names.reason);
-        if (obj instanceof AppInterfaceUnregisteredReason) {
-            return (AppInterfaceUnregisteredReason) obj;
-        } else if (obj instanceof String) {
-            AppInterfaceUnregisteredReason theCode = null;
-            try {
-                theCode = AppInterfaceUnregisteredReason.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.reason, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setReason( AppInterfaceUnregisteredReason reason ) {
-        if (reason != null) {
-            parameters.put(Names.reason, reason );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCNotification;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.AppInterfaceUnregisteredReason;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * <p>Notifies an application that its interface registration has been terminated. This means that all SMARTDEVICELINK resources \r
+ * associated with the application are discarded, including the Command Menu, Choice Sets, button subscriptions, etc.</p>\r
+ * For more information about SMARTDEVICELINK resources related to an interface registration, see {@linkplain RegisterAppInterface}.\r
+ * <p></p>\r
+ * <b>HMI Status Requirements:</b>\r
+ * <ul>\r
+ * HMILevel: \r
+ * <ul><li>Any</li></ul>\r
+ * AudioStreamingState: \r
+ * <ul><li>Any</li></ul>\r
+ * SystemContext: \r
+ * <ul><li>Any</li></ul>\r
+ * </ul>\r
+ * <p>\r
+ * <b>Parameter List:</b>\r
+ * <table  border="1" rules="all">\r
+ * <tr>\r
+ * <th>Name</th>\r
+ * <th>Type</th>\r
+ * <th>Description</th>\r
+ * <th>Applink Ver Available</th>\r
+ * </tr>\r
+ * <tr>\r
+ * <td>reason</td>\r
+ * <td>{@linkplain AppInterfaceUnregisteredReason}</td>\r
+ * <td>The reason the application's interface registration was terminated</td>\r
+ * <td>SmartDeviceLink 1.0</td>\r
+ * </tr>\r
+ * </table>\r
+ * </p>\r
+ * @since SmartDeviceLink 1.0\r
+ * @see RegisterAppInterface\r
+ */\r
+public class OnAppInterfaceUnregistered extends RPCNotification {\r
+       /**\r
+       *Constructs a newly allocated OnAppInterfaceUnregistered object\r
+       */ \r
+    public OnAppInterfaceUnregistered() {\r
+        super("OnAppInterfaceUnregistered");\r
+    }\r
+    /**\r
+    *<p>Constructs a newly allocated OnAppInterfaceUnregistered object indicated by the Hashtable parameter</p>\r
+    *@param hash The Hashtable to use\r
+    */    \r
+    public OnAppInterfaceUnregistered(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * <p>Get the reason the registration was terminated</p>\r
+     * @return {@linkplain AppInterfaceUnregisteredReason} the reason the application's interface registration was terminated\r
+     */    \r
+    public AppInterfaceUnregisteredReason getReason() {\r
+        Object obj = parameters.get(Names.reason);\r
+        if (obj instanceof AppInterfaceUnregisteredReason) {\r
+            return (AppInterfaceUnregisteredReason) obj;\r
+        } else if (obj instanceof String) {\r
+            AppInterfaceUnregisteredReason theCode = null;\r
+            try {\r
+                theCode = AppInterfaceUnregisteredReason.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.reason, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * <p>Set the reason application's interface was terminated</p>\r
+     * @param reason The reason application's interface registration was terminated\r
+     */    \r
+    public void setReason( AppInterfaceUnregisteredReason reason ) {\r
+        if (reason != null) {\r
+            parameters.put(Names.reason, reason );\r
+        }\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnAudioPassThru.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnAudioPassThru.java
new file mode 100755 (executable)
index 0000000..776f437
--- /dev/null
@@ -0,0 +1,67 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCNotification;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Binary data is in binary part of hybrid msg.\r
+ *  <p>\r
+ * </p>\r
+ * <b>HMI Status Requirements:</b>\r
+ * <ul>\r
+ * HMILevel:\r
+ * <ul>\r
+ * <li>BACKGROUND, FULL, LIMITED</li>\r
+ * </ul>\r
+ * AudioStreamingState:\r
+ * <ul>\r
+ * <li>TBD</li>\r
+ * </ul>\r
+ * SystemContext:\r
+ * <ul>\r
+ * <li>TBD</li>\r
+ * </ul>\r
+ * </ul>\r
+ * <p>\r
+ * <b>Parameter List:</b>\r
+ * <table border="1" rules="all">\r
+ * <tr>\r
+ * <th>Name</th>\r
+ * <th>Type</th>\r
+ * <th>Description</th>\r
+ * <th>Req</th>\r
+ * <th>Notes</th>\r
+ * <th>Applink Ver Available</th>\r
+ * </tr>\r
+\r
+ * </table>\r
+ * </p>\r
+ *\r
+ */\r
+public class OnAudioPassThru extends RPCNotification {\r
+       /**\r
+       *Constructs a newly allocated OnCommand object\r
+       */    \r
+    public OnAudioPassThru() {\r
+        super("OnAudioPassThru");\r
+    }\r
+    /**\r
+     *<p>Constructs a newly allocated OnAudioPassThru object indicated by the Hashtable parameter</p>\r
+     *@param hash The Hashtable to use\r
+     */ \r
+    public OnAudioPassThru(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public void setAPTData(byte[] aptData) {\r
+        if (aptData != null) {\r
+            store.put(Names.bulkData, aptData);\r
+        } else {\r
+               store.remove(Names.bulkData);\r
+        }\r
+    }\r
+    public byte[] getAPTData() {\r
+        return (byte[]) store.get(Names.bulkData);\r
+    }\r
+}\r
index 24411e0..026e1e6 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCNotification;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.ButtonEventMode;
-import com.smartdevicelink.proxy.rpc.enums.ButtonName;
-import com.smartdevicelink.util.DebugTool;
-
-public class OnButtonEvent extends RPCNotification {
-
-    public OnButtonEvent() {
-        super("OnButtonEvent");
-    }
-    public OnButtonEvent(Hashtable hash) {
-        super(hash);
-    }
-    public ButtonName getButtonName() {
-        Object obj = parameters.get(Names.buttonName);
-        if (obj instanceof ButtonName) {
-            return (ButtonName) obj;
-        } else if (obj instanceof String) {
-            ButtonName theCode = null;
-            try {
-                theCode = ButtonName.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.buttonName, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setButtonName( ButtonName buttonName ) {
-        if (buttonName != null) {
-            parameters.put(Names.buttonName, buttonName );
-        }
-    }
-    public ButtonEventMode getButtonEventMode() {
-        Object obj = parameters.get(Names.buttonEventMode);
-        if (obj instanceof ButtonEventMode) {
-            return (ButtonEventMode) obj;
-        } else if (obj instanceof String) {
-            ButtonEventMode theCode = null;
-            try {
-                theCode = ButtonEventMode.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.buttonEventMode, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setButtonEventMode( ButtonEventMode buttonEventMode ) {
-        if (buttonEventMode != null) {
-            parameters.put(Names.buttonEventMode, buttonEventMode );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCNotification;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.ButtonEventMode;\r
+import com.smartdevicelink.proxy.rpc.enums.ButtonName;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Notifies application that user has depressed or released a button to which\r
+ * the application has subscribed.</br> Further information about button events\r
+ * and button-presses can be found at {@linkplain SubscribeButton}.\r
+ * <p>\r
+ * </p>\r
+ * <b>HMI Status Requirements:</b>\r
+ * <ul>\r
+ * HMILevel:\r
+ * <ul>\r
+ * <li>The application will receive OnButtonEvent notifications for all\r
+ * subscribed buttons when HMILevel is FULL.</li>\r
+ * <li>The application will receive OnButtonEvent notifications for subscribed\r
+ * media buttons when HMILevel is LIMITED.</li>\r
+ * <li>Media buttons include SEEKLEFT, SEEKRIGHT, TUNEUP, TUNEDOWN, and\r
+ * PRESET_0-PRESET_9.</li>\r
+ * <li>The application will not receive OnButtonEvent notification when HMILevel\r
+ * is BACKGROUND.</li>\r
+ * </ul>\r
+ * AudioStreamingState:\r
+ * <ul>\r
+ * <li> Any </li>\r
+ * </ul>\r
+ * SystemContext:\r
+ * <ul>\r
+ * <li>MAIN, VR. In MENU, only PRESET buttons. In VR, pressing any subscribable\r
+ * button will cancel VR.</li>\r
+ * </ul>\r
+ * </ul>\r
+ * <p>\r
+ * <b>Parameter List:</b>\r
+ * <table  border="1" rules="all">\r
+ * <tr>\r
+ * <th>Name</th>\r
+ * <th>Type</th>\r
+ * <th>Description</th>\r
+ * <th>Req</th>\r
+ * <th>Notes</th>\r
+ * <th>Applink Ver Available</th>\r
+ * </tr>\r
+ * <tr>\r
+ * <td>buttonName</td>\r
+ * <td>{@linkplain ButtonName}</td>\r
+ * <td>Name of the button which triggered this event</td>\r
+ * <td></td>\r
+ * <td></td>\r
+ * <td>SmartDeviceLink 1.0</td>\r
+ * </tr>\r
+ * <tr>\r
+ * <td>buttonEventMode</td>\r
+ * <td>{@linkplain ButtonEventMode}</td>\r
+ * <td>Indicats button was depressed (DOWN) or released (UP)</td>\r
+ * <td></td>\r
+ * <td></td>\r
+ * <td>SmartDeviceLink 1.0</td>\r
+ * </tr>\r
+ * <tr>\r
+ * <td>customButtonID</td>\r
+ * <td>Integer</td>\r
+ * <td>If ButtonName is Â¡Â°CUSTOM_BUTTON", this references the integer ID passed\r
+ * by a custom button. (e.g. softButton ID)</td>\r
+ * <td>N</td>\r
+ * <td>Minvalue=0 Maxvalue=65536</td>\r
+ * <td>SmartDeviceLink 2.0</td>\r
+ * </tr>\r
+ * </table>\r
+ * </p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ * \r
+ * @see SubscribeButton\r
+ * @see UnsubscribeButton\r
+ * \r
+ * \r
+ */\r
+public class OnButtonEvent extends RPCNotification {\r
+       /**\r
+       *Constructs a newly allocated OnButtonEvent object\r
+       */\r
+    public OnButtonEvent() {\r
+        super("OnButtonEvent");\r
+    }\r
+    /**\r
+        * <p>\r
+        * Constructs a newly allocated OnButtonEvent object indicated by the\r
+        * Hashtable parameter\r
+        * </p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+     */    \r
+    public OnButtonEvent(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * <p>Returns <i>{@linkplain ButtonName}</i> the button's name</p>\r
+     * @return ButtonName Name of the button\r
+     */    \r
+    public ButtonName getButtonName() {\r
+        Object obj = parameters.get(Names.buttonName);\r
+        if (obj instanceof ButtonName) {\r
+            return (ButtonName) obj;\r
+        } else if (obj instanceof String) {\r
+            ButtonName theCode = null;\r
+            try {\r
+                theCode = ButtonName.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.buttonName, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * <p>Set the button's name</p>    \r
+     * @param buttonName name of the button\r
+     */    \r
+    public void setButtonName(ButtonName buttonName) {\r
+        if (buttonName != null) {\r
+            parameters.put(Names.buttonName, buttonName);\r
+        } else {\r
+               parameters.remove(Names.buttonName);\r
+        }\r
+    }\r
+    /**\r
+     * <p>Return <i>{@linkplain ButtonEventMode} indicates the button was depressed or released</i></p>\r
+     * @return ButtonEventMode the button depressed or released\r
+     */    \r
+    public ButtonEventMode getButtonEventMode() {\r
+        Object obj = parameters.get(Names.buttonEventMode);\r
+        if (obj instanceof ButtonEventMode) {\r
+            return (ButtonEventMode) obj;\r
+        } else if (obj instanceof String) {\r
+            ButtonEventMode theCode = null;\r
+            try {\r
+                theCode = ButtonEventMode.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.buttonEventMode, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * <p> Set the event mode of the button,pressed or released\r
+     * @param buttonEventMode indicates the button is pressed or released\r
+     * @see ButtonEventMode\r
+     */    \r
+    public void setButtonEventMode(ButtonEventMode buttonEventMode) {\r
+        if (buttonEventMode != null) {\r
+            parameters.put(Names.buttonEventMode, buttonEventMode);\r
+        } else {\r
+               parameters.remove(Names.buttonEventMode);\r
+       }\r
+    }\r
+    public void setCustomButtonID(Integer customButtonID) {\r
+       if (customButtonID != null) {\r
+               parameters.put(Names.customButtonID, customButtonID);\r
+       } else {\r
+               parameters.remove(Names.customButtonID);\r
+       }\r
+    }\r
+    public Integer getCustomButtonID() {\r
+       return (Integer) parameters.get(Names.customButtonID);\r
+    }\r
+}\r
index bb9e789..db80d8e 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCNotification;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.ButtonName;
-import com.smartdevicelink.proxy.rpc.enums.ButtonPressMode;
-import com.smartdevicelink.util.DebugTool;
-
-public class OnButtonPress extends RPCNotification {
-
-    public OnButtonPress() {
-        super("OnButtonPress");
-    }
-    public OnButtonPress(Hashtable hash) {
-        super(hash);
-    }
-    public ButtonName getButtonName() {
-        Object obj = parameters.get(Names.buttonName);
-        if (obj instanceof ButtonName) {
-            return (ButtonName) obj;
-        } else if (obj instanceof String) {
-            ButtonName theCode = null;
-            try {
-                theCode = ButtonName.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.buttonName, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setButtonName( ButtonName buttonName ) {
-        if (buttonName != null) {
-            parameters.put(Names.buttonName, buttonName );
-        }
-    }
-    public ButtonPressMode getButtonPressMode() {
-        Object obj = parameters.get(Names.buttonPressMode);
-        if (obj instanceof ButtonPressMode) {
-            return (ButtonPressMode) obj;
-        } else if (obj instanceof String) {
-            ButtonPressMode theCode = null;
-            try {
-                theCode = ButtonPressMode.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.buttonPressMode, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setButtonPressMode( ButtonPressMode buttonPressMode ) {
-        if (buttonPressMode != null) {
-            parameters.put(Names.buttonPressMode, buttonPressMode );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCNotification;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.ButtonName;\r
+import com.smartdevicelink.proxy.rpc.enums.ButtonPressMode;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * <p>\r
+ * Notifies application of button press events for buttons to which the\r
+ * application is subscribed. SMARTDEVICELINK supports two button press events defined as\r
+ * follows:\r
+ * </p>\r
+ * <ul>\r
+ * <li>SHORT - Occurs when a button is depressed, then released within two\r
+ * seconds. The event is considered to occur immediately after the button is\r
+ * released.</li>\r
+ * <li>LONG - Occurs when a button is depressed and held for two seconds or\r
+ * more. The event is considered to occur immediately after the two second\r
+ * threshold has been crossed, before the button is released</li>\r
+ * </ul>\r
+ * <b>HMI Status Requirements:</b>\r
+ * <ul>\r
+ * HMILevel:\r
+ * <ul>\r
+ * <li>The application will receive OnButtonPress notifications for all\r
+ * subscribed buttons when HMILevel is FULL.</li>\r
+ * <li>The application will receive OnButtonPress notifications for subscribed\r
+ * media buttons when HMILevel is LIMITED.</li>\r
+ * <li>Media buttons include SEEKLEFT, SEEKRIGHT, TUNEUP, TUNEDOWN, and\r
+ * PRESET_0-PRESET_9.</li>\r
+ * <li>The application will not receive OnButtonPress notification when HMILevel\r
+ * is BACKGROUND or NONE.</li>\r
+ * </ul>\r
+ * AudioStreamingState:\r
+ * <ul>\r
+ * <li> Any </li>\r
+ * </ul>\r
+ * SystemContext:\r
+ * <ul>\r
+ * <li>MAIN, VR. In MENU, only PRESET buttons. In VR, pressing any subscribable\r
+ * button will cancel VR.</li>\r
+ * </ul>\r
+ * </ul>\r
+ * <p>\r
+ * <b>Parameter List:</b>\r
+ * <table  border="1" rules="all">\r
+ * <tr>\r
+ * <th>Name</th>\r
+ * <th>Type</th>\r
+ * <th>Description</th>\r
+ * <th>Req</th>\r
+ * <th>Notes</th>\r
+ * <th>Applink Ver Available</th>\r
+ * </tr>\r
+ * <tr>\r
+ * <td>buttonName</td>\r
+ * <td>{@linkplain ButtonName}</td>\r
+ * <td>Name of the button which triggered this event</td>\r
+ * <td></td>\r
+ * <td></td>\r
+ * <td>SmartDeviceLink 1.0</td>\r
+ * </tr>\r
+ * <tr>\r
+ * <td>buttonPressMode</td>\r
+ * <td>{@linkplain ButtonPressMode}</td>\r
+ * <td>Indicates whether this is an SHORT or LONG button press event.</td>\r
+ * <td></td>\r
+ * <td></td>\r
+ * <td>SmartDeviceLink 1.0</td>\r
+ * </tr>\r
+ * <tr>\r
+ * <td>customButtonID</td>\r
+ * <td>Integer</td>\r
+ * <td>If ButtonName is Â¡Â°CUSTOM_BUTTON", this references the integer ID passed\r
+ * by a custom button. (e.g. softButton ID)</td>\r
+ * <td>N</td>\r
+ * <td>Minvalue=0 Maxvalue=65536</td>\r
+ * <td>SmartDeviceLink 2.0</td>\r
+ * </tr>\r
+ * </table>\r
+ * </p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ * @see SubscribeButton\r
+ * @see UnsubscribeButton\r
+ */\r
+public class OnButtonPress extends RPCNotification {\r
+       /**\r
+       *Constructs a newly allocated OnButtonPress object\r
+       */   \r
+    public OnButtonPress() {\r
+        super("OnButtonPress");\r
+    }\r
+    /**\r
+        * <p>\r
+        * Constructs a newly allocated OnButtonPress object indicated by the\r
+        * Hashtable parameter\r
+        * </p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+     */    \r
+    public OnButtonPress(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * <p>Returns an <i>{@linkplain ButtonName}</i> the button's name</p>\r
+     * @return ButtonName Name of the button\r
+     */    \r
+    public ButtonName getButtonName() {\r
+        Object obj = parameters.get(Names.buttonName);\r
+        if (obj instanceof ButtonName) {\r
+            return (ButtonName) obj;\r
+        } else if (obj instanceof String) {\r
+            ButtonName theCode = null;\r
+            try {\r
+                theCode = ButtonName.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.buttonName, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * <p>Set the button's name</p>    \r
+     * @param buttonName name of the button\r
+     */    \r
+    public void setButtonName( ButtonName buttonName ) {\r
+        if (buttonName != null) {\r
+            parameters.put(Names.buttonName, buttonName );\r
+        }\r
+    }\r
+    /**<p>Returns <i>{@linkplain ButtonPressMode}</i></p>\r
+     * @return ButtonPressMode whether this is a long or short button press event\r
+     */    \r
+    public ButtonPressMode getButtonPressMode() {\r
+        Object obj = parameters.get(Names.buttonPressMode);\r
+        if (obj instanceof ButtonPressMode) {\r
+            return (ButtonPressMode) obj;\r
+        } else if (obj instanceof String) {\r
+            ButtonPressMode theCode = null;\r
+            try {\r
+                theCode = ButtonPressMode.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.buttonPressMode, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * <p>Set the button press mode of the event</p>\r
+     * @param buttonPressMode indicates whether this is a short or long press\r
+     */    \r
+    public void setButtonPressMode( ButtonPressMode buttonPressMode ) {\r
+        if (buttonPressMode != null) {\r
+            parameters.put(Names.buttonPressMode, buttonPressMode );\r
+        }\r
+    }\r
+    public void setCustomButtonName(Integer customButtonID) {\r
+       if (customButtonID != null) {\r
+               parameters.put(Names.customButtonID, customButtonID);\r
+       } else {\r
+               parameters.remove(Names.customButtonID);\r
+       }\r
+    }\r
+    public Integer getCustomButtonName() {\r
+       return (Integer) parameters.get(Names.customButtonID);\r
+    }\r
+}\r
index a5f0eb8..94ab19f 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCNotification;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.TriggerSource;
-import com.smartdevicelink.util.DebugTool;
-
-public class OnCommand extends RPCNotification {
-
-    public OnCommand() {
-        super("OnCommand");
-    }
-    public OnCommand(Hashtable hash) {
-        super(hash);
-    }
-    public Integer getCmdID() {
-        return (Integer) parameters.get( Names.cmdID );
-    }
-    public void setCmdID( Integer cmdID ) {
-        if (cmdID != null) {
-            parameters.put(Names.cmdID, cmdID );
-        }
-    }
-    public TriggerSource getTriggerSource() {
-        Object obj = parameters.get(Names.triggerSource);
-        if (obj instanceof TriggerSource) {
-            return (TriggerSource) obj;
-        } else if (obj instanceof String) {
-            TriggerSource theCode = null;
-            try {
-                theCode = TriggerSource.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.triggerSource, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setTriggerSource( TriggerSource triggerSource ) {
-        if (triggerSource != null) {
-            parameters.put(Names.triggerSource, triggerSource );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCNotification;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.TriggerSource;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * This is called when a command was selected via VR after pressing the PTT button, or selected from the menu after \r
+ * pressing the MENU button. <p>\r
+ * <b>Note: </b>Sequence of OnHMIStatus and OnCommand notifications for user-initiated interactions is indeterminate.\r
+ * <p></p>\r
+ * <b>HMI Status Requirements:</b>\r
+ * <ul>\r
+ * HMILevel: \r
+ * <ul><li>FULL,LIMITED</li></ul>\r
+ * AudioStreamingState: \r
+ * <ul><li>Any</li></ul>\r
+ * SystemContext: \r
+ * <ul><li>Any</li></ul>\r
+ * </ul>\r
+ * <p>\r
+ * <b>Parameter List:</b>\r
+ * <table  border="1" rules="all">\r
+ * <tr>\r
+ * <th>Name</th>\r
+ * <th>Type</th>\r
+ * <th>Description</th>\r
+ * <th>Notes</th>\r
+ * <th>Applink Ver Available</th>\r
+ * </tr>\r
+ * <tr>\r
+ * <td>cmdID</td>\r
+ * <td>Int32</td>\r
+ * <td>The cmdID of the command the user selected. This is the cmdID value provided by the application in the AddCommand operation that created the command.</td>\r
+ * <td></td>\r
+ * <td>SmartDeviceLink 1.0</td>\r
+ * </tr>\r
+ * <tr>\r
+ * <td>triggerSource</td>\r
+ * <td>{@linkplain TriggerSource}</td>\r
+ * <td>Indicates whether command was selected via VR or via a menu selection (using the OKbutton).</td>\r
+ * <td></td>\r
+ * <td>SmartDeviceLink 1.0</td>\r
+ * </tr>\r
+ * </table>\r
+ * </p>\r
+ * @since SmartDeviceLink 1.0\r
+ * @see AddCommand\r
+ * @see DeleteCommand\r
+ * @see DeleteSubMenu\r
+ */\r
+public class OnCommand extends RPCNotification {\r
+       /**\r
+       *Constructs a newly allocated OnCommand object\r
+       */    \r
+    public OnCommand() {\r
+        super("OnCommand");\r
+    }\r
+    /**\r
+    *<p>Constructs a newly allocated OnCommand object indicated by the Hashtable parameter</p>\r
+    *@param hash The Hashtable to use\r
+    */    \r
+    public OnCommand(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * <p>Returns an <i>Integer</i> object representing the Command ID</p>\r
+     * @return Integer an integer representation of this object\r
+     */    \r
+    public Integer getCmdID() {\r
+        return (Integer) parameters.get( Names.cmdID );\r
+    }\r
+    /**\r
+     * <p>Sets a Command ID</p>    \r
+     * @param cmdID an integer object representing a Command ID\r
+     */    \r
+    public void setCmdID( Integer cmdID ) {\r
+        if (cmdID != null) {\r
+            parameters.put(Names.cmdID, cmdID );\r
+        }\r
+    }\r
+    /**\r
+     * <p>Returns a <I>TriggerSource</I> object which will be shown in the HMI</p>    \r
+     * @return TriggerSource a TriggerSource object\r
+     */    \r
+    public TriggerSource getTriggerSource() {\r
+        Object obj = parameters.get(Names.triggerSource);\r
+        if (obj instanceof TriggerSource) {\r
+            return (TriggerSource) obj;\r
+        } else if (obj instanceof String) {\r
+            TriggerSource theCode = null;\r
+            try {\r
+                theCode = TriggerSource.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.triggerSource, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * <p>Sets TriggerSource<br/>\r
+     * Indicates whether command was selected via VR or via a menu selection (using the OK button).</p>    \r
+     * @param triggerSource a TriggerSource object\r
+     */    \r
+    public void setTriggerSource( TriggerSource triggerSource ) {\r
+        if (triggerSource != null) {\r
+            parameters.put(Names.triggerSource, triggerSource );\r
+        }\r
+    }\r
+}\r
index e5540a8..62ff68e 100755 (executable)
@@ -1,42 +1,85 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-
-import com.smartdevicelink.proxy.RPCNotification;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.DriverDistractionState;
-import com.smartdevicelink.util.DebugTool;
-
-public class OnDriverDistraction  extends RPCNotification {
-       public OnDriverDistraction() {
-        super("OnDriverDistraction");
-    }
-    public OnDriverDistraction(Hashtable hash) {
-        super(hash);
-    }
-    
-    public DriverDistractionState getState() {
-        Object obj = parameters.get(Names.state);
-        if (obj instanceof DriverDistractionState) {
-               return (DriverDistractionState)obj;
-        } else if(obj instanceof String) {
-               DriverDistractionState theCode = null;
-               try {
-                       theCode = DriverDistractionState.valueForString((String) obj);
-               } catch (Exception e) {
-                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.state, e);
-            }
-               return theCode;
-        }      
-       return null;
-    }
-    public void setState( DriverDistractionState state ) {
-        if (state != null) {
-            parameters.put(Names.state, state );
-        }
-    }  
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+\r
+import com.smartdevicelink.proxy.RPCNotification;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.DriverDistractionState;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * <p>Notifies the application of the current driver distraction state (whether driver distraction rules are in effect, or \r
+ * not).</p>\r
+ *\r
+ * <p></p>\r
+ * <b>HMI Status Requirements:</b>\r
+ * <ul>\r
+ * HMILevel: \r
+ * <ul><li>Can be sent with FULL, LIMITED or BACKGROUND</li></ul>\r
+ * AudioStreamingState: \r
+ * <ul><li>Any</li></ul>\r
+ * SystemContext: \r
+ * <ul><li>Any</li></ul>\r
+ * </ul>\r
+ * <p></p>\r
+ * <b>Parameter List:</b>\r
+ * <table  border="1" rules="all">\r
+ * <tr>\r
+ * <th>Name</th>\r
+ * <th>Type</th>\r
+ * <th>Description</th>\r
+ * <th>Applink Ver Available</th>\r
+ * </tr>\r
+ * <tr>\r
+ * <td>state</td>\r
+ * <td>{@linkplain DriverDistractionState}</td>\r
+ * <td>Current driver distraction state (i.e. whether driver distraction rules are in effect, or not). </td>\r
+ * <td>SmartDeviceLink 1.0</td>\r
+ * </tr>\r
+ * </table> \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class OnDriverDistraction  extends RPCNotification {\r
+       /**\r
+       *Constructs a newly allocated OnDriverDistraction object\r
+       */ \r
+       public OnDriverDistraction() {\r
+        super("OnDriverDistraction");\r
+    }\r
+       /**\r
+     *<p>Constructs a newly allocated OnDriverDistraction object indicated by the Hashtable parameter</p>\r
+     *@param hash The Hashtable to use\r
+     */        \r
+    public OnDriverDistraction(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * <p>Called to get the current driver distraction state(i.e. whether driver distraction rules are in effect, or not)</p>\r
+     * @return {@linkplain DriverDistractionState} the Current driver distraction state.\r
+     */    \r
+    public DriverDistractionState getState() {\r
+        Object obj = parameters.get(Names.state);\r
+        if (obj instanceof DriverDistractionState) {\r
+               return (DriverDistractionState)obj;\r
+        } else if(obj instanceof String) {\r
+               DriverDistractionState theCode = null;\r
+               try {\r
+                       theCode = DriverDistractionState.valueForString((String) obj);\r
+               } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.state, e);\r
+            }\r
+               return theCode;\r
+        }      \r
+       return null;\r
+    }\r
+    /**\r
+     * <p>Called to set the driver distraction state(i.e. whether driver distraction rules are in effect, or not)</p>\r
+     * @param state the current driver distraction state\r
+     */    \r
+    public void setState( DriverDistractionState state ) {\r
+        if (state != null) {\r
+            parameters.put(Names.state, state );\r
+        }\r
+    }  \r
+}\r
index 0e5b5a2..6d81436 100755 (executable)
@@ -1,39 +1,63 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-import java.util.Vector;
-
-
-import com.smartdevicelink.proxy.RPCNotification;
-import com.smartdevicelink.proxy.constants.Names;
-
-public class OnEncodedSyncPData extends RPCNotification {
-       public OnEncodedSyncPData() {
-        super("OnEncodedSyncPData");
-    }
-    public OnEncodedSyncPData(Hashtable hash) {
-        super(hash);
-    }
-    
-    public Vector<String> getData() {
-       if (parameters.get(Names.data) instanceof Vector<?>) {
-               Vector<?> list = (Vector<?>)parameters.get(Names.data);
-               if (list != null && list.size()>0) {
-                       Object obj = list.get(0);
-                       if (obj instanceof String) {
-                               return (Vector<String>)list;
-                       }
-               }
-       }
-        return null;
-    }
-    
-    public void setData( Vector<String> data ) {
-        if (data != null) {
-            parameters.put(Names.data, data );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCNotification;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+\r
+public class OnEncodedSyncPData extends RPCNotification {\r
+\r
+       public OnEncodedSyncPData() {\r
+        super("OnEncodedSyncPData");\r
+    }\r
+\r
+    public OnEncodedSyncPData(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+  \r
+    public Vector<String> getData() {\r
+       if (parameters.get(Names.data) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.data);\r
+               if (list != null && list.size()>0) {\r
+                       Object obj = list.get(0);\r
+                       if (obj instanceof String) {\r
+                               return (Vector<String>)list;\r
+                       }\r
+               }\r
+       }\r
+        return null;\r
+    }\r
+  \r
+    public void setData(Vector<String> data) {\r
+        if (data != null) {\r
+            parameters.put(Names.data, data);\r
+        } else {\r
+                       parameters.remove(Names.data);\r
+        }\r
+    }\r
+    public String getUrl(){\r
+        return (String) parameters.get(Names.URL);\r
+    }\r
+    public void setUrl(String url) {\r
+       if (url != null) {\r
+               parameters.put(Names.URL, url);\r
+       } else {\r
+                       parameters.remove(Names.URL);\r
+        }\r
+    }\r
+    public Integer getTimeout(){\r
+       if (parameters.get(Names.Timeout) instanceof Integer) {\r
+               return (Integer)parameters.get(Names.Timeout);\r
+       }\r
+       return null;\r
+    }\r
+    public void setTimeout(Integer timeout) {\r
+        if (timeout != null) {\r
+            parameters.put(Names.timeout, timeout);\r
+        } else {\r
+               parameters.remove(Names.timeout);\r
+        }\r
+    }\r
+}\r
index 7d4d37a..3e8d36b 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCNotification;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.AudioStreamingState;
-import com.smartdevicelink.proxy.rpc.enums.HMILevel;
-import com.smartdevicelink.proxy.rpc.enums.SystemContext;
-import com.smartdevicelink.util.DebugTool;
-
-public class OnHMIStatus extends RPCNotification {
-       private Boolean firstRun;
-       
-    public OnHMIStatus() {
-        super("OnHMIStatus");
-    }
-    public OnHMIStatus(Hashtable hash) {
-        super(hash);
-    }
-    public HMILevel getHmiLevel() {
-        Object obj = parameters.get(Names.hmiLevel);
-        if (obj instanceof HMILevel) {
-            return (HMILevel) obj;
-        } else if (obj instanceof String) {
-            HMILevel theCode = null;
-            try {
-                theCode = HMILevel.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.hmiLevel, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setHmiLevel( HMILevel hmiLevel ) {
-        if (hmiLevel != null) {
-            parameters.put(Names.hmiLevel, hmiLevel );
-        }
-    }
-    public AudioStreamingState getAudioStreamingState() {
-        Object obj = parameters.get(Names.audioStreamingState);
-        if (obj instanceof AudioStreamingState) {
-            return (AudioStreamingState) obj;
-        } else if (obj instanceof String) {
-            AudioStreamingState theCode = null;
-            try {
-                theCode = AudioStreamingState.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.audioStreamingState, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setAudioStreamingState( AudioStreamingState audioStreamingState ) {
-        if (audioStreamingState != null) {
-            parameters.put(Names.audioStreamingState, audioStreamingState );
-        }
-    }
-    public SystemContext getSystemContext() {
-        Object obj = parameters.get(Names.systemContext);
-        if (obj instanceof SystemContext) {
-            return (SystemContext) obj;
-        } else if (obj instanceof String) {
-            SystemContext theCode = null;
-            try {
-                theCode = SystemContext.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.systemContext, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setSystemContext( SystemContext systemContext ) {
-        if (systemContext != null) {
-            parameters.put(Names.systemContext, systemContext );
-        }
-    }
-    public Boolean getFirstRun() {
-       return this.firstRun;
-    }
-    public void setFirstRun(Boolean firstRun) {
-       this.firstRun = firstRun;
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCNotification;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.AudioStreamingState;\r
+import com.smartdevicelink.proxy.rpc.enums.HMILevel;\r
+import com.smartdevicelink.proxy.rpc.enums.SystemContext;\r
+import com.smartdevicelink.util.DebugTool;\r
+/**\r
+ * <p>Notifies an application that HMI conditions have changed for the application. This indicates whether the application \r
+ * can speak phrases, display text, perform interactions, receive button presses and events, stream audio, etc. This \r
+ * notification will be sent to the application when there has been a change in any one or several of the indicated \r
+ * states ({@linkplain HMILevel}, {@linkplain AudioStreamingState} or {@linkplain SystemContext}) for the application</p>\r
+ * <p>All three values are, in principle, independent of each other (though there may be some relationships). A value for \r
+ * one parameter should not be interpreted from the value of another parameter.</p>\r
+ * <p>There are no guarantees about the timeliness or latency of the OnHMIStatus notification. Therefore, for example, \r
+ * information such as {@linkplain AudioStreamingState} may not indicate that the audio stream became inaudible to the user \r
+ * exactly when the OnHMIStatus notification was received.</p>\r
+ * \r
+ * <p>\r
+ * <b>Parameter List:</b>\r
+ * <table  border="1" rules="all">\r
+ * <tr>\r
+ * <th>Name</th>\r
+ * <th>Type</th>\r
+ * <th>Description</th>\r
+ * <th>Applink Ver Available</th>\r
+ * </tr>\r
+ * <tr>\r
+ * <td>hmiLevel</td>\r
+ * <td>{@linkplain HMILevel}</td>\r
+ * <td>The current HMI Level in effect for the application.</td>\r
+ * <td>SmartDeviceLink 1.0</td>\r
+ * </tr>\r
+ * <tr>\r
+ * <td>audioStreamingState</td>\r
+ * <td>{@linkplain AudioStreamingState}</td>\r
+ * <td>Current state of audio streaming for the application. \r
+ * When this parameter has a value of NOT_AUDIBLE, \r
+ * the application must stop streaming audio to SMARTDEVICELINK. \r
+ * Informs app whether any currently streaming audio is \r
+ * audible to user (AUDIBLE) or not (NOT_AUDIBLE). A \r
+ * value of NOT_AUDIBLE means that either the \r
+ * application's audio will not be audible to the user, or \r
+ * that the application's audio should not be audible to \r
+ * the user (i.e. some other application on the mobile \r
+ * device may be streaming audio and the application's \r
+ * audio would be blended with that other audio). </td>\r
+ * <td>SmartDeviceLink 1.0</td>\r
+ * </tr>\r
+ * <tr>\r
+ * <td>systemContext</td>\r
+ * <td>{@linkplain SystemContext}</td>\r
+ * <td>Indicates that a user-initiated interaction is in-progress \r
+ * (VRSESSION or MENU), or not (MAIN)</td>\r
+ * <td>SmartDeviceLink 1.0</td>\r
+ * </tr>\r
+ * </table>\r
+ * </p>\r
+ * @since SmartDeviceLink 1.0\r
+ * @see RegisterAppInterface \r
+ */\r
+public class OnHMIStatus extends RPCNotification {\r
+       private Boolean firstRun;\r
+       /**\r
+       *Constructs a newly allocated OnHMIStatus object\r
+       */      \r
+    public OnHMIStatus() {\r
+        super("OnHMIStatus");\r
+    }\r
+    /**\r
+    *<p>Constructs a newly allocated OnHMIStatus object indicated by the Hashtable parameter</p>\r
+    *@param hash The Hashtable to use\r
+    */    \r
+    public OnHMIStatus(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * <p>Get HMILevel in effect for the application</p>\r
+     * @return {@linkplain HMILevel} the current HMI Level in effect for the application\r
+     */    \r
+    public HMILevel getHmiLevel() {\r
+        Object obj = parameters.get(Names.hmiLevel);\r
+        if (obj instanceof HMILevel) {\r
+            return (HMILevel) obj;\r
+        } else if (obj instanceof String) {\r
+            HMILevel theCode = null;\r
+            try {\r
+                theCode = HMILevel.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.hmiLevel, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * <p>Set the HMILevel of OnHMIStatus</p>\r
+     * @param hmiLevel the HMILevel to set\r
+     */    \r
+    public void setHmiLevel( HMILevel hmiLevel ) {\r
+        if (hmiLevel != null) {\r
+            parameters.put(Names.hmiLevel, hmiLevel );\r
+        }\r
+    }\r
+    /**\r
+     * <p>Get current state of audio streaming for the application</p>\r
+     * @return {@linkplain AudioStreamingState} Returns current state of audio streaming for the application\r
+     */    \r
+    public AudioStreamingState getAudioStreamingState() {\r
+        Object obj = parameters.get(Names.audioStreamingState);\r
+        if (obj instanceof AudioStreamingState) {\r
+            return (AudioStreamingState) obj;\r
+        } else if (obj instanceof String) {\r
+            AudioStreamingState theCode = null;\r
+            try {\r
+                theCode = AudioStreamingState.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.audioStreamingState, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * <p>Set the audio streaming state</p>\r
+     * @param audioStreamingState the state of audio streaming of the application\r
+     */    \r
+    public void setAudioStreamingState( AudioStreamingState audioStreamingState ) {\r
+        if (audioStreamingState != null) {\r
+            parameters.put(Names.audioStreamingState, audioStreamingState );\r
+        }\r
+    }\r
+    /**\r
+     * <p>Get the System Context</p>\r
+     * @return {@linkplain SystemContext} whether a user-initiated interaction is in-progress (VRSESSION or MENU), or not (MAIN).\r
+     */    \r
+    public SystemContext getSystemContext() {\r
+        Object obj = parameters.get(Names.systemContext);\r
+        if (obj instanceof SystemContext) {\r
+            return (SystemContext) obj;\r
+        } else if (obj instanceof String) {\r
+            SystemContext theCode = null;\r
+            try {\r
+                theCode = SystemContext.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.systemContext, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * <p>Set the System Context of OnHMIStatus</p>\r
+     * @param systemContext Indicates that a user-initiated interaction is in-progress \r
+     * (VRSESSION or MENU), or not (MAIN)\r
+     */    \r
+    public void setSystemContext( SystemContext systemContext ) {\r
+        if (systemContext != null) {\r
+            parameters.put(Names.systemContext, systemContext );\r
+        }\r
+    }\r
+    /**\r
+     * <p>Query whether it's the first run</p>\r
+     * @return boolean whether it's the first run\r
+     */    \r
+    public Boolean getFirstRun() {\r
+       return this.firstRun;\r
+    }\r
+    /**\r
+     * <p>Set the firstRun value</p>\r
+     * @param firstRun True if it is the first run, False or not\r
+     */    \r
+    public void setFirstRun(Boolean firstRun) {\r
+       this.firstRun = firstRun;\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnLanguageChange.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnLanguageChange.java
new file mode 100755 (executable)
index 0000000..2109528
--- /dev/null
@@ -0,0 +1,134 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCNotification;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.Language;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Provides information to what language the SmartDeviceLink HMI language was changed\r
+ * <p>\r
+ * </p>\r
+ * <b>HMI Status Requirements:</b>\r
+ * <ul>\r
+ * HMILevel:\r
+ * <ul>\r
+ * <li>TBD</li>\r
+ * </ul>\r
+ * AudioStreamingState:\r
+ * <ul>\r
+ * <li>TBD</li>\r
+ * </ul>\r
+ * SystemContext:\r
+ * <ul>\r
+ * <li>TBD</li>\r
+ * </ul>\r
+ * </ul>\r
+ * <p>\r
+ * <b>Parameter List:</b>\r
+ * <table border="1" rules="all">\r
+ * <tr>\r
+ * <th>Name</th>\r
+ * <th>Type</th>\r
+ * <th>Description</th>\r
+ * <th>Req</th>\r
+ * <th>Notes</th>\r
+ * <th>Applink Ver Available</th>\r
+ * </tr>\r
+ * <tr>\r
+ * <td>language</td>\r
+ * <td>{@linkplain Language}</td>\r
+ * <td>Current SMARTDEVICELINK voice engine (VR+TTS) language</td>\r
+ * <td>Y</td>\r
+ * <td></td>\r
+ * <td>SmartDeviceLink 2.0</td>\r
+ * </tr>\r
+ * <tr>\r
+ * <td>hmiDisplayLanguage</td>\r
+ * <td>{@linkplain Language}</td>\r
+ * <td>Current display language</td>\r
+ * <td>Y</td>\r
+ * <td></td>\r
+ * <td>SmartDeviceLink 2.0</td>\r
+ * </tr>\r
+ * </table>\r
+ * </p>\r
+ *\r
+ */\r
+public class OnLanguageChange extends RPCNotification {\r
+       /**\r
+       *Constructs a newly allocated OnCommand object\r
+       */    \r
+    public OnLanguageChange() {\r
+        super("OnLanguageChange");\r
+    }\r
+    /**\r
+     *<p>Constructs a newly allocated OnLanguageChange object indicated by the Hashtable parameter</p>\r
+     *@param hash The Hashtable to use\r
+     */\r
+    public OnLanguageChange(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * <p>Sets language that current SMARTDEVICELINK voice engine(VR+TTS) use</p>    \r
+     * @param language language that current SMARTDEVICELINK voice engine(VR+TTS) use\r
+     */  \r
+    public void setLanguage(Language language) {\r
+        if (language != null) {\r
+            parameters.put(Names.language, language);\r
+        } else {\r
+               parameters.remove(Names.language);\r
+        }\r
+    }\r
+    /**\r
+     * <p>Returns language that current SMARTDEVICELINK voice engine(VR+TTS) use</p>\r
+     * @return {@linkplain Language} language that current SMARTDEVICELINK voice engine(VR+TTS) use\r
+     */  \r
+    public Language getLanguage() {\r
+       Object obj = parameters.get(Names.language);\r
+        if (obj instanceof Language) {\r
+            return (Language) obj;\r
+        } else if (obj instanceof String) {\r
+               Language theCode = null;\r
+            try {\r
+                theCode = Language.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.language, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * <p>Sets language that current display use</p>    \r
+     * @param hmiDisplayLanguage language that current SMARTDEVICELINK voice engine(VR+TTS) use\r
+     */  \r
+    public void setHmiDisplayLanguage(Language hmiDisplayLanguage) {\r
+        if (hmiDisplayLanguage != null) {\r
+            parameters.put(Names.hmiDisplayLanguage, hmiDisplayLanguage);\r
+        } else {\r
+               parameters.remove(Names.hmiDisplayLanguage);\r
+        }\r
+    }\r
+    /**\r
+     * <p>Returns language that current  display use</p>\r
+     * @return {@linkplain Language} language that current display use\r
+     */  \r
+    public Language getHmiDisplayLanguage() {\r
+       Object obj = parameters.get(Names.hmiDisplayLanguage);\r
+        if (obj instanceof Language) {\r
+            return (Language) obj;\r
+        } else if (obj instanceof String) {\r
+               Language theCode = null;\r
+            try {\r
+                theCode = Language.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.hmiDisplayLanguage, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+}\r
index 4ccfa37..3cec57a 100755 (executable)
@@ -1,42 +1,95 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-import java.util.Vector;
-
-import com.smartdevicelink.proxy.RPCNotification;
-import com.smartdevicelink.proxy.constants.Names;
-
-public class OnPermissionsChange extends RPCNotification {
-
-       public OnPermissionsChange() {
-               super("OnPermissionsChange");
-       }
-       public OnPermissionsChange(Hashtable hash) {
-               super(hash);
-       }
-
-       public Vector<PermissionGroupItem> getPermissionGroupItems() {
-               Vector<?> list = (Vector<?>)parameters.get(Names.PermissionGroupItems);
-               if (list != null && list.size()>0) {
-                       Object obj = list.get(0);
-                       if(obj instanceof PermissionGroupItem){
-                               return (Vector<PermissionGroupItem>) list;
-                       } else if(obj instanceof Hashtable) {
-                               Vector<PermissionGroupItem> newList = new Vector<PermissionGroupItem>();
-                               for (Object hash:list) {
-                                       newList.add(new PermissionGroupItem((Hashtable)hash));
-                               }
-                               return newList;
-                       }
-               }
-               return null;
-       }
-       public void setPermissionGroupItems(Vector<PermissionGroupItem> permissionGroupItems) {
-               if (permissionGroupItems != null) {
-                       parameters.put(Names.PermissionGroupItems, permissionGroupItems);
-               }
-       }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCNotification;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Provides update to app of which sets of functions are available\r
+ * <p>\r
+ * </p>\r
+ * <b>HMI Status Requirements:</b>\r
+ * <ul>\r
+ * HMILevel:\r
+ * <ul>\r
+ * <li>Any</li>\r
+ * </ul>\r
+ * AudioStreamingState:\r
+ * <ul>\r
+ * <li>TBD</li>\r
+ * </ul>\r
+ * SystemContext:\r
+ * <ul>\r
+ * <li>TBD</li>\r
+ * </ul>\r
+ * </ul>\r
+ * <p>\r
+ * <b>Parameter List:</b>\r
+ * <table border="1" rules="all">\r
+ * <tr>\r
+ * <th>Name</th>\r
+ * <th>Type</th>\r
+ * <th>Description</th>\r
+ * <th>Req</th>\r
+ * <th>Notes</th>\r
+ * <th>Applink Ver Available</th>\r
+ * </tr>\r
+ * <tr>\r
+ * <td>permissionItem</td>\r
+ * <td>PermissionItem[]</td>\r
+ * <td>Change in permissions for a given set of RPCs</td>\r
+ * <td>Y</td>\r
+ * <td>Minsize=1 Maxsize=100</td>\r
+ * <td>SmartDeviceLink 2.0</td>\r
+ * </tr>\r
+ * </table>\r
+ * </p>\r
+ */\r
+public class OnPermissionsChange extends RPCNotification {\r
+       /**\r
+       *Constructs a newly allocated OnCommand object\r
+       */    \r
+       public OnPermissionsChange() {\r
+               super("OnPermissionsChange");\r
+       }\r
+       /**\r
+     *<p>Constructs a newly allocated OnPermissionsChange object indicated by the Hashtable parameter</p>\r
+     *@param hash The Hashtable to use\r
+     */\r
+       public OnPermissionsChange(Hashtable hash) {\r
+               super(hash);\r
+       }\r
+       /**\r
+     * <p>Returns Vector<PermissionItem> object describing change in permissions for a given set of RPCs</p>\r
+     * @return Vector<{@linkplain PermissionItem}> an object describing describing change in permissions for a given set of RPCs\r
+     */   \r
+       public Vector<PermissionItem> getPermissionItem() {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.permissionItem);\r
+               if (list != null && list.size()>0) {\r
+                       Object obj = list.get(0);\r
+                       if(obj instanceof PermissionItem){\r
+                               return (Vector<PermissionItem>) list;\r
+                       } else if(obj instanceof Hashtable) {\r
+                               Vector<PermissionItem> newList = new Vector<PermissionItem>();\r
+                               for (Object hash:list) {\r
+                                       newList.add(new PermissionItem((Hashtable)hash));\r
+                               }\r
+                               return newList;\r
+                       }\r
+               }\r
+               return null;\r
+       }\r
+    /**\r
+     * <p>Sets PermissionItems describing change in permissions for a given set of RPCs</p>    \r
+     * @param permissionItem an vector of  PermissionItem describing change in permissions for a given set of RPCs\r
+     */  \r
+       public void setPermissionItem(Vector<PermissionItem> permissionItem) {\r
+               if (permissionItem != null) {\r
+                       parameters.put(Names.permissionItem, permissionItem);\r
+               } else {\r
+                       parameters.remove(Names.permissionItem);\r
+        }\r
+       }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnSmartDeviceLinkChoiceChosen.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnSmartDeviceLinkChoiceChosen.java
new file mode 100755 (executable)
index 0000000..b919a95
--- /dev/null
@@ -0,0 +1,170 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCNotification;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.TriggerSource;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+public class OnSmartDeviceLinkChoiceChosen extends RPCNotification {\r
+       \r
+       \r
+       public class SmartDeviceLinkSubMenu {\r
+               private Integer _menuID = null;\r
+               private Integer _position = null;\r
+               private String _menuName = null;\r
+               \r
+               // Constructor\r
+               SmartDeviceLinkSubMenu(Integer menuID, Integer position, String menuName) {\r
+                       _menuID = menuID;\r
+                       _position = position;\r
+                       _menuName = menuName;\r
+               }\r
+               \r
+               // Restrict no-arg constructor\r
+               private SmartDeviceLinkSubMenu() {}\r
+               \r
+               // Public Getters\r
+               public Integer getMenuID() {\r
+                       return _menuID;\r
+               }\r
+               \r
+               public String getMenuName() {\r
+                       return _menuName;\r
+               }\r
+               \r
+               public String toString() {\r
+                       return _menuName;\r
+               }\r
+       }\r
+       \r
+       public class SmartDeviceLinkCommand {\r
+               private Integer _commandID = null;\r
+               private SmartDeviceLinkSubMenu _parentSubMenu = null;\r
+               private Integer _position = null;\r
+               private String _menuName = null;\r
+               private Vector<String> _vrCommands = null;\r
+               \r
+               // Constructor\r
+               SmartDeviceLinkCommand(Integer commandID, SmartDeviceLinkSubMenu parentSubMenu, Integer position, String menuName, Vector<String> vrCommands) {\r
+                       _commandID = commandID;\r
+                       _parentSubMenu = parentSubMenu;\r
+                       _position = position;\r
+                       _menuName = menuName;\r
+                       _vrCommands = vrCommands;\r
+               }\r
+               \r
+               // Restrict no-arg constructor\r
+               private SmartDeviceLinkCommand() {}\r
+               \r
+               // Public Getters\r
+               public Integer getCommandID() {\r
+                       return _commandID;\r
+               }\r
+               \r
+               public SmartDeviceLinkSubMenu getParentSubMenu() {\r
+                       return _parentSubMenu;\r
+               }\r
+               \r
+               public String getMenuName() {\r
+                       return _menuName;\r
+               }\r
+               \r
+               public Vector<String> getVrCommands() {\r
+                       return _vrCommands;\r
+               }\r
+               \r
+               public String toString() {\r
+                       return _menuName;\r
+               }\r
+       }\r
+       \r
+       public class SmartDeviceLinkChoice {\r
+               \r
+               private Choice _choice = null;\r
+               \r
+               // Constructor\r
+               SmartDeviceLinkChoice(Choice choice) {\r
+                       _choice = choice;\r
+               }\r
+               \r
+               public Choice getChoice() {\r
+                       return _choice;\r
+               }\r
+               \r
+               public Integer getChoiceID() {\r
+                       return _choice.getChoiceID();\r
+               }\r
+               \r
+               public String getMenuName() {\r
+                       return _choice.getMenuName();\r
+               }\r
+               \r
+               public Vector<String> getVrCommands() {\r
+                       return _choice.getVrCommands();\r
+               }\r
+               \r
+               public String toString() {\r
+                       return _choice.getMenuName();\r
+               }\r
+       }\r
+       \r
+       public class SmartDeviceLinkChoiceSet {\r
+               private Integer _choiceSetID = null;\r
+               private Vector<SmartDeviceLinkChoice> _choiceSet = null;\r
+               \r
+               // Constructor\r
+               SmartDeviceLinkChoiceSet(Integer choiceSetID, Vector<SmartDeviceLinkChoice> choiceSet) {\r
+                       _choiceSetID = choiceSetID;\r
+                       _choiceSet = choiceSet;\r
+               }\r
+               \r
+               public Integer getChoiceSetID() {\r
+                       return _choiceSetID;\r
+               }\r
+               \r
+               public Vector<SmartDeviceLinkChoice> getChoiceSet() {\r
+                       return _choiceSet;\r
+               }\r
+       }\r
+       \r
+       \r
+       \r
+\r
+       public OnSmartDeviceLinkChoiceChosen() {\r
+               super(Names.OnSmartDeviceLinkChoiceChosen);\r
+       }\r
+       public OnSmartDeviceLinkChoiceChosen(Hashtable hash){\r
+               super(hash);\r
+       }\r
+    public SmartDeviceLinkChoice getSmartDeviceLinkChoice() {\r
+       return (SmartDeviceLinkChoice) parameters.get(Names.smartDeviceLinkChoice);\r
+    }\r
+    public void setSmartDeviceLinkChoice(SmartDeviceLinkChoice smartDeviceLinkChoice) {\r
+       if (smartDeviceLinkChoice != null) {\r
+               parameters.put(Names.smartDeviceLinkChoice, smartDeviceLinkChoice);\r
+       }\r
+    }\r
+    public TriggerSource getTriggerSource() {\r
+        Object obj = parameters.get(Names.triggerSource);\r
+        if (obj instanceof TriggerSource) {\r
+            return (TriggerSource) obj;\r
+        } else if (obj instanceof String) {\r
+            TriggerSource theCode = null;\r
+            try {\r
+                theCode = TriggerSource.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.triggerSource, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setTriggerSource( TriggerSource triggerSource ) {\r
+        if (triggerSource != null) {\r
+            parameters.put(Names.triggerSource, triggerSource );\r
+        }\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnSyncPData.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnSyncPData.java
new file mode 100755 (executable)
index 0000000..4e2bd2f
--- /dev/null
@@ -0,0 +1,48 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCNotification;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+public class OnSyncPData extends RPCNotification {\r
+       public OnSyncPData() {\r
+        super("OnSyncPData");\r
+    }\r
+    public OnSyncPData(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public String getUrl(){\r
+        return (String) parameters.get(Names.URL);\r
+    }\r
+    public void setUrl(String url) {\r
+       if (url != null) {\r
+               parameters.put(Names.URL, url);\r
+       } else {\r
+                       parameters.remove(Names.URL);\r
+        }\r
+    }\r
+    public Integer getTimeout(){\r
+       if (parameters.get(Names.Timeout) instanceof Integer) {\r
+               return (Integer)parameters.get(Names.Timeout);\r
+       }\r
+       return null;\r
+    }\r
+    public void setTimeout(Integer timeout) {\r
+        if (timeout != null) {\r
+            parameters.put(Names.timeout, timeout);\r
+        } else {\r
+               parameters.remove(Names.timeout);\r
+        }\r
+    }\r
+    public void setSyncPData(byte[] syncPData) {\r
+        if (syncPData != null) {\r
+            store.put(Names.bulkData, syncPData);\r
+        } else {\r
+               store.remove(Names.bulkData);\r
+        }\r
+    }\r
+    public byte[] getSyncPData() {\r
+        return (byte[]) store.get(Names.bulkData);\r
+    }\r
+}\r
index 53259b5..11a79dd 100755 (executable)
@@ -1,41 +1,86 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCNotification;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.TBTState;
-import com.smartdevicelink.util.DebugTool;
-
-public class OnTBTClientState extends RPCNotification {
-
-    public OnTBTClientState() {
-        super("OnTBTClientState");
-    }
-    public OnTBTClientState(Hashtable hash) {
-        super(hash);
-    }
-    public TBTState getState() {
-        Object obj = parameters.get(Names.state);
-        if (obj instanceof TBTState) {
-               return (TBTState)obj;
-        } else if(obj instanceof String) {
-               TBTState theCode = null;
-               try{
-                       theCode = TBTState.valueForString((String) obj);
-               } catch (Exception e) {
-                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.state, e);
-            }
-               return theCode;
-        }      
-       return null;
-    }
-    public void setState( TBTState state ) {
-        if (state != null) {
-            parameters.put(Names.state, state );
-        }
-    }
-} // end-class
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCNotification;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.TBTState;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * <p>Notifies the application of the current TBT client status on the module.</p>\r
+ *\r
+ * <p></p>\r
+ * <b>HMI Status Requirements:</b>\r
+ * <ul>\r
+ * HMILevel: \r
+ * <ul><li>Can be sent with FULL, LIMITED or BACKGROUND</li></ul>\r
+ * AudioStreamingState: \r
+ * <ul><li>Any</li></ul>\r
+ * SystemContext: \r
+ * <ul><li>Any</li></ul>\r
+ * </ul>\r
+ * <p></p>\r
+ * <b>Parameter List:</b>\r
+ * <table  border="1" rules="all">\r
+ * <tr>\r
+ * <th>Name</th>\r
+ * <th>Type</th>\r
+ * <th>Description</th>\r
+ * <th>Applink Ver Available</th>\r
+ * </tr>\r
+ * <tr>\r
+ * <td>state</td>\r
+ * <td>{@linkplain TBTState}</td>\r
+ * <td>Current state of TBT client.</td>\r
+ * <td>SmartDeviceLink 1.0</td>\r
+ * </tr>\r
+ * </table>\r
+ * @since SmartDeviceLink 1.0\r
+ * \r
+ */\r
+public class OnTBTClientState extends RPCNotification {\r
+       /**\r
+       *Constructs a newly allocated OnTBTClientState object\r
+       */ \r
+    public OnTBTClientState() {\r
+        super("OnTBTClientState");\r
+    }\r
+    /**\r
+     *<p>Constructs a newly allocated OnTBTClientState object indicated by the Hashtable parameter</p>\r
+     *@param hash The Hashtable to use\r
+     */    \r
+    public OnTBTClientState(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * <p>Called to get the current state of TBT client</p>\r
+     * @return {@linkplain TBTState} the current state of TBT client\r
+     */    \r
+    public TBTState getState() {\r
+        Object obj = parameters.get(Names.state);\r
+        if (obj instanceof TBTState) {\r
+               return (TBTState)obj;\r
+        } else if(obj instanceof String) {\r
+               TBTState theCode = null;\r
+               try{\r
+                       theCode = TBTState.valueForString((String) obj);\r
+               } catch (Exception e) {\r
+                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.state, e);\r
+            }\r
+               return theCode;\r
+        }      \r
+       return null;\r
+    }\r
+    /**\r
+     * <p>Called to set the current state of TBT client</p>\r
+     * @param state current state of TBT client\r
+     */    \r
+    public void setState( TBTState state ) {\r
+        if (state != null) {\r
+            parameters.put(Names.state, state );\r
+        } else {\r
+               parameters.remove(Names.state);\r
+        }\r
+    }\r
+} // end-class
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnVehicleData.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/OnVehicleData.java
new file mode 100755 (executable)
index 0000000..68873b5
--- /dev/null
@@ -0,0 +1,550 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Iterator;\r
+\r
+import com.smartdevicelink.proxy.RPCNotification;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.AmbientLightStatus;\r
+import com.smartdevicelink.proxy.rpc.enums.ComponentVolumeStatus;\r
+import com.smartdevicelink.proxy.rpc.enums.GearShiftAdviceStatus;\r
+import com.smartdevicelink.proxy.rpc.enums.PRNDL;\r
+import com.smartdevicelink.proxy.rpc.enums.VehicleDataActiveStatus;\r
+import com.smartdevicelink.proxy.rpc.enums.VehicleDataEventStatus;\r
+import com.smartdevicelink.proxy.rpc.enums.WiperStatus;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+public class OnVehicleData extends RPCNotification {\r
+\r
+    public OnVehicleData() {\r
+        super("OnVehicleData");\r
+    }\r
+    public OnVehicleData(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public void setGps(GPSData gps) {\r
+       if (gps != null) {\r
+               parameters.put(Names.gps, gps);\r
+       } else {\r
+               parameters.remove(Names.gps);\r
+       }\r
+    }\r
+    public GPSData getGps() {\r
+       Object obj = parameters.get(Names.gps);\r
+        if (obj instanceof GPSData) {\r
+            return (GPSData) obj;\r
+        } else {\r
+               GPSData theCode = null;\r
+            try {\r
+                theCode = new GPSData((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.gps, e);\r
+            }\r
+            return theCode;\r
+        }\r
+    }\r
+    public void setSpeed(Double speed) {\r
+       if (speed != null) {\r
+               parameters.put(Names.speed, speed);\r
+       } else {\r
+               parameters.remove(Names.speed);\r
+       }\r
+    }\r
+    public Double getSpeed() {\r
+       return (Double) parameters.get(Names.speed);\r
+    }\r
+    public void setRpm(Integer rpm) {\r
+       if (rpm != null) {\r
+               parameters.put(Names.rpm, rpm);\r
+       } else {\r
+               parameters.remove(Names.rpm);\r
+       }\r
+    }\r
+    public Integer getRpm() {\r
+       return (Integer) parameters.get(Names.rpm);\r
+    }\r
+    public void setFuelLevel(Double fuelLevel) {\r
+       if (fuelLevel != null) {\r
+               parameters.put(Names.fuelLevel, fuelLevel);\r
+       } else {\r
+               parameters.remove(Names.fuelLevel);\r
+       }\r
+    }\r
+    public Double getFuelLevel() {\r
+       return (Double) parameters.get(Names.fuelLevel);\r
+    }\r
+    public void setFuelLevel_State(ComponentVolumeStatus fuelLevel_State) {\r
+       if (fuelLevel_State != null) {\r
+               parameters.put(Names.fuelLevel_State, fuelLevel_State);\r
+       } else {\r
+               parameters.remove(Names.fuelLevel_State);\r
+       }\r
+    }\r
+    public ComponentVolumeStatus getFuelLevel_State() {\r
+        Object obj = parameters.get(Names.fuelLevel_State);\r
+        if (obj instanceof ComponentVolumeStatus) {\r
+            return (ComponentVolumeStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               ComponentVolumeStatus theCode = null;\r
+            try {\r
+                theCode = ComponentVolumeStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.fuelLevel_State, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setInstantFuelConsumption(Double instantFuelConsumption) {\r
+       if (instantFuelConsumption != null) {\r
+               parameters.put(Names.instantFuelConsumption, instantFuelConsumption);\r
+       } else {\r
+               parameters.remove(Names.instantFuelConsumption);\r
+       }\r
+    }\r
+    public Double getInstantFuelConsumption() {\r
+       return (Double) parameters.get(Names.instantFuelConsumption);\r
+    }\r
+    public void setExternalTemperature(Double externalTemperature) {\r
+       if (externalTemperature != null) {\r
+               parameters.put(Names.externalTemperature, externalTemperature);\r
+       } else {\r
+               parameters.remove(Names.externalTemperature);\r
+       }\r
+    }\r
+    public Double getExternalTemperature() {\r
+       return (Double) parameters.get(Names.externalTemperature);\r
+    }\r
+    public void setVin(String vin) {\r
+       if (vin != null) {\r
+               parameters.put(Names.vin, vin);\r
+       } else {\r
+               parameters.remove(Names.vin);\r
+       }\r
+    }\r
+    public String getVin() {\r
+       return (String) parameters.get(Names.vin);\r
+    }\r
+    public void setPrndl(PRNDL prndl) {\r
+       if (prndl != null) {\r
+               parameters.put(Names.prndl, prndl);\r
+       } else {\r
+               parameters.remove(Names.prndl);\r
+       }\r
+    }\r
+    public PRNDL getPrndl() {\r
+        Object obj = parameters.get(Names.prndl);\r
+        if (obj instanceof PRNDL) {\r
+            return (PRNDL) obj;\r
+        } else if (obj instanceof String) {\r
+               PRNDL theCode = null;\r
+            try {\r
+                theCode = PRNDL.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.prndl, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setTirePressure(TireStatus tirePressure) {\r
+       if (tirePressure != null) {\r
+               parameters.put(Names.tirePressure, tirePressure);\r
+       } else {\r
+               parameters.remove(Names.tirePressure);\r
+       }\r
+    }\r
+    public TireStatus getTirePressure() {\r
+       Object obj = parameters.get(Names.tirePressure);\r
+        if (obj instanceof TireStatus) {\r
+            return (TireStatus) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new TireStatus((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.tirePressure, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setOdometer(Integer odometer) {\r
+       if (odometer != null) {\r
+               parameters.put(Names.odometer, odometer);\r
+       } else {\r
+               parameters.remove(Names.odometer);\r
+       }\r
+    }\r
+    public Integer getOdometer() {\r
+       return (Integer) parameters.get(Names.odometer);\r
+    }\r
+    public void setBeltStatus(BeltStatus beltStatus) {\r
+        if (beltStatus != null) {\r
+            parameters.put(Names.beltStatus, beltStatus);\r
+        } else {\r
+               parameters.remove(Names.beltStatus);\r
+        }\r
+    }\r
+    public BeltStatus getBeltStatus() {\r
+       Object obj = parameters.get(Names.beltStatus);\r
+        if (obj instanceof BeltStatus) {\r
+            return (BeltStatus) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new BeltStatus((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.beltStatus, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setBodyInformation(BodyInformation bodyInformation) {\r
+        if (bodyInformation != null) {\r
+            parameters.put(Names.bodyInformation, bodyInformation);\r
+        } else {\r
+               parameters.remove(Names.bodyInformation);\r
+        }\r
+    }\r
+    public BodyInformation getBodyInformation() {\r
+       Object obj = parameters.get(Names.bodyInformation);\r
+        if (obj instanceof BodyInformation) {\r
+            return (BodyInformation) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new BodyInformation((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.bodyInformation, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setDeviceStatus(DeviceStatus deviceStatus) {\r
+        if (deviceStatus != null) {\r
+            parameters.put(Names.deviceStatus, deviceStatus);\r
+        } else {\r
+               parameters.remove(Names.deviceStatus);\r
+        }\r
+    }\r
+    public DeviceStatus getDeviceStatus() {\r
+       Object obj = parameters.get(Names.deviceStatus);\r
+        if (obj instanceof DeviceStatus) {\r
+            return (DeviceStatus) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new DeviceStatus((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.deviceStatus, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setDriverBraking(VehicleDataEventStatus driverBraking) {\r
+        if (driverBraking != null) {\r
+            parameters.put(Names.driverBraking, driverBraking);\r
+        } else {\r
+               parameters.remove(Names.driverBraking);\r
+        }\r
+    }\r
+    public VehicleDataEventStatus getDriverBraking() {\r
+        Object obj = parameters.get(Names.driverBraking);\r
+        if (obj instanceof VehicleDataEventStatus) {\r
+            return (VehicleDataEventStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataEventStatus theCode = null;\r
+            try {\r
+                theCode = VehicleDataEventStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.driverBraking, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setWiperStatus(WiperStatus wiperStatus) {\r
+        if (wiperStatus != null) {\r
+            parameters.put(Names.wiperStatus, wiperStatus);\r
+        } else {\r
+               parameters.remove(Names.wiperStatus);\r
+        }\r
+    }\r
+    public WiperStatus getWiperStatus() {\r
+        Object obj = parameters.get(Names.wiperStatus);\r
+        if (obj instanceof WiperStatus) {\r
+            return (WiperStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               WiperStatus theCode = null;\r
+            try {\r
+                theCode = WiperStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.wiperStatus, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setFuelEconomy(FuelEconomyInformation fuelEconomy) {\r
+        if (fuelEconomy != null) {\r
+            parameters.put(Names.fuelEconomy, fuelEconomy);\r
+        } else {\r
+               parameters.remove(Names.fuelEconomy);\r
+        }\r
+    }\r
+    public FuelEconomyInformation getFuelEconomy() {\r
+       Object obj = parameters.get(Names.fuelEconomy);\r
+        if (obj instanceof FuelEconomyInformation) {\r
+            return (FuelEconomyInformation) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new FuelEconomyInformation((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.fuelEconomy, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setEngineOilLife(Integer engineOilLife) {\r
+        if (engineOilLife != null) {\r
+            parameters.put(Names.engineOilLife, engineOilLife);\r
+        } else {\r
+               parameters.remove(Names.engineOilLife);\r
+        }\r
+    }\r
+    public Integer getEngineOilLife() {\r
+       return (Integer) parameters.get(Names.engineOilLife);\r
+    }\r
+    public void setHeadLampStatus(HeadLampStatus headLampStatus) {\r
+        if (headLampStatus != null) {\r
+            parameters.put(Names.headLampStatus, headLampStatus);\r
+        } else {\r
+               parameters.remove(Names.headLampStatus);\r
+        }\r
+    }\r
+    public HeadLampStatus getHeadLampStatus() {\r
+       Object obj = parameters.get(Names.headLampStatus);\r
+        if (obj instanceof HeadLampStatus) {\r
+            return (HeadLampStatus) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new HeadLampStatus((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.headLampStatus, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setBatteryVoltage(Double batteryVoltage) {\r
+        if (batteryVoltage != null) {\r
+            parameters.put(Names.batteryVoltage, batteryVoltage);\r
+        } else {\r
+               parameters.remove(Names.batteryVoltage);\r
+        }\r
+    }\r
+    public Double getBatteryVoltage() {\r
+       return (Double) parameters.get(Names.batteryVoltage);\r
+    }\r
+    public void setBrakeTorque(Double brakeTorque) {\r
+        if (brakeTorque != null) {\r
+            parameters.put(Names.brakeTorque, brakeTorque);\r
+        } else {\r
+               parameters.remove(Names.brakeTorque);\r
+        }\r
+    }\r
+    public Double getBrakeTorque() {\r
+       return (Double) parameters.get(Names.brakeTorque);\r
+    }\r
+    public void setEngineTorque(Double engineTorque) {\r
+        if (engineTorque != null) {\r
+            parameters.put(Names.engineTorque, engineTorque);\r
+        } else {\r
+               parameters.remove(Names.engineTorque);\r
+        }\r
+    }\r
+    public Double getEngineTorque() {\r
+       return (Double) parameters.get(Names.engineTorque);\r
+    }\r
+    public void setTurboBoost(Double turboBoost) {\r
+        if (turboBoost != null) {\r
+            parameters.put(Names.turboBoost, turboBoost);\r
+        } else {\r
+               parameters.remove(Names.turboBoost);\r
+        }\r
+    }\r
+    public Double getTurboBoost() {\r
+       return (Double) parameters.get(Names.turboBoost);\r
+    }\r
+    public void setCoolantTemp(Double coolantTemp) {\r
+        if (coolantTemp != null) {\r
+            parameters.put(Names.coolantTemp, coolantTemp);\r
+        } else {\r
+               parameters.remove(Names.coolantTemp);\r
+        }\r
+    }\r
+    public Double getCoolantTemp() {\r
+       return (Double) parameters.get(Names.coolantTemp);\r
+    }\r
+    public void setAirFuelRatio(Double airFuelRatio) {\r
+        if (airFuelRatio != null) {\r
+            parameters.put(Names.airFuelRatio, airFuelRatio);\r
+        } else {\r
+               parameters.remove(Names.airFuelRatio);\r
+        }\r
+    }\r
+    public Double getAirFuelRatio() {\r
+       return (Double) parameters.get(Names.airFuelRatio);\r
+    }\r
+    public void setCoolingHeadTemp(Double coolingHeadTemp) {\r
+        if (coolingHeadTemp != null) {\r
+            parameters.put(Names.coolingHeadTemp, coolingHeadTemp);\r
+        } else {\r
+               parameters.remove(Names.coolingHeadTemp);\r
+        }\r
+    }\r
+    public Double getCoolingHeadTemp() {\r
+       return (Double) parameters.get(Names.coolingHeadTemp);\r
+    }\r
+    public void setOilTemp(Double oilTemp) {\r
+        if (oilTemp != null) {\r
+            parameters.put(Names.oilTemp, oilTemp);\r
+        } else {\r
+               parameters.remove(Names.oilTemp);\r
+        }\r
+    }\r
+    public Double getOilTemp() {\r
+       return (Double) parameters.get(Names.oilTemp);\r
+    }\r
+    public void setIntakeAirTemp(Double intakeAirTemp) {\r
+        if (intakeAirTemp != null) {\r
+            parameters.put(Names.intakeAirTemp, intakeAirTemp);\r
+        } else {\r
+               parameters.remove(Names.intakeAirTemp);\r
+        }\r
+    }\r
+    public Double getIntakeAirTemp() {\r
+       return (Double) parameters.get(Names.intakeAirTemp);\r
+    }\r
+    public void setGearShiftAdvice(GearShiftAdviceStatus gearShiftAdvice) {\r
+        if (gearShiftAdvice != null) {\r
+            parameters.put(Names.gearShiftAdvice, gearShiftAdvice);\r
+        } else {\r
+               parameters.remove(Names.gearShiftAdvice);\r
+        }\r
+    }\r
+    public GearShiftAdviceStatus getGearShiftAdvice() {\r
+        Object obj = parameters.get(Names.gearShiftAdvice);\r
+        if (obj instanceof GearShiftAdviceStatus) {\r
+            return (GearShiftAdviceStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               GearShiftAdviceStatus theCode = null;\r
+            try {\r
+                theCode = GearShiftAdviceStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.gearShiftAdvice, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setAcceleration(Double acceleration) {\r
+        if (acceleration != null) {\r
+            parameters.put(Names.acceleration, acceleration);\r
+        } else {\r
+               parameters.remove(Names.acceleration);\r
+        }\r
+    }\r
+    public Double getAcceleration() {\r
+       return (Double) parameters.get(Names.acceleration);\r
+    }\r
+    public void setAccPedalPosition(Double accPedalPosition) {\r
+        if (accPedalPosition != null) {\r
+            parameters.put(Names.accPedalPosition, accPedalPosition);\r
+        } else {\r
+               parameters.remove(Names.accPedalPosition);\r
+        }\r
+    }\r
+    public Double getAccPedalPosition() {\r
+       return (Double) parameters.get(Names.accPedalPosition);\r
+    }\r
+    public void setClutchPedalPosition(Double clutchPedalPosition) {\r
+        if (clutchPedalPosition != null) {\r
+            parameters.put(Names.clutchPedalPosition, clutchPedalPosition);\r
+        } else {\r
+               parameters.remove(Names.clutchPedalPosition);\r
+        }\r
+    }\r
+    public Double getClutchPedalPosition() {\r
+       return (Double) parameters.get(Names.clutchPedalPosition);\r
+    }\r
+    public void setReverseGearStatus(VehicleDataActiveStatus reverseGearStatus) {\r
+        if (reverseGearStatus != null) {\r
+            parameters.put(Names.reverseGearStatus, reverseGearStatus);\r
+        } else {\r
+               parameters.remove(Names.reverseGearStatus);\r
+        }\r
+    }\r
+    public VehicleDataActiveStatus getReverseGearStatus() {\r
+        Object obj = parameters.get(Names.reverseGearStatus);\r
+        if (obj instanceof VehicleDataActiveStatus) {\r
+            return (VehicleDataActiveStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataActiveStatus theCode = null;\r
+            try {\r
+                theCode = VehicleDataActiveStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.reverseGearStatus, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setAccTorque(Double accTorque) {\r
+        if (accTorque != null) {\r
+            parameters.put(Names.accTorque, accTorque);\r
+        } else {\r
+               parameters.remove(Names.accTorque);\r
+        }\r
+    }\r
+    public Double getAccTorque() {\r
+       return (Double) parameters.get(Names.accTorque);\r
+    }\r
+    public void setEvInfo(EVInfo evInfo) {\r
+        if (evInfo != null) {\r
+            parameters.put(Names.evInfo, evInfo);\r
+        } else {\r
+               parameters.remove(Names.evInfo);\r
+        }\r
+    }\r
+    public EVInfo getEvInfo() {\r
+       Object obj = parameters.get(Names.evInfo);\r
+        if (obj instanceof EVInfo) {\r
+            return (EVInfo) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new EVInfo((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.evInfo, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setAmbientLightStatus(AmbientLightStatus ambientLightStatus) {\r
+        if (ambientLightStatus != null) {\r
+            parameters.put(Names.ambientLightStatus, ambientLightStatus);\r
+        } else {\r
+               parameters.remove(Names.ambientLightStatus);\r
+        }\r
+    }\r
+    public AmbientLightStatus getAmbientLightStatus() {\r
+        Object obj = parameters.get(Names.ambientLightStatus);\r
+        if (obj instanceof AmbientLightStatus) {\r
+            return (AmbientLightStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               AmbientLightStatus theCode = null;\r
+            try {\r
+                theCode = AmbientLightStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.ambientLightStatus, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }    \r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ParameterPermissions.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ParameterPermissions.java
new file mode 100755 (executable)
index 0000000..7ff2ffc
--- /dev/null
@@ -0,0 +1,119 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.HMILevel;\r
+\r
+/**\r
+ * Defining sets of parameters, which are permitted or prohibited for a given RPC.\r
+ * <p><b>Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>allowed</td>\r
+ *                     <td>String</td>\r
+ *                     <td>A set of all parameters that are permitted for this given RPC.\r
+ *                                     <ul>\r
+ *                                     <li>Min size: 0</li>\r
+ *                                     <li>Max size: 100</li>\r
+ *                                     <li>Max length: 100</li>\r
+ *                                     </ul>\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>userDisallowed</td>\r
+ *                     <td>String</td>\r
+ *                     <td>A set of all parameters that are prohibated for this given RPC.\r
+ *                                     <ul>\r
+ *                                     <li>Min size: 0</li>\r
+ *                                     <li>Max size: 100</li>\r
+ *                                     <li>Max length: 100</li>\r
+ *                                     </ul>\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *  </table>\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class ParameterPermissions extends RPCStruct {\r
+\r
+       /**\r
+        *  Constructs a newly allocated ParameterPermissions object\r
+        */\r
+    public ParameterPermissions() { }\r
+    \r
+    /**\r
+     * Constructs a newly allocated ParameterPermissions object indicated by the Hashtable parameter\r
+     * @param hash The Hashtable to use\r
+     */\r
+    public ParameterPermissions(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    \r
+    /**\r
+     * get a set of all parameters that are permitted for this given RPC.\r
+     * @return a set of all parameters that are permitted for this given RPC.\r
+     */\r
+    public Vector<String> getAllowed() {\r
+        if (store.get(Names.allowed) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)store.get( Names.allowed);\r
+               if (list != null && list.size() > 0) {\r
+                       Object obj = list.get(0);\r
+                       if (obj instanceof String) {\r
+                       return (Vector<String>) list;                           \r
+                       }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+    \r
+    /**\r
+     * set a set of all parameters that are permitted for this given RPC.\r
+     * @param allowed parameter that is permitted for this given RPC\r
+     */\r
+    public void setAllowed(HMILevel allowed) {\r
+        if (allowed != null) {\r
+            store.put(Names.allowed, allowed);\r
+        } else {\r
+               store.remove(Names.allowed);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get a set of all parameters that are prohibited for this given RPC.\r
+     * @return a set of all parameters that are prohibited for this given RPC\r
+     */\r
+    public Vector<String> getUserDisallowed() {\r
+        if (store.get(Names.userDisallowed) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)store.get( Names.userDisallowed);\r
+               if (list != null && list.size() > 0) {\r
+                       Object obj = list.get(0);\r
+                       if (obj instanceof String) {\r
+                       return (Vector<String>) list;                           \r
+                       }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+    \r
+    /**\r
+     * set a set of all parameters that are prohibited for this given RPC.\r
+     * @param userDisallowed paramter that is prohibited for this given RPC\r
+     */\r
+    public void setUserDisallowed(HMILevel userDisallowed) {\r
+        if (userDisallowed != null) {\r
+            store.put(Names.userDisallowed, userDisallowed);\r
+        } else {\r
+               store.remove(Names.userDisallowed);\r
+       }\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PerformAudioPassThru.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PerformAudioPassThru.java
new file mode 100755 (executable)
index 0000000..9871044
--- /dev/null
@@ -0,0 +1,315 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.AudioType;\r
+import com.smartdevicelink.proxy.rpc.enums.BitsPerSample;\r
+import com.smartdevicelink.proxy.rpc.enums.SamplingRate;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * This will open an audio pass thru session. By doing so the app can receive\r
+ * audio data through the vehicle\92s microphone\r
+ * <p>\r
+ * Function Group: AudioPassThru\r
+ * <p>\r
+ * <b>HMILevel needs to be FULL, LIMITED or BACKGROUND</b>\r
+ * </p>\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ * @see EndAudioPassThru\r
+ */\r
+public class PerformAudioPassThru extends RPCRequest {\r
+       \r
+       /**\r
+        * Constructs a new PerformAudioPassThru object\r
+        */\r
+    public PerformAudioPassThru() {\r
+        super("PerformAudioPassThru");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new PerformAudioPassThru object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public PerformAudioPassThru(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+\r
+       /**\r
+        * Sets initial prompt which will be spoken before opening the audio pass\r
+        * thru session by SMARTDEVICELINK\r
+        * \r
+        * @param initialPrompt\r
+        *            a Vector<TTSChunk> value represents the initial prompt which\r
+        *            will be spoken before opening the audio pass thru session by\r
+        *            SMARTDEVICELINK\r
+        *            <p>\r
+        *            <b>Notes: </b>\r
+        *            <ul>\r
+        *            <li>This is an array of text chunks of type TTSChunk</li>\r
+        *            <li>The array must have at least one item</li>\r
+        *            <li>If omitted, then no initial prompt is spoken</li>\r
+        *            <li>Array Minsize: 1</li>\r
+        *            <li>Array Maxsize: 100</li>\r
+        *            </ul>\r
+        */\r
+    public void setInitialPrompt(Vector<TTSChunk> initialPrompt) {\r
+       if (initialPrompt != null) {\r
+               parameters.put(Names.initialPrompt, initialPrompt);\r
+       } else {\r
+               parameters.remove(Names.initialPrompt);\r
+       }\r
+    }\r
+\r
+       /**\r
+        * Gets a Vector value representing an initial prompt which will be spoken\r
+        * before opening the audio pass thru session by SMARTDEVICELINK\r
+        * \r
+        * @return Vector<TTSChunk> -a Vector value representing an initial prompt\r
+        *         which will be spoken before opening the audio pass thru session\r
+        *         by SMARTDEVICELINK\r
+        */\r
+    public Vector<TTSChunk> getInitialPrompt() {\r
+       if (parameters.get(Names.initialPrompt) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.initialPrompt);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof TTSChunk) {\r
+                       return (Vector<TTSChunk>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<TTSChunk> newList = new Vector<TTSChunk>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new TTSChunk((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+       }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * Sets a line of text displayed during audio capture\r
+        * \r
+        * @param audioPassThruDisplayText1\r
+        *            a String value representing the line of text displayed during\r
+        *            audio capture\r
+        *            <p>\r
+        *            <b>Notes: </b>Maxlength=500\r
+        */\r
+    public void setAudioPassThruDisplayText1(String audioPassThruDisplayText1) {\r
+       if (audioPassThruDisplayText1 != null) {\r
+               parameters.put(Names.audioPassThruDisplayText1, audioPassThruDisplayText1);\r
+       } else {\r
+               parameters.remove(Names.audioPassThruDisplayText1);\r
+       }\r
+    }\r
+\r
+       /**\r
+        * Gets a first line of text displayed during audio capture\r
+        * \r
+        * @return String -a String value representing a first line of text\r
+        *         displayed during audio capture\r
+        */\r
+    public String getAudioPassThruDisplayText1() {\r
+       return (String) parameters.get(Names.audioPassThruDisplayText1);\r
+    }\r
+\r
+       /**\r
+        * Sets a line of text displayed during audio capture\r
+        * \r
+        * @param audioPassThruDisplayText2\r
+        *            a String value representing the line of text displayed during\r
+        *            audio capture\r
+        *            <p>\r
+        *            <b>Notes: </b>Maxlength=500\r
+        */\r
+    public void setAudioPassThruDisplayText2(String audioPassThruDisplayText2) {\r
+       if (audioPassThruDisplayText2 != null) {\r
+               parameters.put(Names.audioPassThruDisplayText2, audioPassThruDisplayText2);\r
+       } else {\r
+               parameters.remove(Names.audioPassThruDisplayText2);\r
+       }\r
+    }\r
+\r
+       /**\r
+        * Gets a second line of text displayed during audio capture\r
+        * \r
+        * @return String -a String value representing a first line of text\r
+        *         displayed during audio capture\r
+        */\r
+    public String getAudioPassThruDisplayText2() {\r
+       return (String) parameters.get(Names.audioPassThruDisplayText2);\r
+    }\r
+\r
+       /**\r
+        * Sets a samplingRate\r
+        * \r
+        * @param samplingRate\r
+        *            a SamplingRate value representing a 8 or 16 or 22 or 24 khz\r
+        */\r
+    public void setSamplingRate(SamplingRate samplingRate) {\r
+       if (samplingRate != null) {\r
+               parameters.put(Names.samplingRate, samplingRate);\r
+       } else {\r
+               parameters.remove(Names.samplingRate);\r
+       }\r
+    }\r
+\r
+       /**\r
+        * Gets a samplingRate\r
+        * \r
+        * @return SamplingRate -a SamplingRate value\r
+        */\r
+    public SamplingRate getSamplingRate() {\r
+       Object obj = parameters.get(Names.samplingRate);\r
+       if (obj instanceof SamplingRate) {\r
+               return (SamplingRate) obj;\r
+       } else if (obj instanceof String) {\r
+               SamplingRate theCode = null;\r
+            try {\r
+                theCode = SamplingRate.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.samplingRate, e);\r
+            }\r
+            return theCode;\r
+       }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * Sets the maximum duration of audio recording in milliseconds\r
+        * \r
+        * @param maxDuration\r
+        *            an Integer value representing the maximum duration of audio\r
+        *            recording in millisecond\r
+        *            <p>\r
+        *            <b>Notes: </b>Minvalue:1; Maxvalue:1000000\r
+        */\r
+    public void setMaxDuration(Integer maxDuration) {\r
+       if (maxDuration != null) {\r
+               parameters.put(Names.maxDuration, maxDuration);\r
+       } else {\r
+               parameters.remove(Names.maxDuration);\r
+       }\r
+    }\r
+\r
+       /**\r
+        * Gets a max duration of audio recording in milliseconds\r
+        * \r
+        * @return int -an int value representing the maximum duration of audio\r
+        *         recording in milliseconds\r
+        */\r
+    public int getMaxDuration() {\r
+       return (Integer) parameters.get(Names.maxDuration);\r
+    }\r
+\r
+       /**\r
+        * Sets the quality the audio is recorded - 8 bit or 16 bit\r
+        * \r
+        * @param audioQuality\r
+        *            a BitsPerSample value representing 8 bit or 16 bit\r
+        */\r
+    public void setBitsPerSample(BitsPerSample audioQuality) {\r
+       if (audioQuality != null) {\r
+               parameters.put(Names.bitsPerSample, audioQuality);\r
+       } else {\r
+               parameters.remove(Names.bitsPerSample);\r
+       }\r
+    }\r
+\r
+       /**\r
+        * Gets a BitsPerSample value, 8 bit or 16 bit\r
+        * \r
+        * @return BitsPerSample -a BitsPerSample value\r
+        */\r
+    public BitsPerSample getBitsPerSample() {\r
+       Object obj = parameters.get(Names.bitsPerSample);\r
+       if (obj instanceof BitsPerSample) {\r
+               return (BitsPerSample) obj;\r
+       } else if (obj instanceof String) {\r
+               BitsPerSample theCode = null;\r
+            try {\r
+                theCode = BitsPerSample.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.bitsPerSample, e);\r
+            }\r
+            return theCode;\r
+       }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * Sets an audioType\r
+        * \r
+        * @param audioType\r
+        *            an audioType\r
+        */\r
+    public void setAudioType(AudioType audioType) {\r
+       if (audioType != null) {\r
+               parameters.put(Names.audioType, audioType);\r
+       } else {\r
+               parameters.remove(Names.audioType);\r
+       }\r
+    }\r
+\r
+       /**\r
+        * Gets a type of audio data\r
+        * \r
+        * @return AudioType -an AudioType\r
+        */\r
+    public AudioType getAudioType() {\r
+       Object obj = parameters.get(Names.audioType);\r
+       if (obj instanceof AudioType) {\r
+               return (AudioType) obj;\r
+       } else if (obj instanceof String) {\r
+               AudioType theCode = null;\r
+            try {\r
+                theCode = AudioType.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.audioType, e);\r
+            }\r
+            return theCode;\r
+       }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * Gets a Boolean value representing if the current audio source should be\r
+        * muted during the APT session<br/>\r
+        * \r
+        * \r
+        * @return Boolean -a Boolean value representing if the current audio source\r
+        *         should be muted during the APT session\r
+        */\r
+    public Boolean getMuteAudio() {\r
+       return (Boolean) parameters.get(Names.muteAudio);\r
+    }\r
+\r
+       /**\r
+        * Sets a muteAudio value representing if the current audio source should be\r
+        * muted during the APT session<br/>\r
+        * If not, the audio source will play without interruption. If omitted, the\r
+        * value is set to true\r
+        * <p>\r
+        * \r
+        * @param muteAudio\r
+        *            a Boolean value representing if the current audio source\r
+        *            should be muted during the APT session\r
+        */\r
+    public void setMuteAudio(Boolean muteAudio) {\r
+       if (muteAudio != null) {\r
+               parameters.put(Names.muteAudio, muteAudio);\r
+       } else {\r
+               parameters.remove(Names.muteAudio);\r
+       }\r
+    }    \r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PerformAudioPassThruResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PerformAudioPassThruResponse.java
new file mode 100755 (executable)
index 0000000..719131c
--- /dev/null
@@ -0,0 +1,32 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Perform Audio Pass Thru Response is sent, when PerformAudioPassThru has been called\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class PerformAudioPassThruResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new PerformAudioPassThruResponse object\r
+        */\r
+    public PerformAudioPassThruResponse() {\r
+        super("PerformAudioPassThru");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new PerformAudioPassThruResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public PerformAudioPassThruResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
index c382e3c..55a0683 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-import java.util.Vector;
-
-import com.smartdevicelink.proxy.RPCRequest;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.InteractionMode;
-import com.smartdevicelink.util.DebugTool;
-
-public class PerformInteraction extends RPCRequest {
-
-    public PerformInteraction() {
-        super("PerformInteraction");
-    }
-    public PerformInteraction(Hashtable hash) {
-        super(hash);
-    }
-    public String getInitialText() {
-        return (String) parameters.get( Names.initialText );
-    }
-    public void setInitialText( String initialText ) {
-        if (initialText != null) {
-            parameters.put(Names.initialText, initialText );
-        }
-    }
-    public Vector<TTSChunk> getInitialPrompt() {
-        if (parameters.get(Names.initialPrompt) instanceof Vector<?>) {
-               Vector<?> list = (Vector<?>)parameters.get(Names.initialPrompt);
-               if (list != null && list.size() > 0) {
-                   Object obj = list.get(0);
-                   if (obj instanceof TTSChunk) {
-                       return (Vector<TTSChunk>) list;
-                   } else if (obj instanceof Hashtable) {
-                       Vector<TTSChunk> newList = new Vector<TTSChunk>();
-                       for (Object hashObj : list) {
-                           newList.add(new TTSChunk((Hashtable)hashObj));
-                       }
-                       return newList;
-                   }
-               }
-        }
-        return null;
-    }
-    public void setInitialPrompt( Vector<TTSChunk> initialPrompt ) {
-        if (initialPrompt != null) {
-            parameters.put(Names.initialPrompt, initialPrompt );
-        }
-    }
-    public InteractionMode getInteractionMode() {
-        Object obj = parameters.get(Names.interactionMode);
-        if (obj instanceof InteractionMode) {
-            return (InteractionMode) obj;
-        } else if (obj instanceof String) {
-            InteractionMode theCode = null;
-            try {
-                theCode = InteractionMode.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.interactionMode, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setInteractionMode( InteractionMode interactionMode ) {
-        if (interactionMode != null) {
-            parameters.put(Names.interactionMode, interactionMode );
-        }
-    }
-    public Vector<Integer> getInteractionChoiceSetIDList() {
-       if(parameters.get(Names.interactionChoiceSetIDList) instanceof Vector<?>){
-               Vector<?> list = (Vector<?>)parameters.get(Names.interactionChoiceSetIDList);
-               if(list != null && list.size()>0){
-                       Object obj = list.get(0);
-                       if(obj instanceof Integer){
-                               return (Vector<Integer>) list;
-                       }
-               }
-       }
-        return null;
-    }
-    public void setInteractionChoiceSetIDList( Vector<Integer> interactionChoiceSetIDList ) {
-        if (interactionChoiceSetIDList != null) {
-            parameters.put(Names.interactionChoiceSetIDList, interactionChoiceSetIDList );
-        }
-    }
-    public Vector<TTSChunk> getHelpPrompt() {
-        if(parameters.get(Names.helpPrompt) instanceof Vector<?>){
-               Vector<?> list = (Vector<?>)parameters.get(Names.helpPrompt);
-               if (list != null && list.size() > 0) {
-                   Object obj = list.get(0);
-                   if (obj instanceof TTSChunk) {
-                       return (Vector<TTSChunk>) list;
-                   } else if (obj instanceof Hashtable) {
-                       Vector<TTSChunk> newList = new Vector<TTSChunk>();
-                       for (Object hashObj : list) {
-                           newList.add(new TTSChunk((Hashtable)hashObj));
-                       }
-                       return newList;
-                   }
-               }
-        }
-        return null;
-    }
-    public void setHelpPrompt( Vector<TTSChunk> helpPrompt ) {
-        if (helpPrompt != null) {
-            parameters.put(Names.helpPrompt, helpPrompt );
-        }
-    }
-    public Vector<TTSChunk> getTimeoutPrompt() {
-        if (parameters.get(Names.timeoutPrompt) instanceof Vector<?>) {
-               Vector<?> list = (Vector<?>)parameters.get(Names.timeoutPrompt);
-               if (list != null && list.size() > 0) {
-                   Object obj = list.get(0);
-                   if (obj instanceof TTSChunk) {
-                       return (Vector<TTSChunk>) list;
-                   } else if (obj instanceof Hashtable) {
-                       Vector<TTSChunk> newList = new Vector<TTSChunk>();
-                       for (Object hashObj : list) {
-                           newList.add(new TTSChunk((Hashtable)hashObj));
-                       }
-                       return newList;
-                   }
-               }
-        }
-        return null;
-    }
-    public void setTimeoutPrompt( Vector<TTSChunk> timeoutPrompt ) {
-        if (timeoutPrompt != null) {
-            parameters.put(Names.timeoutPrompt, timeoutPrompt );
-        }
-    }
-    public Integer getTimeout() {
-        return (Integer) parameters.get( Names.timeout );
-    }
-    public void setTimeout( Integer timeout ) {
-        if (timeout != null) {
-            parameters.put(Names.timeout, timeout );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.InteractionMode;\r
+import com.smartdevicelink.util.DebugTool;\r
+/**\r
+ * Performs an application-initiated interaction in which the user can select a\r
+ * {@linkplain Choice} from among the specified Choice Sets. For instance, an\r
+ * application may use a PerformInteraction to ask a user to say the name of a\r
+ * song to play. The user's response is only valid if it appears in the\r
+ * specified Choice Sets and is recognized by SMARTDEVICELINK\r
+ * <p>\r
+ * Function Group: Base\r
+ * <p>\r
+ * <b>HMILevel needs to be FULL</b>\r
+ * </p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ * @see CreateInteractionChoiceSet\r
+ * @see DeleteInteractionChoiceSet\r
+ */\r
+public class PerformInteraction extends RPCRequest {\r
+       /**\r
+        * Constructs a new PerformInteraction object\r
+        */\r
+    public PerformInteraction() {\r
+        super("PerformInteraction");\r
+    }\r
+       /**\r
+        * Constructs a new PerformInteraction object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */    \r
+    public PerformInteraction(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+       /**\r
+        * Gets the Text that Displayed when the interaction begins. This text may\r
+        * be overlaid by the "Listening" prompt during the interaction. Text is\r
+        * displayed on first line of multiline display, and is centered. If text\r
+        * does not fit on line, it will be truncated\r
+        * \r
+        * @return String -the text displayed when the interaction begins\r
+        */\r
+    public String getInitialText() {\r
+        return (String) parameters.get(Names.initialText);\r
+    }\r
+       /**\r
+        * Sets the Text that Displayed when the interaction begins. This text may\r
+        * be overlaid by the "Listening" prompt during the interaction. Text is\r
+        * displayed on first line of multiline display, and is centered. If text\r
+        * does not fit on line, it will be truncated\r
+        * \r
+        * @param initialText\r
+        *            a String value that Displayed when the interaction begins\r
+        */    \r
+    public void setInitialText(String initialText) {\r
+        if (initialText != null) {\r
+            parameters.put(Names.initialText, initialText);\r
+        } else {\r
+               parameters.remove(Names.initialText);\r
+        }\r
+    }\r
+       /**\r
+        * Gets an An array of one or more TTSChunks that, taken together, specify\r
+        * what is to be spoken to the user at the start of an interaction\r
+        * \r
+        * @return Vector<TTSChunk> -a Vector<TTSChunk> value, specify what is to be\r
+        *         spoken to the user at the start of an interaction\r
+        */\r
+    public Vector<TTSChunk> getInitialPrompt() {\r
+        if (parameters.get(Names.initialPrompt) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.initialPrompt);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof TTSChunk) {\r
+                       return (Vector<TTSChunk>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<TTSChunk> newList = new Vector<TTSChunk>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new TTSChunk((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+       /**\r
+        * Sets An array of one or more TTSChunks that, taken together, specify what\r
+        * is to be spoken to the user at the start of an interaction\r
+        * \r
+        * @param initialPrompt\r
+        *            a Vector<TTSChunk> value, specify what is to be spoken to the\r
+        *            user at the start of an interaction\r
+        */    \r
+    public void setInitialPrompt(Vector<TTSChunk> initialPrompt) {\r
+        if (initialPrompt != null) {\r
+            parameters.put(Names.initialPrompt, initialPrompt);\r
+        } else {\r
+               parameters.remove(Names.initialPrompt);\r
+        }\r
+    }\r
+       /**\r
+        * Gets the Indicates mode that indicate how user selects interaction\r
+        * choice. User can choose either by voice (VR_ONLY), by visual selection\r
+        * from the menu (MANUAL_ONLY), or by either mode (BOTH)\r
+        * \r
+        * @return InteractionMode -indicate how user selects interaction choice\r
+        *         (VR_ONLY, MANUAL_ONLY or BOTH)\r
+        */    \r
+    public InteractionMode getInteractionMode() {\r
+        Object obj = parameters.get(Names.interactionMode);\r
+        if (obj instanceof InteractionMode) {\r
+            return (InteractionMode) obj;\r
+        } else if (obj instanceof String) {\r
+            InteractionMode theCode = null;\r
+            try {\r
+                theCode = InteractionMode.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.interactionMode, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+       /**\r
+        * Sets the Indicates mode that indicate how user selects interaction\r
+        * choice. User can choose either by voice (VR_ONLY), by visual selection\r
+        * from the menu (MANUAL_ONLY), or by either mode (BOTH)\r
+        * \r
+        * @param interactionMode\r
+        *            indicate how user selects interaction choice (VR_ONLY,\r
+        *            MANUAL_ONLY or BOTH)\r
+        */    \r
+    public void setInteractionMode(InteractionMode interactionMode) {\r
+        if (interactionMode != null) {\r
+            parameters.put(Names.interactionMode, interactionMode);\r
+        } else {\r
+               parameters.remove(Names.interactionMode);\r
+        }\r
+    }\r
+       /**\r
+        * Gets a Vector<Integer> value representing an Array of one or more Choice\r
+        * Set IDs\r
+        * \r
+        * @return Vector<Integer> -a Vector<Integer> value representing an Array of\r
+        *         one or more Choice Set IDs. User can select any choice from any\r
+        *         of the specified Choice Sets\r
+        */    \r
+    public Vector<Integer> getInteractionChoiceSetIDList() {\r
+       if(parameters.get(Names.interactionChoiceSetIDList) instanceof Vector<?>){\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.interactionChoiceSetIDList);\r
+               if(list != null && list.size()>0){\r
+                       Object obj = list.get(0);\r
+                       if(obj instanceof Integer){\r
+                               return (Vector<Integer>) list;\r
+                       }\r
+               }\r
+       }\r
+        return null;\r
+    }\r
+       /**\r
+        * Sets a Vector<Integer> representing an Array of one or more Choice Set\r
+        * IDs. User can select any choice from any of the specified Choice Sets\r
+        * \r
+        * @param interactionChoiceSetIDList\r
+        *            -a Vector<Integer> representing an Array of one or more Choice\r
+        *            Set IDs. User can select any choice from any of the specified\r
+        *            Choice Sets\r
+        *            <p>\r
+        *            <b>Notes: </b>Min Value: 0; Max Vlaue: 2000000000\r
+        */    \r
+    public void setInteractionChoiceSetIDList(Vector<Integer> interactionChoiceSetIDList) {\r
+        if (interactionChoiceSetIDList != null) {\r
+            parameters.put(Names.interactionChoiceSetIDList, interactionChoiceSetIDList);\r
+        } else {\r
+               parameters.remove(Names.interactionChoiceSetIDList);\r
+        }\r
+    }\r
+       /**\r
+        * Gets a Vector<TTSChunk> which taken together, specify the help phrase to\r
+        * be spoken when the user says "help" during the VR session\r
+        * \r
+        * @return Vector<TTSChunk> -a Vector<TTSChunk> which taken together,\r
+        *         specify the help phrase to be spoken when the user says "help"\r
+        *         during the VR session\r
+        */    \r
+    public Vector<TTSChunk> getHelpPrompt() {\r
+        if(parameters.get(Names.helpPrompt) instanceof Vector<?>){\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.helpPrompt);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof TTSChunk) {\r
+                       return (Vector<TTSChunk>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<TTSChunk> newList = new Vector<TTSChunk>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new TTSChunk((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+       /**\r
+        * Sets An array of TTSChunks which, taken together, specify the help phrase\r
+        * to be spoken when the user says "help" during the VR session\r
+        * <p>\r
+        * If this parameter is omitted, the help prompt will be constructed by SMARTDEVICELINK\r
+        * from the first vrCommand of each choice of all the Choice Sets specified\r
+        * in the interactionChoiceSetIDList parameter\r
+        * <P>\r
+        * <b>Notes: </b>The helpPrompt specified in\r
+        * {@linkplain SetGlobalProperties} is not used by PerformInteraction\r
+        * \r
+        * @param helpPrompt\r
+        *            a Vector<TTSChunk> which taken together, specify the help\r
+        *            phrase to be spoken when the user says "help" during the VR\r
+        *            session\r
+        */    \r
+    public void setHelpPrompt(Vector<TTSChunk> helpPrompt) {\r
+        if (helpPrompt != null) {\r
+            parameters.put(Names.helpPrompt, helpPrompt);\r
+        } else {\r
+               parameters.remove(Names.helpPrompt);\r
+        }\r
+    }\r
+       /**\r
+        * Gets An array of TTSChunks which, taken together, specify the phrase to\r
+        * be spoken when the listen times out during the VR session\r
+        * \r
+        * @return Vector<TTSChunk> -a Vector<TTSChunk> specify the phrase to be\r
+        *         spoken when the listen times out during the VR session\r
+        */    \r
+    public Vector<TTSChunk> getTimeoutPrompt() {\r
+        if (parameters.get(Names.timeoutPrompt) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.timeoutPrompt);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof TTSChunk) {\r
+                       return (Vector<TTSChunk>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<TTSChunk> newList = new Vector<TTSChunk>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new TTSChunk((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+       /**\r
+        * Sets An array of TTSChunks which, taken together, specify the phrase to\r
+        * be spoken when the listen times out during the VR session\r
+        * <p>\r
+        * <b>Notes: </b>The timeoutPrompt specified in\r
+        * {@linkplain SetGlobalProperties} is not used by PerformInteraction\r
+        * \r
+        * @param timeoutPrompt\r
+        *            a Vector<TTSChunk> specify the phrase to be spoken when the\r
+        *            listen times out during the VR session\r
+        */    \r
+    public void setTimeoutPrompt(Vector<TTSChunk> timeoutPrompt) {\r
+        if (timeoutPrompt != null) {\r
+            parameters.put(Names.timeoutPrompt, timeoutPrompt);\r
+        } else {\r
+               parameters.remove(Names.timeoutPrompt);\r
+        }\r
+    }\r
+       /**\r
+        * Gets a Integer value representing the amount of time, in milliseconds,\r
+        * SMARTDEVICELINK will wait for the user to make a choice (VR or Menu)\r
+        * \r
+        * @return Integer -a Integer representing the amount of time, in\r
+        *         milliseconds, SMARTDEVICELINK will wait for the user to make a choice (VR or\r
+        *         Menu)\r
+        */    \r
+    public Integer getTimeout() {\r
+        return (Integer) parameters.get(Names.timeout);\r
+    }\r
+       /**\r
+        * Sets the amount of time, in milliseconds, SMARTDEVICELINK will wait for the user to\r
+        * make a choice (VR or Menu). If this time elapses without the user making\r
+        * a choice, the timeoutPrompt will be spoken. After this timeout value has\r
+        * been reached, the interaction will stop and a subsequent interaction will\r
+        * take place after SMARTDEVICELINK speaks the timeout prompt. If that times out as\r
+        * well, the interaction will end completely. If omitted, the default is\r
+        * 10000ms\r
+        * \r
+        * @param timeout\r
+        *            an Integer value representing the amount of time, in\r
+        *            milliseconds, SMARTDEVICELINK will wait for the user to make a choice (VR\r
+        *            or Menu)\r
+        *            <p>\r
+        *            <b>Notes: </b>Min Value: 5000; Max Value: 100000\r
+        */    \r
+    public void setTimeout(Integer timeout) {\r
+        if (timeout != null) {\r
+            parameters.put(Names.timeout, timeout);\r
+        } else {\r
+               parameters.remove(Names.timeout);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a Voice recognition Help, which is a suggested VR Help Items to\r
+        * display on-screen during Perform Interaction\r
+        * \r
+        * @return Vector<VrHelpItem> -a Vector value representing a suggested VR\r
+        *         Help Items to display on-screen during Perform Interaction\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public Vector<VrHelpItem> getVrHelp() {\r
+        if (parameters.get(Names.vrHelp) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.vrHelp);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof VrHelpItem) {\r
+                       return (Vector<VrHelpItem>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<VrHelpItem> newList = new Vector<VrHelpItem>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new VrHelpItem((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * \r
+        * @param vrHelp\r
+        *            a Vector representing a suggested VR Help Items to display\r
+        *            on-screen during Perform Interaction<br/>\r
+        *            If omitted on supported displays, the default SMARTDEVICELINK generated\r
+        *            list of suggested choices will be displayed\r
+        *            <p>\r
+        *            <b>Notes: </b>Min=1; Max=100\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public void setVrHelp(Vector<VrHelpItem> vrHelp) {\r
+        if (vrHelp != null) {\r
+            parameters.put(Names.vrHelp, vrHelp);\r
+        } else {\r
+               parameters.remove(Names.vrHelp);\r
+        }\r
+    }\r
+}\r
index 6a55c48..0c263ba 100755 (executable)
@@ -1,49 +1,80 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCResponse;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.TriggerSource;
-import com.smartdevicelink.util.DebugTool;
-
-public class PerformInteractionResponse extends RPCResponse {
-
-    public PerformInteractionResponse() {
-        super("PerformInteraction");
-    }
-    public PerformInteractionResponse(Hashtable hash) {
-        super(hash);
-    }
-    public Integer getChoiceID() {
-        return (Integer) parameters.get( Names.choiceID );
-    }
-    public void setChoiceID( Integer choiceID ) {
-        if (choiceID != null) {
-            parameters.put(Names.choiceID, choiceID );
-        }
-    }
-    public TriggerSource getTriggerSource() {
-        Object obj = parameters.get(Names.triggerSource);
-        if (obj instanceof TriggerSource) {
-            return (TriggerSource) obj;
-        } else if (obj instanceof String) {
-            TriggerSource theCode = null;
-            try {
-                theCode = TriggerSource.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.triggerSource, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setTriggerSource( TriggerSource triggerSource ) {
-        if (triggerSource != null) {
-            parameters.put(Names.triggerSource, triggerSource );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.TriggerSource;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * PerformInteraction Response is sent, when PerformInteraction has been called\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class PerformInteractionResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new PerformInteractionResponse object\r
+        */\r
+    public PerformInteractionResponse() {\r
+        super("PerformInteraction");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new PerformInteractionResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public PerformInteractionResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * Gets the application-scoped identifier that uniquely identifies this choice.\r
+     * @return choiceID Min: 0  Max: 65535\r
+     */   \r
+    public Integer getChoiceID() {\r
+        return (Integer) parameters.get( Names.choiceID );\r
+    }\r
+    /**\r
+     * Sets the application-scoped identifier that uniquely identifies this choice.\r
+     * @param choiceID Min: 0  Max: 65535\r
+     */ \r
+    public void setChoiceID( Integer choiceID ) {\r
+        if (choiceID != null) {\r
+            parameters.put(Names.choiceID, choiceID );\r
+        }\r
+    }\r
+    /**\r
+     * <p>Returns a <I>TriggerSource</I> object which will be shown in the HMI</p>    \r
+     * @return TriggerSource a TriggerSource object\r
+     */    \r
+    public TriggerSource getTriggerSource() {\r
+        Object obj = parameters.get(Names.triggerSource);\r
+        if (obj instanceof TriggerSource) {\r
+            return (TriggerSource) obj;\r
+        } else if (obj instanceof String) {\r
+            TriggerSource theCode = null;\r
+            try {\r
+                theCode = TriggerSource.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.triggerSource, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * <p>Sets TriggerSource<br/>\r
+     * Indicates whether command was selected via VR or via a menu selection (using the OK button).</p>    \r
+     * @param triggerSource a TriggerSource object\r
+     */    \r
+    public void setTriggerSource( TriggerSource triggerSource ) {\r
+        if (triggerSource != null) {\r
+            parameters.put(Names.triggerSource, triggerSource );\r
+        }\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PermissionGroupItem.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PermissionGroupItem.java
deleted file mode 100755 (executable)
index 553acfa..0000000
+++ /dev/null
@@ -1,51 +0,0 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCStruct;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.PermissionStatus;
-import com.smartdevicelink.util.DebugTool;
-
-public class PermissionGroupItem extends RPCStruct {
-       
-       public PermissionGroupItem() { }
-    public PermissionGroupItem(Hashtable hash) {
-        super(hash);
-    }
-    public String getPermissionGroupName() {
-       Object obj = store.get(Names.PermissionGroupName);
-       if (obj instanceof String) {
-               return (String)obj;
-       }
-       return null;
-    }
-    public void setPermissionGroupName(String permissionGroupName) {
-       if (permissionGroupName != null) {
-               store.put(Names.PermissionGroupName, permissionGroupName);
-       }
-    }
-    public PermissionStatus getPermissionGroupStatus() {
-       Object obj = store.get(Names.PermissionGroupStatus);
-       if (obj instanceof PermissionStatus) {
-               return (PermissionStatus)obj;
-       } else if(obj instanceof String) {
-               PermissionStatus theCode = null;
-               try {
-                       theCode = PermissionStatus.valueForString((String) obj);
-               } catch (Exception e) {
-                DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.name, e);
-            }
-               return theCode;
-       }
-       return null;
-    }
-    public void setPermissionGroupStatus(PermissionStatus permissionStatus) {
-       if (permissionStatus != null) {
-               store.put(Names.PermissionGroupStatus, permissionStatus);
-       }
-    }
-}
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PermissionItem.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PermissionItem.java
new file mode 100755 (executable)
index 0000000..75563e1
--- /dev/null
@@ -0,0 +1,65 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+public class PermissionItem extends RPCStruct {\r
+\r
+    public PermissionItem() { }\r
+    public PermissionItem(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public String getRpcName() {\r
+        return (String) store.get(Names.rpcName);\r
+    }\r
+    public void setRpcName(String rpcName) {\r
+        if (rpcName != null) {\r
+               store.put(Names.rpcName, rpcName);\r
+        } else {\r
+               store.remove(Names.rpcName);\r
+        }\r
+    }\r
+    public HMIPermissions getHMIPermissions() {\r
+       Object obj = store.get(Names.hmiPermissions);\r
+        if (obj instanceof HMIPermissions) {\r
+            return (HMIPermissions) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new HMIPermissions((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.hmiPermissions, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setHMIPermissions(HMIPermissions hmiPermissions) {\r
+        if (hmiPermissions != null) {\r
+               store.put(Names.hmiPermissions, hmiPermissions);\r
+        } else {\r
+               store.remove(Names.hmiPermissions);\r
+        }\r
+    }\r
+    public ParameterPermissions getParameterPermissions() {\r
+       Object obj = store.get(Names.parameterPermissions);\r
+        if (obj instanceof ParameterPermissions) {\r
+            return (ParameterPermissions) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new ParameterPermissions((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.parameterPermissions, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setParameterPermissions(ParameterPermissions parameterPermissions) {\r
+        if (parameterPermissions != null) {\r
+               store.put(Names.parameterPermissions, parameterPermissions);\r
+        } else {\r
+               store.remove(Names.parameterPermissions);\r
+        }\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PresetBankCapabilities.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PresetBankCapabilities.java
new file mode 100755 (executable)
index 0000000..2cdf154
--- /dev/null
@@ -0,0 +1,62 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Contains information about on-screen preset capabilities.\r
+ * <p><b>Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>onScreenPresetsAvailable</td>\r
+ *                     <td>Boolean</td>\r
+ *                     <td>Defines, if Onscreen custom presets are available.\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *  </table>\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class PresetBankCapabilities extends RPCStruct {\r
+\r
+       /**\r
+        * Constructs a newly allocated PresetBankCapabilities object\r
+        */\r
+    public PresetBankCapabilities() { }\r
+    \r
+    /**\r
+     * Constructs a newly allocated PresetBankCapabilities object indicated by the Hashtable parameter\r
+     * @param hash The Hashtable to use\r
+     */\r
+    public PresetBankCapabilities(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    \r
+    /**\r
+     * set if Onscreen custom presets are available.\r
+     * @param onScreenPresetsAvailable if Onscreen custom presets are available.\r
+     */\r
+    public void setOnScreenPresetsAvailable(Boolean onScreenPresetsAvailable) {\r
+       if (onScreenPresetsAvailable != null) {\r
+               store.put(Names.OnScreenPresetsAvailable, onScreenPresetsAvailable);\r
+       } else {\r
+               store.remove(Names.OnScreenPresetsAvailable);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * Defines, if Onscreen custom presets are available.\r
+     * @return if Onscreen custom presets are available\r
+     */\r
+    public Boolean onScreenPresetsAvailable() {\r
+       return (Boolean) store.get(Names.OnScreenPresetsAvailable);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PutFile.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PutFile.java
new file mode 100755 (executable)
index 0000000..14c388c
--- /dev/null
@@ -0,0 +1,140 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.FileType;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Used to push a binary data onto the SMARTDEVICELINK module from a mobile device, such as\r
+ * icons and album art\r
+ * <p>\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ * @see DeleteFile\r
+ * @see ListFiles\r
+ */\r
+public class PutFile extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new PutFile object\r
+        */\r
+    public PutFile() {\r
+        super("PutFile");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new PutFile object indicated by the Hashtable parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public PutFile(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+\r
+       /**\r
+        * Sets a file reference name\r
+        * \r
+        * @param smartDeviceLinkFileName\r
+        *            a String value representing a file reference name\r
+        *            <p>\r
+        *            <b>Notes: </b>Maxlength=500\r
+        */\r
+    public void setSmartDeviceLinkFileName(String smartDeviceLinkFileName) {\r
+        if (smartDeviceLinkFileName != null) {\r
+            parameters.put(Names.smartDeviceLinkFileName, smartDeviceLinkFileName);\r
+        } else {\r
+               parameters.remove(Names.smartDeviceLinkFileName);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a file reference name\r
+        * \r
+        * @return String - a String value representing a file reference name\r
+        */\r
+    public String getSmartDeviceLinkFileName() {\r
+        return (String) parameters.get(Names.smartDeviceLinkFileName);\r
+    }\r
+\r
+       /**\r
+        * Sets file type\r
+        * \r
+        * @param fileType\r
+        *            a FileType value representing a selected file type\r
+        */\r
+    public void setFileType(FileType fileType) {\r
+        if (fileType != null) {\r
+            parameters.put(Names.fileType, fileType);\r
+        } else {\r
+               parameters.remove(Names.fileType);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a file type\r
+        * \r
+        * @return FileType -a FileType value representing a selected file type\r
+        */\r
+    public FileType getFileType() {\r
+        Object obj = parameters.get(Names.fileType);\r
+        if (obj instanceof FileType) {\r
+            return (FileType) obj;\r
+        } else if (obj instanceof String) {\r
+               FileType theCode = null;\r
+            try {\r
+                theCode = FileType.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.fileType, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * Sets a value to indicates if the file is meant to persist between\r
+        * sessions / ignition cycles. If set to TRUE, then the system will aim to\r
+        * persist this file through session / cycles. While files with this\r
+        * designation will have priority over others, they are subject to deletion\r
+        * by the system at any time. In the event of automatic deletion by the\r
+        * system, the app will receive a rejection and have to resend the file. If\r
+        * omitted, the value will be set to false\r
+        * <p>\r
+        * \r
+        * @param persistentFile\r
+        *            a Boolean value\r
+        */\r
+    public void setPersistentFile(Boolean persistentFile) {\r
+        if (persistentFile != null) {\r
+            parameters.put(Names.persistentFile, persistentFile);\r
+        } else {\r
+               parameters.remove(Names.persistentFile);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a value to Indicates if the file is meant to persist between\r
+        * sessions / ignition cycles\r
+        * \r
+        * @return Boolean -a Boolean value to indicates if the file is meant to\r
+        *         persist between sessions / ignition cycles\r
+        */\r
+    public Boolean getPersistentFile() {\r
+        return (Boolean) parameters.get(Names.persistentFile);\r
+    }\r
+    public void setFileData(byte[] fileData) {\r
+        if (fileData != null) {\r
+            parameters.put(Names.bulkData, fileData);\r
+        } else {\r
+               parameters.remove(Names.bulkData);\r
+        }\r
+    }\r
+    public byte[] getFileData() {\r
+        return (byte[]) parameters.get(Names.bulkData);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PutFileResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/PutFileResponse.java
new file mode 100755 (executable)
index 0000000..a1285ee
--- /dev/null
@@ -0,0 +1,43 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Put File Response is sent, when PutFile has been called\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class PutFileResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new PutFileResponse object\r
+        */\r
+    public PutFileResponse() {\r
+        super("PutFile");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new PutFileResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public PutFileResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public void setSpaceAvailable(Integer spaceAvailable) {\r
+        if (spaceAvailable != null) {\r
+            parameters.put(Names.spaceAvailable, spaceAvailable);\r
+        } else {\r
+               parameters.remove(Names.spaceAvailable);\r
+        }\r
+    }\r
+    public Integer getSpaceAvailable() {\r
+        return (Integer) parameters.get(Names.spaceAvailable);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ReadDID.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ReadDID.java
new file mode 100755 (executable)
index 0000000..a8d73bf
--- /dev/null
@@ -0,0 +1,106 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Non periodic vehicle data read request. This is an RPC to get diagnostics\r
+ * data from certain vehicle modules. DIDs of a certain module might differ from\r
+ * vehicle type to vehicle type\r
+ * <p>\r
+ * Function Group: ProprietaryData\r
+ * <p>\r
+ * <b>HMILevel needs to be FULL, LIMITED or BACKGROUND</b>\r
+ * <p>\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class ReadDID extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new ReadDID object\r
+        */\r
+    public ReadDID() {\r
+        super("ReadDID");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new ReadDID object indicated by the Hashtable parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public ReadDID(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+\r
+       /**\r
+        * Sets an ID of the vehicle module\r
+        * \r
+        * @param ecuName\r
+        *            an Integer value representing the ID of the vehicle module\r
+        *            <p>\r
+        *            <b>Notes: </b>Minvalue:0; Maxvalue:65535\r
+        */\r
+    public void setEcuName(Integer ecuName) {\r
+       if (ecuName != null) {\r
+               parameters.put(Names.ecuName, ecuName);\r
+       } else {\r
+               parameters.remove(Names.ecuName);\r
+       }\r
+    }\r
+\r
+       /**\r
+        * Gets the ID of the vehicle module\r
+        * \r
+        * @return Integer -an Integer value representing the ID of the vehicle\r
+        *         module\r
+        */\r
+    public Integer getEcuName() {\r
+       return (Integer) parameters.get(Names.ecuName);\r
+    }\r
+\r
+       /**\r
+        * Sets raw data from vehicle data DID location(s)\r
+        * \r
+        * @param didLocation\r
+        *            a Vector<Integer> value representing raw data from vehicle\r
+        *            data DID location(s)\r
+        *            <p>\r
+        *            <b>Notes: </b>\r
+        *            <ul>\r
+        *            <li>Minvalue:0; Maxvalue:65535</li>\r
+        *            <li>ArrayMin:0; ArrayMax:1000</li>\r
+        *            </ul>\r
+        */\r
+    public void setDidLocation(Vector<Integer> didLocation) {\r
+       if (didLocation != null) {\r
+               parameters.put(Names.didLocation, didLocation);\r
+       } else {\r
+               parameters.remove(Names.didLocation);\r
+       }\r
+    }\r
+\r
+       /**\r
+        * Gets raw data from vehicle data DID location(s)\r
+        * \r
+        * @return Vector<Integer> -a Vector<Integer> value representing raw data\r
+        *         from vehicle data DID location(s)\r
+        */\r
+    public Vector<Integer> getDidLocation() {\r
+        if (parameters.get(Names.didLocation) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.didLocation);\r
+               if (list != null && list.size() > 0) {\r
+                       Object obj = list.get(0);\r
+                       if (obj instanceof Integer) {\r
+                       return (Vector<Integer>) list;                          \r
+                       }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ReadDIDResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ReadDIDResponse.java
new file mode 100755 (executable)
index 0000000..023e1db
--- /dev/null
@@ -0,0 +1,49 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.VehicleDataResultCode;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Read DID Response is sent, when ReadDID has been called\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class ReadDIDResponse extends RPCResponse {\r
+\r
+    public ReadDIDResponse() {\r
+        super("ReadDID");\r
+    }\r
+    public ReadDIDResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public void setDidResult(Vector<DIDResult> didResult) {\r
+       if (didResult != null) {\r
+               parameters.put(Names.didResult, didResult);\r
+       } else {\r
+               parameters.remove(Names.didResult);\r
+       }\r
+    }\r
+    public Vector<DIDResult> getDidResult() {\r
+        if (parameters.get(Names.didResult) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.didResult);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof DIDResult) {\r
+                       return (Vector<DIDResult>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<DIDResult> newList = new Vector<DIDResult>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new DIDResult((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+}
\ No newline at end of file
index d27688d..cf51b73 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-import java.util.Vector;
-
-import com.smartdevicelink.proxy.RPCRequest;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.Language;
-import com.smartdevicelink.util.DebugTool;
-
-public class RegisterAppInterface extends RPCRequest {
-
-    public RegisterAppInterface() {
-        super("RegisterAppInterface");
-    }
-    public RegisterAppInterface(Hashtable hash) {
-        super(hash);
-    }
-    public SyncMsgVersion getSyncMsgVersion() {
-        Object obj = parameters.get(Names.syncMsgVersion);
-        if (obj instanceof SyncMsgVersion) {
-               return (SyncMsgVersion)obj;
-        } else if (obj instanceof Hashtable) {
-               return new SyncMsgVersion((Hashtable)obj);
-        }
-        return null;
-    }
-    public void setSyncMsgVersion( SyncMsgVersion SyncMsgVersion ) {
-        if (SyncMsgVersion != null) {
-            parameters.put(Names.syncMsgVersion, SyncMsgVersion );
-        }
-    }
-    public String getAppName() {
-        return (String) parameters.get( Names.appName );
-    }
-    public void setAppName( String appName ) {
-        if (appName != null) {
-            parameters.put(Names.appName, appName );
-        }
-    }
-    public String getNgnMediaScreenAppName() {
-        return (String) parameters.get( Names.ngnMediaScreenAppName );
-    }
-    public void setNgnMediaScreenAppName( String ngnMediaScreenAppName ) {
-        if (ngnMediaScreenAppName != null) {
-            parameters.put(Names.ngnMediaScreenAppName, ngnMediaScreenAppName );
-        }
-    }
-    public Vector<String> getVrSynonyms() {
-       if (parameters.get( Names.vrSynonyms ) instanceof Vector<?>) {
-               Vector<?> list = (Vector<?>)parameters.get( Names.vrSynonyms );
-               if (list != null && list.size()>0) {
-                       Object obj = list.get(0);
-                       if (obj instanceof String) {
-                               return (Vector<String>) list;
-                       }
-               }
-       }
-        return null;
-    }
-    public void setVrSynonyms( Vector<String> vrSynonyms ) {
-        if (vrSynonyms != null) {
-            parameters.put(Names.vrSynonyms, vrSynonyms );
-        }
-    }
-    public Boolean getIsMediaApplication() {
-        return (Boolean) parameters.get( Names.isMediaApplication );
-    }
-    public void setIsMediaApplication( Boolean isMediaApplication ) {
-        if (isMediaApplication != null) {
-            parameters.put(Names.isMediaApplication, isMediaApplication );
-        }
-    }
-    public Language getLanguageDesired() {
-        Object obj = parameters.get(Names.languageDesired);
-        if (obj instanceof Language) {
-            return (Language) obj;
-        } else if (obj instanceof String) {
-            Language theCode = null;
-            try {
-                theCode = Language.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.languageDesired, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setLanguageDesired( Language languageDesired ) {
-        if (languageDesired != null) {
-            parameters.put(Names.languageDesired, languageDesired );
-        }
-    }
-    public String getAutoActivateID() {
-        return (String) parameters.get( Names.autoActivateID );
-    }
-    public void setAutoActivateID( String autoActivateID ) {
-        if (autoActivateID != null) {
-            parameters.put(Names.autoActivateID, autoActivateID );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.AppHMIType;\r
+import com.smartdevicelink.proxy.rpc.enums.Language;\r
+import com.smartdevicelink.util.DebugTool;\r
+/**\r
+ * Registers the application's interface with SMARTDEVICELINK&reg;, declaring properties of\r
+ * the registration, including the messaging interface version, the app name,\r
+ * etc. The mobile application must establish its interface registration with\r
+ * SMARTDEVICELINK&reg; before any other interaction with SMARTDEVICELINK&reg; can take place. The\r
+ * registration lasts until it is terminated either by the application calling\r
+ * the <i> {@linkplain UnregisterAppInterface}</i> method, or by SMARTDEVICELINK&reg;\r
+ * sending an <i> {@linkplain OnAppInterfaceUnregistered}</i> notification, or\r
+ * by loss of the underlying transport connection, or closing of the underlying\r
+ * message transmission protocol RPC session\r
+ * <p>\r
+ * Until the application receives its first <i>{@linkplain OnHMIStatus}</i>\r
+ * Notification, its HMI Status is assumed to be: <i>\r
+ * {@linkplain com.smartdevicelink.proxy.rpc.enums.HMILevel}</i>=NONE, <i>\r
+ * {@linkplain com.smartdevicelink.proxy.rpc.enums.AudioStreamingState}\r
+ * </i>=NOT_AUDIBLE, <i>\r
+ * {@linkplain com.smartdevicelink.proxy.rpc.enums.SystemContext}</i>=MAIN\r
+ * <p>\r
+ * All SMARTDEVICELINK&reg; resources which the application creates or uses (e.g. Choice\r
+ * Sets, Command Menu, etc.) are associated with the application's interface\r
+ * registration. Therefore, when the interface registration ends, the SMARTDEVICELINK&reg;\r
+ * resources associated with the application are disposed of. As a result, even\r
+ * though the application itself may continue to run on its host platform (e.g.\r
+ * mobile device) after the interface registration terminates, the application\r
+ * will not be able to use the SMARTDEVICELINK&reg; HMI without first establishing a new\r
+ * interface registration and re-creating its required SMARTDEVICELINK&reg; resources. That\r
+ * is, SMARTDEVICELINK&reg; resources created by (or on behalf of) an application do not\r
+ * persist beyond the life-span of the interface registration\r
+ * <p>\r
+ * Resources and settings whose lifespan is tied to the duration of an\r
+ * application's interface registration:<br/>\r
+ * <ul>\r
+ * <li>Choice Sets</li>\r
+ * <li>Command Menus (built by successive calls to <i>{@linkplain AddCommand}\r
+ * </i>)</li>\r
+ * <li>Media clock timer display value</li>\r
+ * <li>Media clock timer display value</li>\r
+ * <li>Media clock timer display value</li>\r
+ * </ul>\r
+ * <p>\r
+ * The autoActivateID is used to grant an application the HMILevel and\r
+ * AudioStreamingState it had when it last disconnected\r
+ * <p>\r
+ * <b>Notes: </b>The autoActivateID parameter, and associated behavior, is\r
+ * currently ignored by SMARTDEVICELINK&reg;\r
+ * <p>\r
+ * When first calling this method (i.e. first time within life cycle of mobile\r
+ * app), an autoActivateID should not be included. After successfully\r
+ * registering an interface, an autoActivateID is returned to the mobile\r
+ * application for it to use in subsequent connections. If the connection\r
+ * between SMARTDEVICELINK&reg; and the mobile application is lost, such as the vehicle is\r
+ * turned off while the application is running, the autoActivateID can then be\r
+ * passed in another call to RegisterAppInterface to re-acquire <i>\r
+ * {@linkplain com.smartdevicelink.proxy.rpc.enums.HMILevel}</i>=FULL\r
+ * <p>\r
+ * If the application intends to stream audio it is important to indicate so via\r
+ * the isMediaApp parameter. When set to true, audio will reliably stream\r
+ * without any configuration required by the user. When not set, audio may\r
+ * stream, depending on what the user might have manually configured as a media\r
+ * source on SMARTDEVICELINK&reg;\r
+ * <p>\r
+ * There is no time limit for how long the autoActivateID is "valid" (i.e. would\r
+ * confer focus and opt-in)\r
+ * <p>\r
+ * <b>HMILevel is not defined before registering</b><br/>\r
+ * </p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ * @see UnregisterAppInterface\r
+ * @see OnAppInterfaceUnregistered\r
+ */\r
+public class RegisterAppInterface extends RPCRequest {\r
+       /**\r
+        * Constructs a new RegisterAppInterface object\r
+        */\r
+    public RegisterAppInterface() {\r
+        super("RegisterAppInterface");\r
+    }\r
+       /**\r
+        * Constructs a new RegisterAppInterface object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */    \r
+    public RegisterAppInterface(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+       /**\r
+        * Gets the version of the SMARTDEVICELINK&reg; SmartDeviceLink interface\r
+        * \r
+        * @return smartdevicelinkMsgVersion -a smartdevicelinkMsgVersion object representing version of\r
+        *         the SMARTDEVICELINK&reg; SmartDeviceLink interface\r
+        */    \r
+    public smartdevicelinkMsgVersion getsmartdevicelinkMsgVersion() {\r
+        Object obj = parameters.get(Names.smartDeviceLinkMsgVersion);\r
+        if (obj instanceof smartdevicelinkMsgVersion) {\r
+               return (smartdevicelinkMsgVersion) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               return new smartdevicelinkMsgVersion((Hashtable) obj);\r
+        }\r
+        return null;\r
+    }\r
+       /**\r
+        * Sets the version of the SMARTDEVICELINK&reg; SmartDeviceLink interface\r
+        * \r
+        * @param smartDeviceLinkMsgVersion\r
+        *            a smartdevicelinkMsgVersion object representing version of the SMARTDEVICELINK&reg;\r
+        *            SmartDeviceLink interface\r
+        *            <p>\r
+        *            <b>Notes: </b>To be compatible, app msg major version number\r
+        *            must be less than or equal to SMARTDEVICELINK&reg; major version number.\r
+        *            If msg versions are incompatible, app has 20 seconds to\r
+        *            attempt successful RegisterAppInterface (w.r.t. msg version)\r
+        *            on underlying protocol session, else will be terminated. Major\r
+        *            version number is a compatibility declaration. Minor version\r
+        *            number indicates minor functional variations (e.g. features,\r
+        *            capabilities, bug fixes) when sent from SMARTDEVICELINK&reg; to app (in\r
+        *            RegisterAppInterface response). However, the minor version\r
+        *            number sent from the app to SMARTDEVICELINK&reg; (in RegisterAppInterface\r
+        *            request) is ignored by SMARTDEVICELINK&reg;\r
+        */    \r
+    public void setsmartdevicelinkMsgVersion(smartdevicelinkMsgVersion smartDeviceLinkMsgVersion) {\r
+        if (smartDeviceLinkMsgVersion != null) {\r
+            parameters.put(Names.smartDeviceLinkMsgVersion, smartDeviceLinkMsgVersion);\r
+        } else {\r
+               parameters.remove(Names.smartDeviceLinkMsgVersion);\r
+        }\r
+    }\r
+       /**\r
+        * Gets Mobile Application's Name\r
+        * \r
+        * @return String -a String representing the Mobile Application's Name\r
+        */    \r
+    public String getAppName() {\r
+        return (String) parameters.get(Names.appName);\r
+    }\r
+       /**\r
+        * Sets Mobile Application's Name, This name is displayed in the SMARTDEVICELINK&reg;\r
+        * Mobile Applications menu. It also serves as the unique identifier of the\r
+        * application for SmartDeviceLink\r
+        * \r
+        * @param appName\r
+        *            a String value representing the Mobile Application's Name\r
+        *            <p>\r
+        *            <b>Notes: </b>\r
+        *            <ul>\r
+        *            <li>Must be 1-100 characters in length</li>\r
+        *            <li>May not be the same (by case insensitive comparison) as\r
+        *            the name or any synonym of any currently-registered\r
+        *            application</li>\r
+        *            </ul>\r
+        */    \r
+    public void setAppName(String appName) {\r
+        if (appName != null) {\r
+            parameters.put(Names.appName, appName);\r
+        } else {\r
+               parameters.remove(Names.appName);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets TTS string for VR recognition of the mobile application name\r
+        * \r
+        * @return Vector<TTSChunk> -Vector value representing the TTS string\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public Vector<TTSChunk> getTtsName() {\r
+        if (parameters.get(Names.ttsName) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.ttsName);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof TTSChunk) {\r
+                       return (Vector<TTSChunk>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<TTSChunk> newList = new Vector<TTSChunk>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new TTSChunk((Hashtable) hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * \r
+        * @param ttsName\r
+        *            a Vector<TTSChunk> value represeting the TTS Name\r
+        *            <p>\r
+        *            <b>Notes: </b><br/>\r
+        *            <ul>\r
+        *            <li>Size must be 1-100</li>\r
+        *            <li>Needs to be unique over all applications</li>\r
+        *            <li>May not be empty</li>\r
+        *            <li>May not start with a new line character</li>\r
+        *            <li>May not interfere with any name or synonym of previously\r
+        *            registered applications and the following list of words</li>\r
+        *            <li>Needs to be unique over all applications. Applications\r
+        *            with the same name will be rejected</li>\r
+        *            </ul>\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public void setTtsName(Vector<TTSChunk> ttsName) {\r
+        if (ttsName != null) {\r
+            parameters.put(Names.ttsName, ttsName);\r
+        } else {\r
+               parameters.remove(Names.ttsName);\r
+        }\r
+    }\r
+       /**\r
+        * Gets a String representing an abbreviated version of the mobile\r
+        * applincation's name (if necessary) that will be displayed on the NGN\r
+        * media screen\r
+        * \r
+        * @return String -a String value representing an abbreviated version of the\r
+        *         mobile applincation's name\r
+        */    \r
+    public String getNgnMediaScreenAppName() {\r
+        return (String) parameters.get(Names.ngnMediaScreenAppName);\r
+    }\r
+       /**\r
+        * Sets a String representing an abbreviated version of the mobile\r
+        * applincation's name (if necessary) that will be displayed on the NGN\r
+        * media screen\r
+        * \r
+        * @param ngnMediaScreenAppName\r
+        *            a String value representing an abbreviated version of the\r
+        *            mobile applincation's name\r
+        *            <p>\r
+        *            <b>Notes: </b>\r
+        *            <ul>\r
+        *            <li>Must be 1-5 characters</li>\r
+        *            <li>If not provided, value will be derived from appName\r
+        *            truncated to 5 characters</li>\r
+        *            </ul>\r
+        */    \r
+    public void setNgnMediaScreenAppName(String ngnMediaScreenAppName) {\r
+        if (ngnMediaScreenAppName != null) {\r
+            parameters.put(Names.ngnMediaScreenAppName, ngnMediaScreenAppName);\r
+        } else {\r
+               parameters.remove(Names.ngnMediaScreenAppName);\r
+        }\r
+    }\r
+       /**\r
+        * Gets the Vector<String> representing the an array of 1-100 elements, each\r
+        * element containing a voice-recognition synonym\r
+        * \r
+        * @return Vector<String> -a Vector value representing the an array of\r
+        *         1-100 elements, each element containing a voice-recognition\r
+        *         synonym\r
+        */    \r
+    public Vector<String> getVrSynonyms() {\r
+       if (parameters.get(Names.vrSynonyms) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.vrSynonyms);\r
+               if (list != null && list.size()>0) {\r
+                       Object obj = list.get(0);\r
+                       if (obj instanceof String) {\r
+                               return (Vector<String>) list;\r
+                       }\r
+               }\r
+       }\r
+        return null;\r
+    }\r
+       /**\r
+        * Sets a vrSynonyms representing the an array of 1-100 elements, each\r
+        * element containing a voice-recognition synonym\r
+        * \r
+        * @param vrSynonyms\r
+        *            a Vector<String> value representing the an array of 1-100\r
+        *            elements\r
+        *            <p>\r
+        *            <b>Notes: </b>\r
+        *            <ul>\r
+        *            <li>Each vr synonym is limited to 40 characters, and there can\r
+        *            be 1-100 synonyms in array</li>\r
+        *            <li>May not be the same (by case insensitive comparison) as\r
+        *            the name or any synonym of any currently-registered\r
+        *            application</li>\r
+        *            </ul>\r
+        */    \r
+    public void setVrSynonyms(Vector<String> vrSynonyms) {\r
+        if (vrSynonyms != null) {\r
+            parameters.put(Names.vrSynonyms, vrSynonyms);\r
+        } else {\r
+               parameters.remove(Names.vrSynonyms);\r
+        }\r
+    }\r
+       /**\r
+        * Gets a Boolean representing MediaApplication\r
+        * \r
+        * @return Boolean -a Boolean value representing a mobile application that is\r
+        *         a media application or not\r
+        */    \r
+    public Boolean getIsMediaApplication() {\r
+        return (Boolean) parameters.get(Names.isMediaApplication);\r
+    }\r
+       /**\r
+        * Sets a Boolean to indicate a mobile application that is a media\r
+        * application or not\r
+        * \r
+        * @param isMediaApplication\r
+        *            a Boolean value\r
+        */    \r
+    public void setIsMediaApplication(Boolean isMediaApplication) {\r
+        if (isMediaApplication != null) {\r
+            parameters.put(Names.isMediaApplication, isMediaApplication);\r
+        } else {\r
+               parameters.remove(Names.isMediaApplication);\r
+        }\r
+    }\r
+       /**\r
+        * Gets a Language enumeration indicating what language the application\r
+        * intends to use for user interaction (Display, TTS and VR)\r
+        * \r
+        * @return Enumeration -a language enumeration\r
+        */    \r
+    public Language getLanguageDesired() {\r
+        Object obj = parameters.get(Names.languageDesired);\r
+        if (obj instanceof Language) {\r
+            return (Language) obj;\r
+        } else if (obj instanceof String) {\r
+            Language theCode = null;\r
+            try {\r
+                theCode = Language.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.languageDesired, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+       /**\r
+        * Sets an enumeration indicating what language the application intends to\r
+        * use for user interaction (Display, TTS and VR)\r
+        * \r
+        * @param languageDesired\r
+        *            a Language Enumeration\r
+        *            <p>\r
+        * \r
+        */    \r
+    public void setLanguageDesired(Language languageDesired) {\r
+        if (languageDesired != null) {\r
+            parameters.put(Names.languageDesired, languageDesired);\r
+        } else {\r
+               parameters.remove(Names.languageDesired);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets an enumeration indicating what language the application intends to\r
+        * use for user interaction ( Display)\r
+        * \r
+        * @return Language - a Language value representing an enumeration\r
+        *         indicating what language the application intends to use for user\r
+        *         interaction ( Display)\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public Language getHmiDisplayLanguageDesired() {\r
+        Object obj = parameters.get(Names.hmiDisplayLanguageDesired);\r
+        if (obj instanceof Language) {\r
+            return (Language) obj;\r
+        } else if (obj instanceof String) {\r
+            Language theCode = null;\r
+            try {\r
+                theCode = Language.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.hmiDisplayLanguageDesired, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * Sets an enumeration indicating what language the application intends to\r
+        * use for user interaction ( Display)\r
+        * \r
+        * @param hmiDisplayLanguageDesired\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public void setHmiDisplayLanguageDesired(Language hmiDisplayLanguageDesired) {\r
+        if (hmiDisplayLanguageDesired != null) {\r
+            parameters.put(Names.hmiDisplayLanguageDesired, hmiDisplayLanguageDesired);\r
+        } else {\r
+               parameters.remove(Names.hmiDisplayLanguageDesired);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a list of all applicable app types stating which classifications to\r
+        * be given to the app.e.g. for platforms , like GEN2, this will determine\r
+        * which "corner(s)" the app can populate\r
+        * \r
+        * @return Vector<AppHMIType> - a Vector value representing a list of all\r
+        *         applicable app types stating which classifications to be given to\r
+        *         the app\r
+        * @since SmartDeviceLinke 2.0\r
+        */\r
+    public Vector<AppHMIType> getAppHMIType() {\r
+        if (parameters.get(Names.appHMIType) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.appHMIType);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof AppHMIType) {\r
+                       return (Vector<AppHMIType>) list;\r
+                   } else if (obj instanceof String) {\r
+                       Vector<AppHMIType> newList = new Vector<AppHMIType>();\r
+                       for (Object hashObj : list) {\r
+                           String strFormat = (String)hashObj;\r
+                           AppHMIType toAdd = null;\r
+                           try {\r
+                               toAdd = AppHMIType.valueForString(strFormat);\r
+                           } catch (Exception e) {\r
+                               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.appHMIType, e);                            }\r
+                           if (toAdd != null) {\r
+                               newList.add(toAdd);\r
+                           }\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * Sets a a list of all applicable app types stating which classifications\r
+        * to be given to the app. e.g. for platforms , like GEN2, this will\r
+        * determine which "corner(s)" the app can populate\r
+        * \r
+        * @param appHMIType\r
+        *            a Vector<AppHMIType>\r
+        *            <p>\r
+        *            <b>Notes: </b>\r
+        *            <ul>\r
+        *            <li>Array Minsize: = 1</li>\r
+        *            <li>Array Maxsize = 100</li>\r
+        *            </ul>\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public void setAppHMIType(Vector<AppHMIType> appHMIType) {\r
+        if (appHMIType != null) {\r
+            parameters.put(Names.appHMIType, appHMIType);\r
+        } else {\r
+               parameters.remove(Names.appHMIType);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets the unique ID, which an app will be given when approved by Ford\r
+        * \r
+        * @return String - a String value representing the unique ID, which an app\r
+        *         will be given when approved by Ford\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public String getAppID() {\r
+        return (String) parameters.get(Names.appID);\r
+    }\r
+\r
+       /**\r
+        * Sets a unique ID, which an app will be given when approved by Ford\r
+        * \r
+        * @param appID\r
+        *            a String value representing a unique ID, which an app will be\r
+        *            given when approved by Ford\r
+        *            <p>\r
+        *            <b>Notes: </b>Maxlength = 100\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public void setAppID(String appID) {\r
+        if (appID != null) {\r
+            parameters.put(Names.appID, appID);\r
+        } else {\r
+               parameters.remove(Names.appID);\r
+        }\r
+    }\r
+}\r
index 8f6809c..9a99e8f 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-import java.util.Vector;
-
-import com.smartdevicelink.proxy.RPCResponse;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.HmiZoneCapabilities;
-import com.smartdevicelink.proxy.rpc.enums.Language;
-import com.smartdevicelink.proxy.rpc.enums.SpeechCapabilities;
-import com.smartdevicelink.proxy.rpc.enums.VrCapabilities;
-import com.smartdevicelink.util.DebugTool;
-
-public class RegisterAppInterfaceResponse extends RPCResponse {
-
-    public RegisterAppInterfaceResponse() {
-        super("RegisterAppInterface");
-    }
-    public RegisterAppInterfaceResponse(Hashtable hash) {
-        super(hash);
-    }
-    public SyncMsgVersion getSyncMsgVersion() {
-        Object obj = parameters.get(Names.syncMsgVersion);
-        if (obj instanceof SyncMsgVersion) {
-               return (SyncMsgVersion)obj;
-        } else if (obj instanceof Hashtable) {
-               return new SyncMsgVersion((Hashtable)obj);
-        }
-        return null;
-    }
-    public void setSyncMsgVersion( SyncMsgVersion SyncMsgVersion ) {
-        if (SyncMsgVersion != null) {
-            parameters.put(Names.syncMsgVersion, SyncMsgVersion );
-        }
-    }
-    public String getAutoActivateID() {
-        return (String) parameters.get( Names.autoActivateID );
-    }
-    public void setAutoActivateID( String autoActivateID ) {
-        if (autoActivateID != null) {
-            parameters.put(Names.autoActivateID, autoActivateID );
-        }
-    }
-    public Language getLanguage() {
-        Object obj = parameters.get(Names.language);
-        if (obj instanceof Language) {
-            return (Language) obj;
-        } else if (obj instanceof String) {
-            Language theCode = null;
-            try {
-                theCode = Language.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.language, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setLanguage( Language language ) {
-        if (language != null) {
-            parameters.put(Names.language, language );
-        }
-    }
-    public DisplayCapabilities getDisplayCapabilities() {
-        Object obj = parameters.get(Names.displayCapabilities);
-        if (obj instanceof DisplayCapabilities) {
-               return (DisplayCapabilities)obj;
-        } else if (obj instanceof Hashtable) {
-               return new DisplayCapabilities((Hashtable)obj);
-        }
-        return null;
-    }
-    public void setDisplayCapabilities( DisplayCapabilities displayCapabilities ) {
-        if (displayCapabilities != null) {
-            parameters.put(Names.displayCapabilities, displayCapabilities );
-        }
-    }
-    public Vector<ButtonCapabilities> getButtonCapabilities() {
-        if (parameters.get(Names.buttonCapabilities) instanceof Vector<?>) {
-               Vector<?> list = (Vector<?>)parameters.get(Names.buttonCapabilities);
-               if (list != null && list.size() > 0) {
-                   Object obj = list.get(0);
-                   if (obj instanceof ButtonCapabilities) {
-                       return (Vector<ButtonCapabilities>) list;
-                   } else if (obj instanceof Hashtable) {
-                       Vector<ButtonCapabilities> newList = new Vector<ButtonCapabilities>();
-                       for (Object hashObj : list) {
-                           newList.add(new ButtonCapabilities((Hashtable)hashObj));
-                       }
-                       return newList;
-                   }
-               }
-        }
-        return null;
-    }
-    public void setButtonCapabilities( Vector<ButtonCapabilities> buttonCapabilities ) {
-        if (buttonCapabilities != null) {
-            parameters.put(Names.buttonCapabilities, buttonCapabilities );
-        }
-    }
-    public Vector<HmiZoneCapabilities> getHmiZoneCapabilities() {
-        if (parameters.get(Names.hmiZoneCapabilities) instanceof Vector<?>) {
-               Vector<?> list = (Vector<?>)parameters.get(Names.hmiZoneCapabilities);
-               if (list != null && list.size() > 0) {
-                   Object obj = list.get(0);
-                   if (obj instanceof HmiZoneCapabilities) {
-                       return (Vector<HmiZoneCapabilities>) list;
-                   } else if (obj instanceof String) {
-                       Vector<HmiZoneCapabilities> newList = new Vector<HmiZoneCapabilities>();
-                       for (Object hashObj : list) {
-                           String strFormat = (String)hashObj;
-                           HmiZoneCapabilities toAdd = null;
-                           try {
-                               toAdd = HmiZoneCapabilities.valueForString(strFormat);
-                           } catch (Exception e) {
-                               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.hmiZoneCapabilities, e);
-                           }
-                           if (toAdd != null) {
-                               newList.add(toAdd);
-                           }
-                       }
-                       return newList;
-                   }
-               }
-        }
-        return null;
-    }
-    public void setHmiZoneCapabilities( Vector<HmiZoneCapabilities> hmiZoneCapabilities ) {
-        if (hmiZoneCapabilities != null) {
-            parameters.put(Names.hmiZoneCapabilities, hmiZoneCapabilities );
-        }
-    }
-    public Vector<SpeechCapabilities> getSpeechCapabilities() {
-        if (parameters.get(Names.speechCapabilities) instanceof Vector<?>) {
-               Vector<?> list = (Vector<?>)parameters.get(Names.speechCapabilities);
-               if (list != null && list.size() > 0) {
-                   Object obj = list.get(0);
-                   if (obj instanceof SpeechCapabilities) {
-                       return (Vector<SpeechCapabilities>) list;
-                   } else if (obj instanceof String) {
-                       Vector<SpeechCapabilities> newList = new Vector<SpeechCapabilities>();
-                       for (Object hashObj : list) {
-                           String strFormat = (String)hashObj;
-                           SpeechCapabilities toAdd = null;
-                           try {
-                               toAdd = SpeechCapabilities.valueForString(strFormat);
-                           } catch (Exception e) {
-                               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.speechCapabilities, e);
-                           }
-                           if (toAdd != null) {
-                               newList.add(toAdd);
-                           }
-                       }
-                       return newList;
-                   }
-               }
-        }
-        return null;
-    }
-    public void setSpeechCapabilities( Vector<SpeechCapabilities> speechCapabilities ) {
-        if (speechCapabilities != null) {
-            parameters.put(Names.speechCapabilities, speechCapabilities );
-        }
-    }
-    public Vector<VrCapabilities> getVrCapabilities() {
-        if (parameters.get(Names.vrCapabilities) instanceof Vector<?>) {
-               Vector<?> list = (Vector<?>)parameters.get(Names.vrCapabilities);
-               if (list != null && list.size() > 0) {
-                   Object obj = list.get(0);
-                   if (obj instanceof VrCapabilities) {
-                       return (Vector<VrCapabilities>) list;
-                   } else if (obj instanceof String) {
-                       Vector<VrCapabilities> newList = new Vector<VrCapabilities>();
-                       for (Object hashObj : list) {
-                           String strFormat = (String)hashObj;
-                           VrCapabilities toAdd = null;
-                           try {
-                               toAdd = VrCapabilities.valueForString(strFormat);
-                           } catch (Exception e) {
-                               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.vrCapabilities, e);
-                           }
-                           if (toAdd != null) {
-                               newList.add(toAdd);
-                           }
-                       }
-                       return newList;
-                   }
-               }
-        }
-        return null;
-    }
-    public void setVrCapabilities( Vector<VrCapabilities> vrCapabilities ) {
-        if (vrCapabilities != null) {
-            parameters.put(Names.vrCapabilities, vrCapabilities );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.exception.SmartDeviceLinkException;\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+import com.smartdevicelink.proxy.Version;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.HmiZoneCapabilities;\r
+import com.smartdevicelink.proxy.rpc.enums.Language;\r
+import com.smartdevicelink.proxy.rpc.enums.SpeechCapabilities;\r
+import com.smartdevicelink.proxy.rpc.enums.VrCapabilities;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Register AppInterface Response is sent, when RegisterAppInterface has been called\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class RegisterAppInterfaceResponse extends RPCResponse {\r
+       /**\r
+        * Constructs a new RegisterAppInterfaceResponse object\r
+        */\r
+    public RegisterAppInterfaceResponse() {\r
+        super("RegisterAppInterface");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new RegisterAppInterfaceResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public RegisterAppInterfaceResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+\r
+       /**\r
+        * Gets the version of the SMARTDEVICELINK&reg; SmartDeviceLink interface\r
+        * \r
+        * @return smartdevicelinkMsgVersion -a smartdevicelinkMsgVersion object representing version of\r
+        *         the SMARTDEVICELINK&reg; SmartDeviceLink interface\r
+        */\r
+    public smartdevicelinkMsgVersion getsmartdevicelinkMsgVersion() {\r
+        Object obj = parameters.get(Names.smartDeviceLinkMsgVersion);\r
+        if (obj instanceof smartdevicelinkMsgVersion) {\r
+               return (smartdevicelinkMsgVersion)obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               return new smartdevicelinkMsgVersion((Hashtable)obj);\r
+        }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * Sets the version of the SMARTDEVICELINK&reg; SmartDeviceLink interface\r
+        * \r
+        * @param smartDeviceLinkMsgVersion\r
+        *            a smartdevicelinkMsgVersion object representing version of the SMARTDEVICELINK&reg;\r
+        *            SmartDeviceLink interface\r
+        *            <p>\r
+        *            <b>Notes: </b>To be compatible, app msg major version number\r
+        *            must be less than or equal to SMARTDEVICELINK&reg; major version number.\r
+        *            If msg versions are incompatible, app has 20 seconds to\r
+        *            attempt successful RegisterAppInterface (w.r.t. msg version)\r
+        *            on underlying protocol session, else will be terminated. Major\r
+        *            version number is a compatibility declaration. Minor version\r
+        *            number indicates minor functional variations (e.g. features,\r
+        *            capabilities, bug fixes) when sent from SMARTDEVICELINK&reg; to app (in\r
+        *            RegisterAppInterface response). However, the minor version\r
+        *            number sent from the app to SMARTDEVICELINK&reg; (in RegisterAppInterface\r
+        *            request) is ignored by SMARTDEVICELINK&reg;\r
+        */\r
+    public void setsmartdevicelinkMsgVersion(smartdevicelinkMsgVersion smartDeviceLinkMsgVersion) {\r
+        if (smartDeviceLinkMsgVersion != null) {\r
+            parameters.put(Names.smartDeviceLinkMsgVersion, smartDeviceLinkMsgVersion);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a Language enumeration indicating what language the application\r
+        * intends to use for user interaction (Display, TTS and VR)\r
+        * \r
+        * @return Enumeration -a language enumeration\r
+        */\r
+    public Language getLanguage() {\r
+        Object obj = parameters.get(Names.language);\r
+        if (obj instanceof Language) {\r
+            return (Language) obj;\r
+        } else if (obj instanceof String) {\r
+            Language theCode = null;\r
+            try {\r
+                theCode = Language.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.language, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * Sets an enumeration indicating what language the application intends to\r
+        * use for user interaction (Display, TTS and VR)\r
+        * \r
+        * @param language\r
+        *            a Language Enumeration\r
+        *            <p>\r
+        * \r
+        */\r
+    public void setLanguage(Language language) {\r
+        if (language != null) {\r
+            parameters.put(Names.language, language);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets an enumeration indicating what language the application intends to\r
+        * use for user interaction ( Display)\r
+        * \r
+        * @return Language - a Language value representing an enumeration\r
+        *         indicating what language the application intends to use for user\r
+        *         interaction ( Display)\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public Language getHmiDisplayLanguage() {\r
+        Object obj = parameters.get(Names.hmiDisplayLanguage);\r
+        if (obj instanceof Language) {\r
+            return (Language) obj;\r
+        } else if (obj instanceof String) {\r
+            Language theCode = null;\r
+            try {\r
+                theCode = Language.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.hmiDisplayLanguage, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * Sets an enumeration indicating what language the application intends to\r
+        * use for user interaction ( Display)\r
+        * \r
+        * @param hmiDisplayLanguage\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public void setHmiDisplayLanguage(Language hmiDisplayLanguage) {\r
+        if (hmiDisplayLanguage != null) {\r
+            parameters.put(Names.hmiDisplayLanguage, hmiDisplayLanguage);\r
+        } else {\r
+               parameters.remove(Names.hmiDisplayLanguage);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets getDisplayCapabilities set when application interface is registered.\r
+        * \r
+        * @return DisplayCapabilities\r
+        */\r
+    public DisplayCapabilities getDisplayCapabilities() {\r
+        Object obj = parameters.get(Names.displayCapabilities);\r
+        if (obj instanceof DisplayCapabilities) {\r
+               return (DisplayCapabilities)obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               return new DisplayCapabilities((Hashtable)obj);\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Display Capabilities\r
+     * @param displayCapabilities\r
+     */\r
+    public void setDisplayCapabilities(DisplayCapabilities displayCapabilities) {\r
+        if (displayCapabilities != null) {\r
+            parameters.put(Names.displayCapabilities, displayCapabilities);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets buttonCapabilities set when application interface is registered.\r
+        * \r
+        * @return buttonCapabilities\r
+        */\r
+    public Vector<ButtonCapabilities> getButtonCapabilities() {\r
+        if (parameters.get(Names.buttonCapabilities) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.buttonCapabilities);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof ButtonCapabilities) {\r
+                       return (Vector<ButtonCapabilities>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<ButtonCapabilities> newList = new Vector<ButtonCapabilities>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new ButtonCapabilities((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Button Capabilities\r
+     * @param buttonCapabilities\r
+     */\r
+    public void setButtonCapabilities(Vector<ButtonCapabilities> buttonCapabilities) {\r
+        if (buttonCapabilities != null) {\r
+            parameters.put(Names.buttonCapabilities, buttonCapabilities);\r
+        }\r
+    }\r
+    /**\r
+        * Gets getSoftButtonCapabilities set when application interface is registered.\r
+        * \r
+        * @return SoftButtonCapabilities \r
+        */\r
+    public Vector<SoftButtonCapabilities> getSoftButtonCapabilities() {\r
+        if (parameters.get(Names.softButtonCapabilities) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.softButtonCapabilities);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof SoftButtonCapabilities) {\r
+                       return (Vector<SoftButtonCapabilities>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<SoftButtonCapabilities> newList = new Vector<SoftButtonCapabilities>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new SoftButtonCapabilities((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets softButtonCapabilities\r
+     * @param softButtonCapabilities\r
+     */\r
+    public void setSoftButtonCapabilities(Vector<SoftButtonCapabilities> softButtonCapabilities) {\r
+        if (softButtonCapabilities != null) {\r
+            parameters.put(Names.softButtonCapabilities, softButtonCapabilities);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets getPresetBankCapabilities set when application interface is registered.\r
+        * \r
+        * @return PresetBankCapabilities \r
+        */\r
+    public PresetBankCapabilities getPresetBankCapabilities() {\r
+        Object obj = parameters.get(Names.presetBankCapabilities);\r
+        if (obj instanceof PresetBankCapabilities) {\r
+               return (PresetBankCapabilities)obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               return new PresetBankCapabilities((Hashtable)obj);\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets presetBankCapabilities\r
+     * @param  presetBankCapabilities\r
+     */\r
+    public void setPresetBankCapabilities(PresetBankCapabilities presetBankCapabilities) {\r
+        if (presetBankCapabilities != null) {\r
+            parameters.put(Names.presetBankCapabilities, presetBankCapabilities);\r
+        }\r
+    }\r
+       \r
+       /**\r
+        * Gets hmiZoneCapabilities set when application interface is registered.\r
+        * \r
+        * @return HmiZoneCapabilities\r
+        */\r
+    public Vector<HmiZoneCapabilities> getHmiZoneCapabilities() {\r
+        if (parameters.get(Names.hmiZoneCapabilities) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.hmiZoneCapabilities);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof HmiZoneCapabilities) {\r
+                       return (Vector<HmiZoneCapabilities>) list;\r
+                   } else if (obj instanceof String) {\r
+                       Vector<HmiZoneCapabilities> newList = new Vector<HmiZoneCapabilities>();\r
+                       for (Object hashObj : list) {\r
+                           String strFormat = (String)hashObj;\r
+                           HmiZoneCapabilities toAdd = null;\r
+                           try {\r
+                               toAdd = HmiZoneCapabilities.valueForString(strFormat);\r
+                           } catch (Exception e) {\r
+                               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.hmiZoneCapabilities, e);\r
+                           }\r
+                           if (toAdd != null) {\r
+                               newList.add(toAdd);\r
+                           }\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets hmiZoneCapabilities\r
+     * @param hmiZoneCapabilities\r
+     */\r
+    public void setHmiZoneCapabilities(Vector<HmiZoneCapabilities> hmiZoneCapabilities) {\r
+        if (hmiZoneCapabilities != null) {\r
+            parameters.put(Names.hmiZoneCapabilities, hmiZoneCapabilities);\r
+        }\r
+    }\r
+       \r
+       /**\r
+        * Gets speechCapabilities set when application interface is registered.\r
+        * \r
+        * @return SpeechCapabilities\r
+        */\r
+    public Vector<SpeechCapabilities> getSpeechCapabilities() {\r
+        if (parameters.get(Names.speechCapabilities) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.speechCapabilities);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof SpeechCapabilities) {\r
+                       return (Vector<SpeechCapabilities>) list;\r
+                   } else if (obj instanceof String) {\r
+                       Vector<SpeechCapabilities> newList = new Vector<SpeechCapabilities>();\r
+                       for (Object hashObj : list) {\r
+                           String strFormat = (String)hashObj;\r
+                           SpeechCapabilities toAdd = null;\r
+                           try {\r
+                               toAdd = SpeechCapabilities.valueForString(strFormat);\r
+                           } catch (Exception e) {\r
+                               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.speechCapabilities, e);\r
+                           }\r
+                           if (toAdd != null) {\r
+                               newList.add(toAdd);\r
+                           }\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets speechCapabilities\r
+     * @param speechCapabilities\r
+     */\r
+    public void setSpeechCapabilities(Vector<SpeechCapabilities> speechCapabilities) {\r
+        if (speechCapabilities != null) {\r
+            parameters.put(Names.speechCapabilities, speechCapabilities);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets vrCapabilities set when application interface is registered.\r
+        * \r
+        * @return VrCapabilities\r
+        */\r
+    public Vector<VrCapabilities> getVrCapabilities() {\r
+        if (parameters.get(Names.vrCapabilities) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.vrCapabilities);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof VrCapabilities) {\r
+                       return (Vector<VrCapabilities>) list;\r
+                   } else if (obj instanceof String) {\r
+                       Vector<VrCapabilities> newList = new Vector<VrCapabilities>();\r
+                       for (Object hashObj : list) {\r
+                           String strFormat = (String)hashObj;\r
+                           VrCapabilities toAdd = null;\r
+                           try {\r
+                               toAdd = VrCapabilities.valueForString(strFormat);\r
+                           } catch (Exception e) {\r
+                               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.vrCapabilities, e);\r
+                           }\r
+                           if (toAdd != null) {\r
+                               newList.add(toAdd);\r
+                           }\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets VrCapabilities\r
+     * @param vrCapabilities\r
+     */\r
+    public void setVrCapabilities(Vector<VrCapabilities> vrCapabilities) {\r
+        if (vrCapabilities != null) {\r
+            parameters.put(Names.vrCapabilities, vrCapabilities);\r
+        }\r
+    }\r
+       \r
+       /**\r
+        * Gets getVehicleType set when application interface is registered.\r
+        * \r
+        * @return vehicleType \r
+        */\r
+    public VehicleType getVehicleType() {\r
+        Object obj = parameters.get(Names.vehicleType);\r
+        if (obj instanceof VehicleType) {\r
+               return (VehicleType)obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               return new VehicleType((Hashtable)obj);\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets vehicleType\r
+     * @param vehicleType\r
+     */\r
+    public void setVehicleType(VehicleType vehicleType) {\r
+        if (vehicleType != null) {\r
+            parameters.put(Names.vehicleType, vehicleType);\r
+        }\r
+    }\r
+       \r
+       /**\r
+        * Gets AudioPassThruCapabilities set when application interface is registered.\r
+        * \r
+        * @return AudioPassThruCapabilities \r
+        */\r
+    public Vector<AudioPassThruCapabilities> getAudioPassThruCapabilities() {\r
+        if (parameters.get(Names.audioPassThruCapabilities) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.audioPassThruCapabilities);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof AudioPassThruCapabilities) {\r
+                       return (Vector<AudioPassThruCapabilities>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<AudioPassThruCapabilities> newList = new Vector<AudioPassThruCapabilities>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new AudioPassThruCapabilities((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets AudioPassThruCapabilities\r
+     * @param audioPassThruCapabilities\r
+     */\r
+    public void setAudioPassThruCapabilities(Vector<AudioPassThruCapabilities> audioPassThruCapabilities) {\r
+        if (audioPassThruCapabilities != null) {\r
+            parameters.put(Names.audioPassThruCapabilities, audioPassThruCapabilities);\r
+        }\r
+    }\r
+    public String getProxyVersionInfo() {\r
+               if (Version.VERSION != null)\r
+                       return  Version.VERSION;\r
+       \r
+               return null;\r
+    }\r
+}\r
index 38775b4..096e5ec 100755 (executable)
@@ -1,54 +1,94 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-import java.util.Vector;
-
-import com.smartdevicelink.proxy.RPCRequest;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.GlobalProperty;
-import com.smartdevicelink.util.DebugTool;
-
-public class ResetGlobalProperties extends RPCRequest {
-
-    public ResetGlobalProperties() {
-        super("ResetGlobalProperties");
-    }
-    public ResetGlobalProperties(Hashtable hash) {
-        super(hash);
-    }
-    public Vector<GlobalProperty> getProperties() {
-       if (parameters.get(Names.properties) instanceof Vector<?>) {
-               Vector<?> list = (Vector<?>)parameters.get(Names.properties);
-               if (list != null && list.size() > 0) {
-                   Object obj = list.get(0);
-                   if (obj instanceof GlobalProperty) {
-                       return (Vector<GlobalProperty>) list;
-                   } else if (obj instanceof String) {
-                       Vector<GlobalProperty> newList = new Vector<GlobalProperty>();
-                       for (Object hashObj : list) {
-                           String strFormat = (String)hashObj;
-                           GlobalProperty toAdd = null;
-                           try {
-                               toAdd = GlobalProperty.valueForString(strFormat);
-                           } catch (Exception e) {
-                               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.properties, e);
-                           }
-                           if (toAdd != null) {
-                               newList.add(toAdd);
-                           }
-                       }
-                       return newList;
-                   }
-               }
-       }
-        return null;
-    }
-    public void setProperties( Vector<GlobalProperty> properties ) {
-        if (properties != null) {
-            parameters.put(Names.properties, properties );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.GlobalProperty;\r
+import com.smartdevicelink.util.DebugTool;\r
+/**\r
+ * Resets the passed global properties to their default values as defined by\r
+ * SMARTDEVICELINK\r
+ * <p>\r
+ * The HELPPROMPT global property default value is generated by SMARTDEVICELINK consists of\r
+ * the first vrCommand of each Command Menu item defined at the moment PTT is\r
+ * pressed<br/>\r
+ * The TIMEOUTPROMPT global property default value is the same as the HELPPROMPT\r
+ * global property default value\r
+ * <p>\r
+ * <b>HMILevel needs to be FULL, LIMITED or BACKGROUND</b>\r
+ * </p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ * @see SetGlobalProperties\r
+ */\r
+public class ResetGlobalProperties extends RPCRequest {\r
+       /**\r
+        * Constructs a new ResetGlobalProperties object\r
+        */\r
+    public ResetGlobalProperties() {\r
+        super("ResetGlobalProperties");\r
+    }\r
+       /**\r
+        * Constructs a new ResetGlobalProperties object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */    \r
+    public ResetGlobalProperties(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+       /**\r
+        * Gets an array of one or more GlobalProperty enumeration elements\r
+        * indicating which global properties to reset to their default value\r
+        * \r
+        * @return Vector<GlobalProperty> -an array of one or more GlobalProperty\r
+        *         enumeration elements\r
+        */    \r
+    public Vector<GlobalProperty> getProperties() {\r
+       if (parameters.get(Names.properties) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.properties);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof GlobalProperty) {\r
+                       return (Vector<GlobalProperty>) list;\r
+                   } else if (obj instanceof String) {\r
+                       Vector<GlobalProperty> newList = new Vector<GlobalProperty>();\r
+                       for (Object hashObj : list) {\r
+                           String strFormat = (String)hashObj;\r
+                           GlobalProperty toAdd = null;\r
+                           try {\r
+                               toAdd = GlobalProperty.valueForString(strFormat);\r
+                           } catch (Exception e) {\r
+                               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.properties, e);\r
+                           }\r
+                           if (toAdd != null) {\r
+                               newList.add(toAdd);\r
+                           }\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+       }\r
+        return null;\r
+    }\r
+       /**\r
+        * Sets an array of one or more GlobalProperty enumeration elements\r
+        * indicating which global properties to reset to their default value\r
+        * \r
+        * @param properties\r
+        *            a Vector<GlobalProperty> An array of one or more\r
+        *            GlobalProperty enumeration elements indicating which global\r
+        *            properties to reset to their default value\r
+        *            <p>\r
+        *            <b>Notes: </b>Array must have at least one element\r
+        */    \r
+    public void setProperties( Vector<GlobalProperty> properties ) {\r
+        if (properties != null) {\r
+            parameters.put(Names.properties, properties );\r
+        }\r
+    }\r
+}\r
index 56c3170..0c4570a 100755 (executable)
@@ -1,18 +1,32 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCResponse;
-
-public class ResetGlobalPropertiesResponse extends RPCResponse {
-
-    public ResetGlobalPropertiesResponse() {
-        super("ResetGlobalProperties");
-    }
-    public ResetGlobalPropertiesResponse(Hashtable hash) {
-        super(hash);
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Reset Global Properties Response is sent, when ResetGlobalProperties has been called\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class ResetGlobalPropertiesResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new ResetGlobalPropertiesResponse object\r
+        */\r
+    public ResetGlobalPropertiesResponse() {\r
+        super("ResetGlobalProperties");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new ResetGlobalPropertiesResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public ResetGlobalPropertiesResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ScrollableMessage.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ScrollableMessage.java
new file mode 100755 (executable)
index 0000000..2036559
--- /dev/null
@@ -0,0 +1,133 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.SystemAction;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Creates a full screen overlay containing a large block of formatted text that\r
+ * can be scrolled with up to 8 SoftButtons defined\r
+ * <p>\r
+ * Function Group: ScrollableMessage\r
+ * <p>\r
+ * <b>HMILevel needs to be FULL</b>\r
+ * <p>\r
+ */\r
+public class ScrollableMessage extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new ScrollableMessage object\r
+        */\r
+    public ScrollableMessage() {\r
+        super("ScrollableMessage");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new ScrollableMessage object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public ScrollableMessage(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+\r
+       /**\r
+        * Sets a Body of text that can include newlines and tabs\r
+        * \r
+        * @param scrollableMessageBody\r
+        *            a String value representing the Body of text that can include\r
+        *            newlines and tabs\r
+        *            <p>\r
+        *            <b>Notes: </b>Maxlength=500\r
+        */\r
+    public void setScrollableMessageBody(String scrollableMessageBody) {\r
+        if (scrollableMessageBody != null) {\r
+            parameters.put(Names.scrollableMessageBody, scrollableMessageBody);\r
+        } else {\r
+               parameters.remove(Names.scrollableMessageBody);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a Body of text that can include newlines and tabs\r
+        * \r
+        * @return String -a String value\r
+        */\r
+    public String getScrollableMessageBody() {\r
+        return (String) parameters.get(Names.scrollableMessageBody);\r
+    }\r
+\r
+       /**\r
+        * Sets an App defined timeout. Indicates how long of a timeout from the\r
+        * last action\r
+        * \r
+        * @param timeout\r
+        *            an Integer value representing an App defined timeout\r
+        *            <p>\r
+        *            <b>Notes</b>:Minval=0; Maxval=65535;Default=30000\r
+        */\r
+    public void setTimeout(Integer timeout) {\r
+        if (timeout != null) {\r
+            parameters.put(Names.timeout, timeout);\r
+        } else {\r
+               parameters.remove(Names.timeout);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets an App defined timeout\r
+        * \r
+        * @return Integer -an Integer value representing an App defined timeout\r
+        */\r
+    public Integer getTimeout() {\r
+        return (Integer) parameters.get(Names.timeout);\r
+    }\r
+\r
+       /**\r
+        * Sets App defined SoftButtons.If omitted on supported displays, only the\r
+        * system defined "Close" SoftButton will be displayed\r
+        * \r
+        * @param softButtons\r
+        *            a Vector<SoftButton> value representing App defined\r
+        *            SoftButtons\r
+        *            <p>\r
+        *            <b>Notes: </b>Minsize=0, Maxsize=8\r
+        */\r
+    public void setSoftButtons(Vector<SoftButton> softButtons) {\r
+        if (softButtons != null) {\r
+            parameters.put(Names.softButtons, softButtons);\r
+        } else {\r
+               parameters.remove(Names.softButtons);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets App defined soft button\r
+        * @return Vector -Vector<SoftButton> value\r
+        */\r
+    public Vector<SoftButton> getSoftButtons() {\r
+        if (parameters.get(Names.softButtons) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.softButtons);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof SoftButton) {\r
+                       return (Vector<SoftButton>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<SoftButton> newList = new Vector<SoftButton>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new SoftButton((Hashtable) hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ScrollableMessageResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ScrollableMessageResponse.java
new file mode 100755 (executable)
index 0000000..8be2277
--- /dev/null
@@ -0,0 +1,32 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Scrollable Message Response is sent, when ScrollableMessage has been called\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class ScrollableMessageResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new ScrollableMessageResponse object\r
+        */\r
+    public ScrollableMessageResponse() {\r
+        super("ScrollableMessage");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new ScrollableMessageResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public ScrollableMessageResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SetAppIcon.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SetAppIcon.java
new file mode 100755 (executable)
index 0000000..c234f4d
--- /dev/null
@@ -0,0 +1,58 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Used to set existing local file on SMARTDEVICELINK as the app's icon. Not supported on\r
+ * first generation SMARTDEVICELINK vehicles\r
+ * <p>\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class SetAppIcon extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new SetAppIcon object\r
+        */\r
+    public SetAppIcon() {\r
+        super("SetAppIcon");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new SetAppIcon object indicated by the Hashtable parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public SetAppIcon(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+\r
+       /**\r
+        * Sets a file reference name\r
+        * \r
+        * @param smartDeviceLinkFileName\r
+        *            a String value representing a file reference name\r
+        *            <p>\r
+        *            <b>Notes: </b>Maxlength=500\r
+        */\r
+    public void setSmartDeviceLinkFileName(String smartDeviceLinkFileName) {\r
+        if (smartDeviceLinkFileName != null) {\r
+            parameters.put(Names.smartDeviceLinkFileName, smartDeviceLinkFileName);\r
+        } else {\r
+               parameters.remove(Names.smartDeviceLinkFileName);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a file reference name\r
+        * @return String -a String value\r
+        */\r
+    public String getSmartDeviceLinkFileName() {\r
+        return (String) parameters.get(Names.smartDeviceLinkFileName);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SetAppIconResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SetAppIconResponse.java
new file mode 100755 (executable)
index 0000000..8ee16ae
--- /dev/null
@@ -0,0 +1,15 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+public class SetAppIconResponse extends RPCResponse {\r
+\r
+    public SetAppIconResponse() {\r
+        super("SetAppIcon");\r
+    }\r
+    public SetAppIconResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SetDisplayLayout.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SetDisplayLayout.java
new file mode 100755 (executable)
index 0000000..b72860c
--- /dev/null
@@ -0,0 +1,60 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Used to set an alternate display layout. If not sent, default screen for\r
+ * given platform will be shown\r
+ * <p>\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class SetDisplayLayout extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new SetDisplayLayout object\r
+        */\r
+    public SetDisplayLayout() {\r
+        super("SetDisplayLayout");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new SetDisplayLayout object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public SetDisplayLayout(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+\r
+       /**\r
+        * Sets a display layout. Predefined or dynamically created screen layout.\r
+        * Currently only predefined screen layouts are defined. Predefined layouts\r
+        * include: "ONSCREEN_PRESETS" Custom screen containing app-defined onscreen\r
+        * presets. Currently defined for GEN2\r
+        * \r
+        * @param displayLayout\r
+        *            a String value representing a diaply layout\r
+        */\r
+    public void setDisplayLayout(String displayLayout) {\r
+        if (displayLayout != null) {\r
+            parameters.put(Names.displayLayout, displayLayout);\r
+        } else {\r
+               parameters.remove(Names.displayLayout);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a display layout.\r
+        */\r
+    public String getDisplayLayout() {\r
+       return (String) parameters.get(Names.displayLayout);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SetDisplayLayoutResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SetDisplayLayoutResponse.java
new file mode 100755 (executable)
index 0000000..5f869fa
--- /dev/null
@@ -0,0 +1,32 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Set Display Layout Response is sent, when SetDisplayLayout has been called\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class SetDisplayLayoutResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new SetDisplayLayoutResponse object\r
+        */\r
+    public SetDisplayLayoutResponse() {\r
+        super("SetDisplayLayout");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new SetDisplayLayoutResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public SetDisplayLayoutResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
index b086b9e..f1178d4 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-import java.util.Vector;
-
-import com.smartdevicelink.proxy.RPCRequest;
-import com.smartdevicelink.proxy.constants.Names;
-
-public class SetGlobalProperties extends RPCRequest {
-
-    public SetGlobalProperties() {
-        super("SetGlobalProperties");
-    }
-    public SetGlobalProperties(Hashtable hash) {
-        super(hash);
-    }
-    public Vector<TTSChunk> getHelpPrompt() {
-       if (parameters.get(Names.helpPrompt) instanceof Vector<?>) {
-               Vector<?> list = (Vector<?>)parameters.get(Names.helpPrompt);
-               if (list != null && list.size() > 0) {
-                   Object obj = list.get(0);
-                   if (obj instanceof TTSChunk) {
-                       return (Vector<TTSChunk>) list;
-                   } else if (obj instanceof Hashtable) {
-                       Vector<TTSChunk> newList = new Vector<TTSChunk>();
-                       for (Object hashObj : list) {
-                           newList.add(new TTSChunk((Hashtable)hashObj));
-                       }
-                       return newList;
-                   }
-               }
-       }
-           return null;
-    }
-    public void setHelpPrompt( Vector<TTSChunk> helpPrompt ) {
-        if (helpPrompt != null) {
-            parameters.put(Names.helpPrompt, helpPrompt );
-        }
-    }
-    public Vector<TTSChunk> getTimeoutPrompt() {
-        if (parameters.get(Names.timeoutPrompt) instanceof Vector<?>) {
-               Vector<?> list = (Vector<?>)parameters.get(Names.timeoutPrompt);
-               if (list != null && list.size() > 0) {
-                   Object obj = list.get(0);
-                   if (obj instanceof TTSChunk) {
-                       return (Vector<TTSChunk>) list;
-                   } else if (obj instanceof Hashtable) {
-                       Vector<TTSChunk> newList = new Vector<TTSChunk>();
-                       for (Object hashObj : list) {
-                           newList.add(new TTSChunk((Hashtable)hashObj));
-                       }
-                       return newList;
-                   }
-               }
-        }
-        return null;
-    }
-    public void setTimeoutPrompt( Vector<TTSChunk> timeoutPrompt ) {
-        if (timeoutPrompt != null) {
-            parameters.put(Names.timeoutPrompt, timeoutPrompt );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+/**\r
+ * Sets value(s) for the specified global property(ies)\r
+ * <p>\r
+ * Function Group: Base <p>\r
+ * <b>HMILevel needs to be FULL, LIMITED or BACKGROUND</b>\r
+ * </p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ * @see ResetGlobalProperties\r
+ */\r
+public class SetGlobalProperties extends RPCRequest {\r
+       /**\r
+        * Constructs a new SetGlobalProperties object\r
+        */\r
+    public SetGlobalProperties() {\r
+        super("SetGlobalProperties");\r
+    }\r
+       /**\r
+        * Constructs a new SetGlobalProperties object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */    \r
+    public SetGlobalProperties(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+       /**\r
+        * Gets a Vector<TTSChunk> for Help Prompt representing Array of one or more\r
+        * TTSChunk elements specifying the help prompt used in an interaction\r
+        * started by PTT\r
+        * \r
+        * @return Vector<TTSChunk> -an Array of one or more TTSChunk elements\r
+        *         specifying the help prompt used in an interaction started by PTT\r
+        */    \r
+    public Vector<TTSChunk> getHelpPrompt() {\r
+       if (parameters.get(Names.helpPrompt) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.helpPrompt);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof TTSChunk) {\r
+                       return (Vector<TTSChunk>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<TTSChunk> newList = new Vector<TTSChunk>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new TTSChunk((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+       }\r
+           return null;\r
+    }\r
+       /**\r
+        * Sets a Vector<TTSChunk> for Help Prompt that Array of one or more\r
+        * TTSChunk elements specifying the help prompt used in an interaction\r
+        * started by PTT\r
+        * \r
+        * @param helpPrompt\r
+        *            a Vector<TTSChunk> of one or more TTSChunk elements\r
+        *            <p>\r
+        *            <b>Notes: </b>\r
+        *            <ul>\r
+        *            <li>Array must have at least one element</li>\r
+        *            <li>Only optional it timeoutPrompt has been specified</li>\r
+        *            </ul>\r
+        */    \r
+    public void setHelpPrompt(Vector<TTSChunk> helpPrompt) {\r
+        if (helpPrompt != null) {\r
+            parameters.put(Names.helpPrompt, helpPrompt);\r
+        }\r
+    }\r
+       /**\r
+        * Gets a Vector<TTSChunk> for Timeout Prompt representing Array of one or\r
+        * more TTSChunk elements specifying the help prompt used in an interaction\r
+        * started by PTT\r
+        * \r
+        * @return Vector<TTSChunk> -an Array of one or more TTSChunk elements\r
+        *         specifying the help prompt used in an interaction started by PTT\r
+        */    \r
+    public Vector<TTSChunk> getTimeoutPrompt() {\r
+        if (parameters.get(Names.timeoutPrompt) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.timeoutPrompt);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof TTSChunk) {\r
+                       return (Vector<TTSChunk>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<TTSChunk> newList = new Vector<TTSChunk>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new TTSChunk((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+       /**\r
+        * Sets a Vector<TTSChunk> for Timeout Prompt representing Array of one or\r
+        * more TTSChunk elements specifying the help prompt used in an interaction\r
+        * started by PTT\r
+        * \r
+        */    \r
+    public void setTimeoutPrompt(Vector<TTSChunk> timeoutPrompt) {\r
+        if (timeoutPrompt != null) {\r
+            parameters.put(Names.timeoutPrompt, timeoutPrompt);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a voice recognition Help Title\r
+        * \r
+        * @return String - a String value representing the text, which is shown as\r
+        *         title of the VR help screen used in an interaction started by PTT\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public String getVrHelpTitle() {\r
+        return (String) parameters.get(Names.vrHelpTitle);\r
+    }\r
+\r
+       /**\r
+        * Sets a voice recognition Help Title\r
+        * \r
+        * @param vrHelpTitle\r
+        *            a String value representing a voice recognition Help Title\r
+        *            <p>\r
+        *            <b>Notes: </b><br/>\r
+        *            <ul>\r
+        *            <li>If omitted on supported displays, the default SMARTDEVICELINK help\r
+        *            title will be used</li>\r
+        *            <li>If omitted and one or more vrHelp items are provided, the\r
+        *            request will be rejected.</li>\r
+        *            <li>String Maxlength = 500</li>\r
+        *            </ul>\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public void setVrHelpTitle(String vrHelpTitle) {\r
+        if (vrHelpTitle != null) {\r
+            parameters.put(Names.vrHelpTitle, vrHelpTitle);\r
+        } else {\r
+               parameters.remove(Names.vrHelpTitle);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets items listed in the VR help screen used in an interaction started by\r
+        * PTT\r
+        * \r
+        * @return Vector<VrHelpItem> - a Vector value representing items listed in\r
+        *         the VR help screen used in an interaction started by PTT\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public Vector<VrHelpItem> getVrHelp() {\r
+        if (parameters.get(Names.vrHelp) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.vrHelp);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof VrHelpItem) {\r
+                       return (Vector<VrHelpItem>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<VrHelpItem> newList = new Vector<VrHelpItem>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new VrHelpItem((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * Sets the items listed in the VR help screen used in an interaction\r
+        * started by PTT\r
+        * \r
+        * @param vrHelp\r
+        *            a Vector value representing items listed in the VR help screen\r
+        *            used in an interaction started by PTT\r
+        *            <p>\r
+        *            <b>Notes: </b><br/>\r
+        *            <ul>\r
+        *            <li>If omitted on supported displays, the default SmartDeviceLink VR\r
+        *            help / What Can I Say? screen will be used</li>\r
+        *            <li>If the list of VR Help Items contains nonsequential\r
+        *            positions (e.g. [1,2,4]), the RPC will be rejected</li>\r
+        *            <li>If omitted and a vrHelpTitle is provided, the request\r
+        *            will be rejected</li>\r
+        *            <li>Array Minsize: = 1</li>\r
+        *            <li>Array Maxsize = 100</li>\r
+        *            </ul>\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public void setVrHelp(Vector<VrHelpItem> vrHelp) {\r
+        if (vrHelp != null) {\r
+            parameters.put(Names.vrHelp, vrHelp);\r
+        } else {\r
+               parameters.remove(Names.vrHelp);\r
+        }\r
+    }\r
+}\r
index 1d7e178..ad16c46 100755 (executable)
@@ -1,18 +1,32 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCResponse;
-
-public class SetGlobalPropertiesResponse extends RPCResponse {
-
-    public SetGlobalPropertiesResponse() {
-        super("SetGlobalProperties");
-    }
-    public SetGlobalPropertiesResponse(Hashtable hash) {
-        super(hash);
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Set Global Properties Response is sent, when SetGlobalProperties has been called\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class SetGlobalPropertiesResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new SetGlobalPropertiesResponse object\r
+        */\r
+    public SetGlobalPropertiesResponse() {\r
+        super("SetGlobalProperties");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new SetGlobalPropertiesResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public SetGlobalPropertiesResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
index e21c8f7..299771c 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCRequest;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.UpdateMode;
-import com.smartdevicelink.util.DebugTool;
-
-public class SetMediaClockTimer extends RPCRequest {
-
-    public SetMediaClockTimer() {
-        super("SetMediaClockTimer");
-    }
-    public SetMediaClockTimer(Hashtable hash) {
-        super(hash);
-    }
-    public StartTime getStartTime() {
-        Object obj = parameters.get(Names.startTime);
-        if (obj instanceof StartTime) {
-               return (StartTime)obj;
-        } else if (obj instanceof Hashtable) {
-               return new StartTime((Hashtable)obj);
-        }
-        return null;
-    }
-    public void setStartTime( StartTime startTime ) {
-        if (startTime != null) {
-            parameters.put(Names.startTime, startTime );
-        }
-    }
-    public UpdateMode getUpdateMode() {
-        Object obj = parameters.get(Names.updateMode);
-        if (obj instanceof UpdateMode) {
-            return (UpdateMode) obj;
-        } else if (obj instanceof String) {
-            UpdateMode theCode = null;
-            try {
-                theCode = UpdateMode.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.updateMode, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setUpdateMode( UpdateMode updateMode ) {
-        if (updateMode != null) {
-            parameters.put(Names.updateMode, updateMode );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.UpdateMode;\r
+import com.smartdevicelink.util.DebugTool;\r
+/**\r
+ * Sets the media clock/timer value and the update method (e.g.count-up,\r
+ * count-down, etc.)\r
+ * <p>\r
+ * Function Group: Base <p>\r
+ * <b>HMILevel needs to be FULL, LIMITIED or BACKGROUND</b>\r
+ * </p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class SetMediaClockTimer extends RPCRequest {\r
+       /**\r
+        * Constructs a new SetMediaClockTimer object\r
+        */\r
+    public SetMediaClockTimer() {\r
+        super("SetMediaClockTimer");\r
+    }\r
+       /**\r
+        * Constructs a new SetMediaClockTimer object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */    \r
+    public SetMediaClockTimer(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+       /**\r
+        * Gets the Start Time which media clock timer is set\r
+        * \r
+        * @return StartTime -a StartTime object specifying hour, minute, second\r
+        *         values\r
+        */    \r
+    public StartTime getStartTime() {\r
+        Object obj = parameters.get(Names.startTime);\r
+        if (obj instanceof StartTime) {\r
+               return (StartTime)obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               return new StartTime((Hashtable)obj);\r
+        }\r
+        return null;\r
+    }\r
+       /**\r
+        * Sets a Start Time with specifying hour, minute, second values\r
+        * \r
+        * @param startTime\r
+        *            a startTime object with specifying hour, minute, second values\r
+        *            <p>\r
+        *            <b>Notes: </b>\r
+        *            <ul>\r
+        *            <li>If "updateMode" is COUNTUP or COUNTDOWN, this parameter\r
+        *            must be provided</li>\r
+        *            <li>Will be ignored for PAUSE/RESUME and CLEAR</li>\r
+        *            </ul>\r
+        */    \r
+    public void setStartTime( StartTime startTime ) {\r
+        if (startTime != null) {\r
+            parameters.put(Names.startTime, startTime );\r
+        }\r
+    }\r
+       /**\r
+        * Gets the media clock/timer update mode (COUNTUP/COUNTDOWN/PAUSE/RESUME)\r
+        * \r
+        * @return UpdateMode -a Enumeration value (COUNTUP/COUNTDOWN/PAUSE/RESUME)\r
+        */    \r
+    public UpdateMode getUpdateMode() {\r
+        Object obj = parameters.get(Names.updateMode);\r
+        if (obj instanceof UpdateMode) {\r
+            return (UpdateMode) obj;\r
+        } else if (obj instanceof String) {\r
+            UpdateMode theCode = null;\r
+            try {\r
+                theCode = UpdateMode.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.updateMode, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+       /**\r
+        * Sets the media clock/timer update mode (COUNTUP/COUNTDOWN/PAUSE/RESUME)\r
+        * \r
+        * @param updateMode\r
+        *            a Enumeration value (COUNTUP/COUNTDOWN/PAUSE/RESUME)\r
+        *            <p>\r
+        *            <b>Notes: </b>\r
+        *            <ul>\r
+        *            <li>When updateMode is PAUSE, RESUME or CLEAR, the start time value\r
+        *            is ignored</li>\r
+        *            <li>When updateMode is RESUME, the timer resumes counting from\r
+        *            the timer's value when it was paused</li>\r
+        *            </ul>\r
+        */    \r
+    public void setUpdateMode( UpdateMode updateMode ) {\r
+        if (updateMode != null) {\r
+            parameters.put(Names.updateMode, updateMode );\r
+        }\r
+    }\r
+}\r
index c224b45..5955156 100755 (executable)
@@ -1,18 +1,32 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCResponse;
-
-public class SetMediaClockTimerResponse extends RPCResponse {
-
-    public SetMediaClockTimerResponse() {
-        super("SetMediaClockTimer");
-    }
-    public SetMediaClockTimerResponse(Hashtable hash) {
-        super(hash);
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Set Media Clock Timer Response is sent, when SetMediaClockTimer has been called\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class SetMediaClockTimerResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new SetMediaClockTimerResponse object\r
+        */\r
+    public SetMediaClockTimerResponse() {\r
+        super("SetMediaClockTimer");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new SetMediaClockTimerResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public SetMediaClockTimerResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
index 5093606..f2e7cc2 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCRequest;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.TextAlignment;
-import com.smartdevicelink.util.DebugTool;
-
-public class Show extends RPCRequest {
-
-    public Show() {
-        super("Show");
-    }
-    public Show(Hashtable hash) {
-        super(hash);
-    }
-    public String getMainField1() {
-        return (String) parameters.get( Names.mainField1 );
-    }
-    public void setMainField1( String mainField1 ) {
-        if (mainField1 != null) {
-            parameters.put(Names.mainField1, mainField1 );
-        }
-    }
-    public String getMainField2() {
-        return (String) parameters.get( Names.mainField2 );
-    }
-    public void setMainField2( String mainField2 ) {
-        if (mainField2 != null) {
-            parameters.put(Names.mainField2, mainField2 );
-        }
-    }
-    public TextAlignment getAlignment() {
-        Object obj = parameters.get(Names.alignment);
-        if (obj instanceof TextAlignment) {
-            return (TextAlignment) obj;
-        } else if (obj instanceof String) {
-            TextAlignment theCode = null;
-            try {
-                theCode = TextAlignment.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.alignment, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setAlignment( TextAlignment alignment ) {
-        if (alignment != null) {
-            parameters.put(Names.alignment, alignment );
-        }
-    }
-    public String getStatusBar() {
-        return (String) parameters.get( Names.statusBar );
-    }
-    public void setStatusBar( String statusBar ) {
-        if (statusBar != null) {
-            parameters.put(Names.statusBar, statusBar );
-        }
-    }
-    public String getMediaClock() {
-        return (String) parameters.get( Names.mediaClock );
-    }
-    public void setMediaClock( String mediaClock ) {
-        if (mediaClock != null) {
-            parameters.put(Names.mediaClock, mediaClock );
-        }
-    }
-    public String getMediaTrack() {
-        return (String) parameters.get( Names.mediaTrack );
-    }
-    public void setMediaTrack( String mediaTrack ) {
-        if (mediaTrack != null) {
-            parameters.put(Names.mediaTrack, mediaTrack );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.TextAlignment;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Updates the application's display text area, regardless of whether or not\r
+ * this text area is visible to the user at the time of the request. The\r
+ * application's display text area remains unchanged until updated by subsequent\r
+ * calls to Show\r
+ * <p>\r
+ * The content of the application's display text area is visible to the user\r
+ * when the application's {@linkplain com.smartdevicelink.proxy.rpc.enums.HMILevel}\r
+ * is FULL or LIMITED, and the\r
+ * {@linkplain com.smartdevicelink.proxy.rpc.enums.SystemContext}=MAIN and no\r
+ * {@linkplain Alert} is in progress\r
+ * <p>\r
+ * The Show operation cannot be used to create an animated scrolling screen. To\r
+ * avoid distracting the driver, Show commands cannot be issued more than once\r
+ * every 4 seconds. Requests made more frequently than this will be rejected\r
+ * <p>\r
+ * <b>HMILevel needs to be FULL, LIMITED or BACKGROUND</b>\r
+ * </p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ * @see Alert\r
+ * @see SetMediaClockTimer\r
+ */\r
+public class Show extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new Show object\r
+        */\r
+       public Show() {\r
+        super("Show");\r
+    }\r
+       /**\r
+        * Constructs a new Show object indicated by the Hashtable parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public Show(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+       /**\r
+        * Gets the text displayed in a single-line display, or in the upper display\r
+        * line in a two-line display\r
+        * \r
+        * @return String -a String value representing the text displayed in a\r
+        *         single-line display, or in the upper display line in a two-line\r
+        *         display\r
+        */    \r
+    public String getMainField1() {\r
+        return (String) parameters.get(Names.mainField1);\r
+    }\r
+       /**\r
+        * Sets the text displayed in a single-line display, or in the upper display\r
+        * line in a two-line display\r
+        * \r
+        * @param mainField1\r
+        *            the String value representing the text displayed in a\r
+        *            single-line display, or in the upper display line in a\r
+        *            two-line display\r
+        *            <p>\r
+        *            <b>Notes: </b>\r
+        *            <ul>\r
+        *            <li>If this parameter is omitted, the text of mainField1 does\r
+        *            not change</li>\r
+        *            <li>If this parameter is an empty string, the field will be\r
+        *            cleared</li>\r
+        *            </ul>\r
+        */    \r
+    public void setMainField1(String mainField1) {\r
+        if (mainField1 != null) {\r
+            parameters.put(Names.mainField1, mainField1);\r
+        } else {\r
+               parameters.remove(Names.mainField1);\r
+        }\r
+    }\r
+       /**\r
+        * Gets the text displayed on the second display line of a two-line display\r
+        * \r
+        * @return String -a String value representing the text displayed on the\r
+        *         second display line of a two-line display\r
+        */    \r
+    public String getMainField2() {\r
+        return (String) parameters.get(Names.mainField2);\r
+    }\r
+       /**\r
+        * Sets the text displayed on the second display line of a two-line display\r
+        * \r
+        * @param mainField2\r
+        *            the String value representing the text displayed on the second\r
+        *            display line of a two-line display\r
+        *            <p>\r
+        *            <b>Notes: </b>\r
+        *            <ul>\r
+        *            <li>If this parameter is omitted, the text of mainField2 does\r
+        *            not change</li>\r
+        *            <li>If this parameter is an empty string, the field will be\r
+        *            cleared</li>\r
+        *            <li>If provided and the display is a single-line display, the\r
+        *            parameter is ignored</li>\r
+        *            <li>Maxlength = 500</li>\r
+        *            </ul>\r
+        */    \r
+    public void setMainField2(String mainField2) {\r
+        if (mainField2 != null) {\r
+            parameters.put(Names.mainField2, mainField2);\r
+        } else {\r
+               parameters.remove(Names.mainField2);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets the text displayed on the first display line of the second page\r
+        * \r
+        * @return String -a String value representing the text displayed on the\r
+        *         first display line of the second page\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public String getMainField3() {\r
+        return (String) parameters.get(Names.mainField3);\r
+    }\r
+\r
+       /**\r
+        * Sets the text displayed on the first display line of the second page\r
+        * \r
+        * @param mainField3\r
+        *            the String value representing the text displayed on the first\r
+        *            display line of the second page\r
+        *            <p>\r
+        *            <b>Notes: </b>\r
+        *            <ul>\r
+        *            <li>If this parameter is omitted, the text of mainField3 does\r
+        *            not change</li>\r
+        *            <li>If this parameter is an empty string, the field will be\r
+        *            cleared</li>\r
+        *            <li>If provided and the display is a single-line display, the\r
+        *            parameter is ignored</li>\r
+        *            <li>Maxlength = 500</li>\r
+        *            </ul>\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public void setMainField3(String mainField3) {\r
+        if (mainField3 != null) {\r
+            parameters.put(Names.mainField3, mainField3);\r
+        } else {\r
+               parameters.remove(Names.mainField3);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets the text displayed on the second display line of the second page\r
+        * \r
+        * @return String -a String value representing the text displayed on the\r
+        *         first display line of the second page\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public String getMainField4() {\r
+        return (String) parameters.get(Names.mainField4);\r
+    }\r
+\r
+       /**\r
+        * Sets the text displayed on the second display line of the second page\r
+        * \r
+        * @param mainField4\r
+        *            the String value representing the text displayed on the second\r
+        *            display line of the second page\r
+        *            <p>\r
+        *            <b>Notes: </b>\r
+        *            <ul>\r
+        *            <li>If this parameter is omitted, the text of mainField4 does\r
+        *            not change</li>\r
+        *            <li>If this parameter is an empty string, the field will be\r
+        *            cleared</li>\r
+        *            <li>If provided and the display is a single-line display, the\r
+        *            parameter is ignored</li>\r
+        *            <li>Maxlength = 500</li>\r
+        *            </ul>\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public void setMainField4(String mainField4) {\r
+        if (mainField4 != null) {\r
+            parameters.put(Names.mainField4, mainField4);\r
+        } else {\r
+               parameters.remove(Names.mainField4);\r
+        }\r
+    }\r
+       /**\r
+        * Gets the alignment that Specifies how mainField1 and mainField2 text\r
+        * should be aligned on display\r
+        * \r
+        * @return TextAlignment -an Enumeration value\r
+        */    \r
+    public TextAlignment getAlignment() {\r
+        Object obj = parameters.get(Names.alignment);\r
+        if (obj instanceof TextAlignment) {\r
+            return (TextAlignment) obj;\r
+        } else if (obj instanceof String) {\r
+            TextAlignment theCode = null;\r
+            try {\r
+                theCode = TextAlignment.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.alignment, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+       /**\r
+        * Sets the alignment that Specifies how mainField1 and mainField2 text\r
+        * should be aligned on display\r
+        * \r
+        * @param alignment\r
+        *            an Enumeration value\r
+        *            <p>\r
+        *            <b>Notes: </b>\r
+        *            <ul>\r
+        *            <li>Applies only to mainField1 and mainField2 provided on this\r
+        *            call, not to what is already showing in display</li>\r
+        *            <li>If this parameter is omitted, text in both mainField1 and\r
+        *            mainField2 will be centered</li>\r
+        *            <li>Has no effect with navigation display</li>\r
+        *            </ul>\r
+        */    \r
+    public void setAlignment(TextAlignment alignment) {\r
+        if (alignment != null) {\r
+            parameters.put(Names.alignment, alignment);\r
+        } else {\r
+               parameters.remove(Names.alignment);\r
+        }\r
+    }\r
+       /**\r
+        * Gets text in the Status Bar\r
+        * \r
+        * @return String -the value in the Status Bar\r
+        */    \r
+    public String getStatusBar() {\r
+        return (String) parameters.get(Names.statusBar);\r
+    }\r
+       /**\r
+        * Sets text in the Status Bar\r
+        * \r
+        * @param statusBar\r
+        *            a String representing the text you want to add in the Status\r
+        *            Bar\r
+        *            <p>\r
+        *            <b>Notes: </b><i>The status bar only exists on navigation\r
+        *            displays</i><br/>\r
+        *            <ul>\r
+        *            <li>If this parameter is omitted, the status bar text will\r
+        *            remain unchanged</li>\r
+        *            <li>If this parameter is an empty string, the field will be\r
+        *            cleared</li>\r
+        *            <li>If provided and the display has no status bar, this\r
+        *            parameter is ignored</li>\r
+        *            </ul>\r
+        */    \r
+    public void setStatusBar(String statusBar) {\r
+        if (statusBar != null) {\r
+            parameters.put(Names.statusBar, statusBar);\r
+        } else {\r
+               parameters.remove(Names.statusBar);\r
+        }\r
+    }\r
+       /**\r
+        * Gets the String value of the MediaClock\r
+        * \r
+        * @return String -a String value of the MediaClock\r
+        */    \r
+    public String getMediaClock() {\r
+        return (String) parameters.get(Names.mediaClock);\r
+    }\r
+       /**\r
+        * Sets the value for the MediaClock field using a format described in the\r
+        * MediaClockFormat enumeration\r
+        * \r
+        * @param mediaClock\r
+        *            a String value for the MdaiaClock\r
+        *            <p>\r
+        *            <b>Notes: </b><br/>\r
+        *            <ul>\r
+        *            <li>Must be properly formatted as described in the\r
+        *            MediaClockFormat enumeration</li>\r
+        *            <li>If a value of five spaces is provided, this will clear\r
+        *            that field on the display (i.e. the media clock timer field\r
+        *            will not display anything)</li>\r
+        *            </ul>\r
+        */    \r
+    public void setMediaClock(String mediaClock) {\r
+        if (mediaClock != null) {\r
+            parameters.put(Names.mediaClock, mediaClock);\r
+        } else {\r
+               parameters.remove(Names.mediaClock);\r
+        }\r
+    }\r
+       /**\r
+        * Gets the text in the track field\r
+        * \r
+        * @return String -a String displayed in the track field\r
+        */    \r
+    public String getMediaTrack() {\r
+        return (String) parameters.get(Names.mediaTrack);\r
+    }\r
+       /**\r
+        * Sets the text in the track field\r
+        * \r
+        * @param mediaTrack\r
+        *            a String value disaplayed in the track field\r
+        *            <p>\r
+        *            <b>Notes: </b><br/>\r
+        *            <ul>\r
+        *            <li>If parameter is omitted, the track field remains unchanged</li>\r
+        *            <li>If an empty string is provided, the field will be cleared</li>\r
+        *            <li>This field is only valid for media applications on navigation displays</li>\r
+        *            </ul>\r
+        */    \r
+    public void setMediaTrack(String mediaTrack) {\r
+        if (mediaTrack != null) {\r
+            parameters.put(Names.mediaTrack, mediaTrack);\r
+        } else {\r
+               parameters.remove(Names.mediaTrack);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Sets an image to be shown on supported displays\r
+        * \r
+        * @param graphic\r
+        *            the value representing the image shown on supported displays\r
+        *            <p>\r
+        *            <b>Notes: </b>If omitted on supported displays, the displayed\r
+        *            graphic shall not change<br/>\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public void setGraphic(Image graphic) {\r
+        if (graphic != null) {\r
+            parameters.put(Names.graphic, graphic);\r
+        } else {\r
+               parameters.remove(Names.graphic);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets an image to be shown on supported displays\r
+        * \r
+        * @return Image -the value representing the image shown on supported\r
+        *         displays\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public Image getGraphic() {\r
+       Object obj = parameters.get(Names.graphic);\r
+        if (obj instanceof Image) {\r
+            return (Image) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new Image((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.graphic, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * Gets the Soft buttons defined by the App\r
+        * \r
+        * @return Vector<SoftButton> -a Vector value representing the Soft buttons\r
+        *         defined by the App\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public Vector<SoftButton> getSoftButtons() {\r
+        if (parameters.get(Names.softButtons) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.softButtons);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof SoftButton) {\r
+                       return (Vector<SoftButton>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<SoftButton> newList = new Vector<SoftButton>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new SoftButton((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * Sets the the Soft buttons defined by the App\r
+        * \r
+        * @param softButtons\r
+        *            a Vector value represemting the Soft buttons defined by the\r
+        *            App\r
+        *            <p>\r
+        *            <b>Notes: </b><br/>\r
+        *            <ul>\r
+        *            <li>If omitted on supported displays, the currently displayed\r
+        *            SoftButton values will not change</li>\r
+        *            <li>Array Minsize: 0</li>\r
+        *            <li>Array Maxsize: 8</li>\r
+        *            </ul>\r
+        * \r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public void setSoftButtons(Vector<SoftButton> softButtons) {\r
+        if (softButtons != null) {\r
+            parameters.put(Names.softButtons, softButtons);\r
+        } else {\r
+               parameters.remove(Names.softButtons);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets the Custom Presets defined by the App\r
+        * \r
+        * @return Vector<String> - a Vector value representing the Custom presets\r
+        *         defined by the App\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public Vector<String> getCustomPresets() {\r
+       if (parameters.get(Names.customPresets) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.customPresets);\r
+               if (list != null && list.size()>0) {\r
+                       Object obj = list.get(0);\r
+                       if (obj instanceof String) {\r
+                               return (Vector<String>) list;\r
+                       }\r
+               }\r
+       }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * Sets the Custom Presets defined by the App\r
+        * \r
+        * @param customPresets\r
+        *            a Vector value representing the Custom Presets defined by the\r
+        *            App\r
+        *            <p>\r
+        *            <ul>\r
+        *            <li>If omitted on supported displays, the presets will be shown as not defined</li>\r
+        *            <li>Array Minsize: 0</li>\r
+        *            <li>Array Maxsize: 6</li>\r
+        *            </ul>\r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    public void setCustomPresets(Vector<String> customPresets) {\r
+        if (customPresets != null) {\r
+            parameters.put(Names.customPresets, customPresets);\r
+        } else {\r
+               parameters.remove(Names.customPresets);\r
+        }\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ShowConstantTBT.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ShowConstantTBT.java
new file mode 100755 (executable)
index 0000000..e21afd2
--- /dev/null
@@ -0,0 +1,298 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * This RPC is used to update the user with navigation information for the\r
+ * constantly shown screen (base screen), but also for the alert type screen\r
+ * <p>\r
+ * Function Group: Navigation\r
+ * <p>\r
+ * <b>HMILevel needs to be FULL, LIMITED or BACKGROUND</b>\r
+ * <p>\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ * @see AlertManeuver\r
+ * @see UpdateTurnList\r
+ */\r
+public class ShowConstantTBT extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new ShowConstantTBT object\r
+        */\r
+    public ShowConstantTBT() {\r
+        super("ShowConstantTBT");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new ShowConstantTBT object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public ShowConstantTBT(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+\r
+       /**\r
+        * Sets a text for navigation text field 1\r
+        * \r
+        * @param navigationText1\r
+        *            a String value representing a text for navigation text field 1\r
+        *            <p>\r
+        *            <b>Notes: </b>Maxlength=500\r
+        */\r
+    public void setNavigationText1(String navigationText1) {\r
+        if (navigationText1 != null) {\r
+            parameters.put(Names.navigationText1, navigationText1);\r
+        } else {\r
+               parameters.remove(Names.navigationText1);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a text for navigation text field 1\r
+        * \r
+        * @return String -a String value representing a text for navigation text\r
+        *         field 1\r
+        */\r
+    public String getNavigationText1() {\r
+        return (String) parameters.get(Names.navigationText1);\r
+    }\r
+\r
+       /**\r
+        * Sets a text for navigation text field 2\r
+        * \r
+        * @param navigationText2\r
+        *            a String value representing a text for navigation text field 2\r
+        *            <p>\r
+        *            <b>Notes: </b>Maxlength=500\r
+        */\r
+    public void setNavigationText2(String navigationText2) {\r
+        if (navigationText2 != null) {\r
+            parameters.put(Names.navigationText2, navigationText2);\r
+        } else {\r
+               parameters.remove(Names.navigationText2);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a text for navigation text field 2\r
+        * \r
+        * @return String -a String value representing a text for navigation text\r
+        *         field 2\r
+        */\r
+    public String getNavigationText2() {\r
+        return (String) parameters.get(Names.navigationText2);\r
+    }\r
+\r
+       /**\r
+        * Sets a text field for estimated time of arrival\r
+        * \r
+        * @param eta\r
+        *            a String value representing a text field for estimated time of\r
+        *            arrival\r
+        *            <p>\r
+        *            <b>Notes: </b>Maxlength=500\r
+        */\r
+    public void setEta(String eta) {\r
+        if (eta != null) {\r
+            parameters.put(Names.eta, eta);\r
+        } else {\r
+               parameters.remove(Names.eta);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a text field for estimated time of arrival\r
+        * \r
+        * @return String -a String value representing a text field for estimated\r
+        *         time of arrival\r
+        */\r
+    public String getEta() {\r
+        return (String) parameters.get(Names.eta);\r
+    }\r
+\r
+       /**\r
+        * Sets a text field for total distance\r
+        * \r
+        * @param totalDistance\r
+        *            a String value representing a text field for total distance\r
+        *            <p>\r
+        *            <b>Notes: </b>Maxlength=500\r
+        */\r
+    public void setTotalDistance(String totalDistance) {\r
+        if (totalDistance != null) {\r
+            parameters.put(Names.totalDistance, totalDistance);\r
+        } else {\r
+               parameters.remove(Names.totalDistance);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a text field for total distance\r
+        * \r
+        * @return String -a String value representing a text field for total\r
+        *         distance\r
+        */\r
+    public String getTotalDistance() {\r
+        return (String) parameters.get(Names.totalDistance);\r
+    }\r
+\r
+       /**\r
+        * Sets an Image for turnicon\r
+        * \r
+        * @param turnIcon\r
+        *            an Image value\r
+        */\r
+    public void setTurnIcon(Image turnIcon) {\r
+        if (turnIcon != null) {\r
+            parameters.put(Names.turnIcon, turnIcon);\r
+        } else {\r
+               parameters.remove(Names.turnIcon);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets an Image for turnicon\r
+        * \r
+        * @return Image -an Image value representing an Image for turnicon\r
+        */\r
+    public Image getTurnIcon() {\r
+        Object obj = parameters.get(Names.turnIcon);\r
+        if (obj instanceof Image) {\r
+            return (Image) obj;\r
+        } else {\r
+               return new Image((Hashtable) obj);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Sets a Fraction of distance till next maneuver\r
+        * \r
+        * @param distanceToManeuver\r
+        *            a Double value representing a Fraction of distance till next\r
+        *            maneuver\r
+        *            <p>\r
+        *            <b>Notes: </b>Minvalue=0; Maxvalue=1000000000\r
+        */\r
+    public void setDistanceToManeuver(Double distanceToManeuver) {\r
+        if (distanceToManeuver != null) {\r
+            parameters.put(Names.distanceToManeuver, distanceToManeuver);\r
+        } else {\r
+               parameters.remove(Names.distanceToManeuver);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a Fraction of distance till next maneuver\r
+        * \r
+        * @return Double -a Double value representing a Fraction of distance till\r
+        *         next maneuver\r
+        */\r
+    public Double getDistanceToManeuver() {\r
+        return (Double) parameters.get(Names.distanceToManeuver);\r
+    }\r
+\r
+       /**\r
+        * Sets a Distance till next maneuver (starting from) from previous maneuver\r
+        * \r
+        * @param distanceToManeuverScale\r
+        *            a Double value representing a Distance till next maneuver\r
+        *            (starting from) from previous maneuver\r
+        *            <p>\r
+        *            <b>Notes: </b>Minvalue=0; Maxvalue=1000000000\r
+        */\r
+    public void setDistanceToManeuverScale(Double distanceToManeuverScale) {\r
+        if (distanceToManeuverScale != null) {\r
+            parameters.put(Names.distanceToManeuverScale, distanceToManeuverScale);\r
+        } else {\r
+               parameters.remove(Names.distanceToManeuverScale);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a Distance till next maneuver (starting from) from previous maneuver\r
+        * \r
+        * @return Double -a Double value representing a Distance till next maneuver\r
+        *         (starting from) from previous maneuver\r
+        */\r
+    public Double getDistanceToManeuverScale() {\r
+        return (Double) parameters.get(Names.distanceToManeuverScale);\r
+    }\r
+\r
+       /**\r
+        * Sets a maneuver complete flag. If and when a maneuver has completed while\r
+        * an AlertManeuver is active, the app must send this value set to TRUE in\r
+        * order to clear the AlertManeuver overlay<br/>\r
+        * If omitted the value will be assumed as FALSE\r
+        * <p>\r
+        * \r
+        * @param maneuverComplete\r
+        *            a Boolean value\r
+        */\r
+    public void setManeuverComplete(Boolean maneuverComplete) {\r
+        if (maneuverComplete != null) {\r
+            parameters.put(Names.maneuverComplete, maneuverComplete);\r
+        } else {\r
+               parameters.remove(Names.maneuverComplete);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a maneuver complete flag\r
+        * \r
+        * @return Boolean -a Boolean value\r
+        */\r
+    public Boolean getManeuverComplete() {\r
+        return (Boolean) parameters.get(Names.maneuverComplete);\r
+    }\r
+\r
+       /**\r
+        * Sets Three dynamic SoftButtons available (first SoftButton is fixed to\r
+        * "Turns"). If omitted on supported displays, the currently displayed\r
+        * SoftButton values will not change\r
+        * <p>\r
+        * <b>Notes: </b>Minsize=0; Maxsize=3\r
+        * \r
+        * @param softButtons a Vector<SoftButton> value\r
+        */\r
+    public void setSoftButtons(Vector<SoftButton> softButtons) {\r
+        if (softButtons != null) {\r
+            parameters.put(Names.softButtons, softButtons);\r
+        } else {\r
+               parameters.remove(Names.softButtons);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets Three dynamic SoftButtons available (first SoftButton is fixed to\r
+        * "Turns"). If omitted on supported displays, the currently displayed\r
+        * SoftButton values will not change\r
+        * @return Vector<SoftButton> -a Vector<SoftButton> value\r
+        */\r
+    public Vector<SoftButton> getSoftButtons() {\r
+        if (parameters.get(Names.softButtons) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.softButtons);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof SoftButton) {\r
+                       return (Vector<SoftButton>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<SoftButton> newList = new Vector<SoftButton>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new SoftButton((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ShowConstantTBTResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/ShowConstantTBTResponse.java
new file mode 100755 (executable)
index 0000000..a9ddae4
--- /dev/null
@@ -0,0 +1,32 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Show Constant TBT Response is sent, when ShowConstantTBT has been called\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class ShowConstantTBTResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new ShowConstantTBTResponse object\r
+        */\r
+    public ShowConstantTBTResponse() {\r
+        super("ShowConstantTBT");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new ShowConstantTBTResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public ShowConstantTBTResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
index b97db00..e6f8feb 100755 (executable)
@@ -1,18 +1,32 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCResponse;
-
-public class ShowResponse extends RPCResponse {
-
-    public ShowResponse() {
-        super("Show");
-    }
-    public ShowResponse(Hashtable hash) {
-        super(hash);
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Show Response is sent, when Show has been called\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class ShowResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new ShowResponse object\r
+        */\r
+    public ShowResponse() {\r
+        super("Show");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new ShowResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public ShowResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SingleTireStatus.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SingleTireStatus.java
new file mode 100755 (executable)
index 0000000..8234d64
--- /dev/null
@@ -0,0 +1,77 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.ComponentVolumeStatus;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Tire pressure status of a single tire.\r
+ * <p><b>Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>status</td>\r
+ *                     <td>ComponentVolumeStatus</td>\r
+ *                     <td>Describes the volume status of a single tire\r
+ *                                     See ComponentVolumeStatus\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *  </table>\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class SingleTireStatus extends RPCStruct {\r
+\r
+       /**\r
+        * Constructs a newly allocated SingleTireStatus object\r
+        */\r
+    public SingleTireStatus() { }\r
+    \r
+    /**\r
+     * Constructs a newly allocated SingleTireStatus object indicated by the Hashtable parameter\r
+     * @param hash The Hashtable to use\r
+     */\r
+    public SingleTireStatus(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    \r
+    /**\r
+     *  set the volume status of a single tire\r
+     * @param status  the volume status of a single tire\r
+     */\r
+    public void setStatus(ComponentVolumeStatus status) {\r
+       if (status != null) {\r
+               store.put(Names.status, status);\r
+       } else {\r
+               store.remove(Names.status);\r
+       }\r
+    }\r
+    \r
+    /**\r
+     * get  the volume status of a single tire\r
+     * @return  the volume status of a single tire\r
+     */\r
+    public ComponentVolumeStatus getStatus() {\r
+        Object obj = store.get(Names.status);\r
+        if (obj instanceof ComponentVolumeStatus) {\r
+            return (ComponentVolumeStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               ComponentVolumeStatus theCode = null;\r
+            try {\r
+                theCode = ComponentVolumeStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.status, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/Slider.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/Slider.java
new file mode 100755 (executable)
index 0000000..f1cd804
--- /dev/null
@@ -0,0 +1,177 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Creates a full screen or pop-up overlay (depending on platform) with a single\r
+ * user controlled slider\r
+ * <p>\r
+ * Function Group: Base\r
+ * <p>\r
+ * <b>HMILevel needs to be FULL</b>\r
+ * <p>\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ * \r
+ */\r
+public class Slider extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new Slider object\r
+        */\r
+    public Slider() {\r
+        super("Slider");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new Slider object indicated by the Hashtable parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public Slider(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+\r
+       /**\r
+        * Sets a number of selectable items on a horizontal axis\r
+        * \r
+        * @param numTicks\r
+        *            an Integer value representing a number of selectable items on\r
+        *            a horizontal axis\r
+        *            <p>\r
+        *            <b>Notes: </b>Minvalue=2; Maxvalue=26\r
+        */\r
+    public void setNumTicks(Integer numTicks) {\r
+       if (numTicks != null) {\r
+               parameters.put(Names.numTicks, numTicks);\r
+       } else {\r
+               parameters.remove(Names.numTicks);\r
+       }\r
+    }\r
+\r
+       /**\r
+        * Gets a number of selectable items on a horizontal axis\r
+        * \r
+        * @return Integer -an Integer value representing a number of selectable\r
+        *         items on a horizontal axis\r
+        */\r
+    public Integer getNumTicks() {\r
+       return (Integer) parameters.get(Names.numTicks);\r
+    }\r
+\r
+       /**\r
+        * Sets an Initial position of slider control\r
+        * \r
+        * @param position\r
+        *            an Integer value representing an Initial position of slider\r
+        *            control\r
+        *            <p>\r
+        *            <b>Notes: </b>Minvalue=1; Maxvalue=26\r
+        */\r
+    public void setPosition(Integer position) {\r
+       if (position != null) {\r
+               parameters.put(Names.position, position);\r
+       } else {\r
+               parameters.remove(Names.position);\r
+       }\r
+    }\r
+\r
+       /**\r
+        * Gets an Initial position of slider control\r
+        * \r
+        * @return Integer -an Integer value representing an Initial position of\r
+        *         slider control\r
+        */\r
+    public Integer getPosition() {\r
+       return (Integer) parameters.get(Names.position);\r
+    }\r
+\r
+       /**\r
+        * Sets a text header to display\r
+        * \r
+        * @param sliderHeader\r
+        *            a String value\r
+        *            <p>\r
+        *            <b>Notes: </b>Maxlength=500\r
+        */\r
+    public void setSliderHeader(String sliderHeader) {\r
+       if (sliderHeader != null) {\r
+               parameters.put(Names.sliderHeader, sliderHeader);\r
+       } else {\r
+               parameters.remove(Names.sliderHeader);\r
+       }\r
+    }\r
+\r
+       /**\r
+        * Gets a text header to display\r
+        * \r
+        * @return String -a String value representing a text header to display\r
+        */\r
+    public String getSliderHeader() {\r
+       return (String) parameters.get(Names.sliderHeader);\r
+    }\r
+\r
+       /**\r
+        * Sets a text footer to display\r
+        * \r
+        * @param sliderFooter\r
+        *            a Vector<String> value representing a text footer to display\r
+        *            <p>\r
+        *            <b>Notes: </b>Maxlength=500; Minvalue=1; Maxvalue=26\r
+        */\r
+    public void setSliderFooter(Vector<String> sliderFooter) {\r
+       if (sliderFooter != null) {\r
+               parameters.put(Names.sliderFooter, sliderFooter);\r
+       } else {\r
+               parameters.remove(Names.sliderFooter);\r
+       }\r
+    }\r
+\r
+       /**\r
+        * Gets a text footer to display\r
+        * \r
+        * @return String -a String value representing a text footer to display\r
+        */\r
+    public Vector<String> getSliderFooter() {\r
+        if (parameters.get(Names.sliderFooter) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.sliderFooter);\r
+               if (list != null && list.size()>0) {\r
+                       Object obj = list.get(0);\r
+                       if (obj instanceof String) {\r
+                               return (Vector<String>) list;\r
+                       }\r
+               }\r
+        }\r
+       return null;\r
+    }\r
+\r
+       /**\r
+        * Sets an App defined timeout\r
+        * \r
+        * @param timeout\r
+        *            an Integer value representing an App defined timeout\r
+        *            <p>\r
+        *            <b>Notes: </b>Minvalue=0; Maxvalue=65535; Defvalue=10000\r
+        */\r
+    public void setTimeout(Integer timeout) {\r
+       if (timeout != null) {\r
+               parameters.put(Names.timeout, timeout);\r
+       } else {\r
+               parameters.remove(Names.timeout);\r
+       }\r
+    }\r
+\r
+       /**\r
+        * Gets an App defined timeout\r
+        * @return Integer -an Integer value representing an App defined timeout\r
+        */\r
+    public Integer getTimeout() {\r
+       return (Integer) parameters.get(Names.timeout);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SliderResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SliderResponse.java
new file mode 100755 (executable)
index 0000000..3d44ff4
--- /dev/null
@@ -0,0 +1,51 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Slider Response is sent, when Slider has been called\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class SliderResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new SliderResponse object\r
+        */\r
+    public SliderResponse() {\r
+        super("Slider");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new SliderResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public SliderResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * Sets an Initial position of slider control\r
+     * @param sliderPosition\r
+     */\r
+    public void setSliderPosition(Integer sliderPosition) {\r
+       if (sliderPosition != null) {\r
+               parameters.put(Names.sliderPosition, sliderPosition);\r
+       } else {\r
+               parameters.remove(Names.sliderPosition);\r
+       }\r
+    }\r
+    /**\r
+     * Gets an Initial position of slider control\r
+     * @return Integer\r
+     */\r
+    public Integer getSliderPosition() {\r
+       return (Integer) parameters.get(Names.sliderPosition);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SoftButton.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SoftButton.java
new file mode 100755 (executable)
index 0000000..d0f46de
--- /dev/null
@@ -0,0 +1,111 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.SoftButtonType;\r
+import com.smartdevicelink.proxy.rpc.enums.SystemAction;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+public class SoftButton extends RPCStruct {\r
+\r
+    public SoftButton() { }\r
+    public SoftButton(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public void setType(SoftButtonType type) {\r
+        if (type != null) {\r
+            store.put(Names.type, type);\r
+        } else {\r
+               store.remove(Names.type);\r
+        }\r
+    }\r
+    public SoftButtonType getType() {\r
+       Object obj = store.get(Names.type);\r
+        if (obj instanceof SoftButtonType) {\r
+            return (SoftButtonType) obj;\r
+        } else if (obj instanceof String) {\r
+               SoftButtonType theCode = null;\r
+            try {\r
+                theCode = SoftButtonType.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.type, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setText(String text) {\r
+        if (text != null) {\r
+            store.put(Names.text, text);\r
+        } else {\r
+               store.remove(Names.text);\r
+        }\r
+    }\r
+    public String getText() {\r
+        return (String) store.get(Names.text);\r
+    }\r
+    public void setImage(Image image) {\r
+        if (image != null) {\r
+            store.put(Names.image, image);\r
+        } else {\r
+               store.remove(Names.image);\r
+        }\r
+    }\r
+    public Image getImage() {\r
+       Object obj = store.get(Names.image);\r
+        if (obj instanceof Image) {\r
+            return (Image) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new Image((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.image, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setIsHighlighted(Boolean isHighlighted) {\r
+        if (isHighlighted != null) {\r
+            store.put(Names.isHighlighted, isHighlighted);\r
+        } else {\r
+               store.remove(Names.isHighlighted);\r
+        }\r
+    }\r
+    public Boolean getIsHighlighted() {\r
+        return (Boolean) store.get(Names.isHighlighted);\r
+    }\r
+    public void setSoftButtonID(Integer softButtonID) {\r
+        if (softButtonID != null) {\r
+            store.put(Names.softButtonID, softButtonID);\r
+        } else {\r
+               store.remove(Names.softButtonID);\r
+        }\r
+    }\r
+    public Integer getSoftButtonID() {\r
+        return (Integer) store.get(Names.softButtonID);\r
+    }\r
+    public void setSystemAction(SystemAction systemAction) {\r
+        if (systemAction != null) {\r
+            store.put(Names.systemAction, systemAction);\r
+        } else {\r
+               store.remove(Names.systemAction);\r
+        }\r
+    }\r
+    public SystemAction getSystemAction() {\r
+       Object obj = store.get(Names.systemAction);\r
+        if (obj instanceof SystemAction) {\r
+            return (SystemAction) obj;\r
+        } else if (obj instanceof String) {\r
+               SystemAction theCode = null;\r
+            try {\r
+                theCode = SystemAction.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.systemAction, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SoftButtonCapabilities.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SoftButtonCapabilities.java
new file mode 100755 (executable)
index 0000000..59b8291
--- /dev/null
@@ -0,0 +1,146 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Contains information about a SoftButton's capabilities.\r
+ * <p><b>Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>shortPressAvailable</td>\r
+ *                     <td>Boolean</td>\r
+ *                     <td>The button supports a short press.\r
+ *                                     Whenever the button is pressed short, onButtonPressed( SHORT) will be invoked.\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>longPressAvailable</td>\r
+ *                     <td>Boolean</td>\r
+ *                     <td>The button supports a LONG press.\r
+ *                                     Whenever the button is pressed long, onButtonPressed( LONG) will be invoked.\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>upDownAvailable</td>\r
+ *                     <td>Boolean</td>\r
+ *                     <td>The button supports "button down" and "button up". Whenever the button is pressed, onButtonEvent( DOWN) will be invoked.\r
+ *                                     Whenever the button is released, onButtonEvent( UP) will be invoked. *                  \r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>imageSupported</td>\r
+ *                     <td>Boolean</td>\r
+ *                     <td>The button supports referencing a static or dynamic image.\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr> \r
+ *  </table>\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class SoftButtonCapabilities extends RPCStruct {\r
+\r
+       /**\r
+        * Constructs a newly allocated SoftButtonCapabilities object\r
+        */\r
+    public SoftButtonCapabilities() { }\r
+    \r
+    /**\r
+     * Constructs a newly allocated SoftButtonCapabilities object indicated by the Hashtable parameter\r
+     * @param hash The Hashtable to use\r
+     */\r
+    public SoftButtonCapabilities(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    \r
+    /**\r
+     * set the button supports a short press.\r
+     * @param shortPressAvailable whether the button supports a short press.\r
+     */\r
+    public void setShortPressAvailable(Boolean shortPressAvailable) {\r
+        if (shortPressAvailable != null) {\r
+            store.put(Names.shortPressAvailable, shortPressAvailable);\r
+        } else {\r
+               store.remove(Names.shortPressAvailable);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get whether the button supports a short press.\r
+     * @return whether the button supports a short press\r
+     */\r
+    public Boolean getShortPressAvailable() {\r
+        return (Boolean) store.get( Names.shortPressAvailable);\r
+    }\r
+    \r
+    /**\r
+     * set the button supports a LONG press.\r
+     * @param longPressAvailable whether the button supports a long press\r
+     */\r
+    public void setLongPressAvailable(Boolean longPressAvailable) {\r
+        if (longPressAvailable != null) {\r
+            store.put(Names.longPressAvailable, longPressAvailable);\r
+        } else {\r
+               store.remove(Names.longPressAvailable);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get whether  the button supports a LONG press.\r
+     * @return whether  the button supports a LONG press\r
+     */\r
+    public Boolean getLongPressAvailable() {\r
+        return (Boolean) store.get( Names.longPressAvailable);\r
+    }\r
+    \r
+    /**\r
+     * set the button supports "button down" and "button up". \r
+     * @param upDownAvailable the button supports "button down" and "button up". \r
+     */\r
+    public void setUpDownAvailable(Boolean upDownAvailable) {\r
+        if (upDownAvailable != null) {\r
+            store.put(Names.upDownAvailable, upDownAvailable);\r
+        } else {\r
+               store.remove(Names.upDownAvailable);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get the button supports "button down" and "button up".\r
+     * @return the button supports "button down" and "button up".\r
+     */\r
+    public Boolean getUpDownAvailable() {\r
+        return (Boolean) store.get( Names.upDownAvailable);\r
+    }\r
+    \r
+    /**\r
+     * set the button supports referencing a static or dynamic image.\r
+     * @param imageSupported whether the button supports referencing a static or dynamic image.\r
+     */\r
+    public void setImageSupported(Boolean imageSupported) {\r
+        if (imageSupported != null) {\r
+            store.put(Names.imageSupported, imageSupported);\r
+        } else {\r
+               store.remove(Names.imageSupported);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get the button supports referencing a static or dynamic image.\r
+     * @return the button supports referencing a static or dynamic image.\r
+     */\r
+    public Boolean getImageSupported() {\r
+        return (Boolean) store.get( Names.imageSupported);\r
+    }\r
+}\r
index 9c5ed4a..3a099ee 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-import java.util.Vector;
-
-import com.smartdevicelink.proxy.RPCRequest;
-import com.smartdevicelink.proxy.constants.Names;
-
-public class Speak extends RPCRequest {
-
-    public Speak() {
-        super("Speak");
-    }
-    public Speak(Hashtable hash) {
-        super(hash);
-    }
-    public Vector<TTSChunk> getTtsChunks() {
-       if (parameters.get(Names.ttsChunks) instanceof Vector<?>) {
-               Vector<?> list = (Vector<?>)parameters.get(Names.ttsChunks);
-               if (list != null && list.size() > 0) {
-                   Object obj = list.get(0);
-                   if (obj instanceof TTSChunk) {
-                       return (Vector<TTSChunk>) list;
-                   } else if (obj instanceof Hashtable) {
-                       Vector<TTSChunk> newList = new Vector<TTSChunk>();
-                       for (Object hashObj : list) {
-                           newList.add(new TTSChunk((Hashtable)hashObj));
-                       }
-                       return newList;
-                   }
-               }
-       }
-        return null;
-    }
-    public void setTtsChunks( Vector<TTSChunk> ttsChunks ) {
-        if (ttsChunks != null) {
-            parameters.put(Names.ttsChunks, ttsChunks );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Speaks a phrase over the vehicle audio system using SMARTDEVICELINK's TTS\r
+ * (text-to-speech) engine. The provided text to be spoken can be simply a text\r
+ * phrase, or it can consist of phoneme specifications to direct SMARTDEVICELINK's TTS\r
+ * engine to speak a "speech-sculpted" phrase\r
+ * <p>\r
+ * Receipt of the Response indicates the completion of the Speak operation,\r
+ * regardless of how the Speak operation may have completed (i.e. successfully,\r
+ * interrupted, terminated, etc.)\r
+ * <p>\r
+ * Requesting a new Speak operation while the application has another Speak\r
+ * operation already in progress (i.e. no corresponding Response for that\r
+ * in-progress Speak operation has been received yet) will terminate the\r
+ * in-progress Speak operation (causing its corresponding Response to be sent by\r
+ * SMARTDEVICELINK) and begin the requested Speak operation\r
+ * <p>\r
+ * Requesting a new Speak operation while the application has an <i>\r
+ * {@linkplain Alert}</i> operation already in progress (i.e. no corresponding\r
+ * Response for that in-progress <i>{@linkplain Alert}</i> operation has been\r
+ * received yet) will result in the Speak operation request being rejected\r
+ * (indicated in the Response to the Request)\r
+ * <p>\r
+ * Requesting a new <i>{@linkplain Alert}</i> operation while the application\r
+ * has a Speak operation already in progress (i.e. no corresponding Response for\r
+ * that in-progress Speak operation has been received yet) will terminate the\r
+ * in-progress Speak operation (causing its corresponding Response to be sent by\r
+ * SMARTDEVICELINK) and begin the requested <i>{@linkplain Alert}</i> operation\r
+ * <p>\r
+ * Requesting a new Speak operation while the application has a <i>\r
+ * {@linkplain PerformInteraction}</i> operation already in progress (i.e. no\r
+ * corresponding Response for that in-progress <i>\r
+ * {@linkplain PerformInteraction}</i> operation has been received yet) will\r
+ * result in the Speak operation request being rejected (indicated in the\r
+ * Response to the Request)\r
+ * <p>\r
+ * Requesting a <i> {@linkplain PerformInteraction}</i> operation while the\r
+ * application has a Speak operation already in progress (i.e. no corresponding\r
+ * Response for that in-progress Speak operation has been received yet) will\r
+ * terminate the in-progress Speak operation (causing its corresponding Response\r
+ * to be sent by SMARTDEVICELINK) and begin the requested <i>\r
+ * {@linkplain PerformInteraction}</i> operation\r
+ * <p>\r
+ * \r
+ * <b>HMI Status Requirements:</b><br/>\r
+ * HMILevel: FULL, Limited<br/>\r
+ * AudioStreamingState: Any<br/>\r
+ * SystemContext: MAIN, MENU, VR\r
+ * </p>\r
+ * <b>Notes: </b>\r
+ * <ul>\r
+ * <li>When <i>{@linkplain Alert}</i> is issued with MENU in effect, <i>\r
+ * {@linkplain Alert}</i> is queued and "played" when MENU interaction is\r
+ * completed (i.e. SystemContext reverts to MAIN). When <i>{@linkplain Alert}\r
+ * </i> is issued with VR in effect, <i>{@linkplain Alert}</i> is queued and\r
+ * "played" when VR interaction is completed (i.e. SystemContext reverts to\r
+ * MAIN)</li>\r
+ * <li>When both <i>{@linkplain Alert}</i> and Speak are queued during MENU or\r
+ * VR, they are "played" back in the order in which they were queued, with all\r
+ * existing rules for "collisions" still in effect</li>\r
+ * </ul>\r
+ * <p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ * @see Alert\r
+ */\r
+public class Speak extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new Speak object\r
+        */    \r
+       public Speak() {\r
+        super("Speak");\r
+    }\r
+       /**\r
+        * Constructs a new Speak object indicated by the Hashtable parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */     \r
+    public Speak(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+       /**\r
+        * Gets a Vector<TTSChunk> representing an array of 1-100 TTSChunk structs\r
+        * which, taken together, specify the phrase to be spoken\r
+        * \r
+        * @return Vector<TTSChunk> -an Array of 1-100 TTSChunk specify the phrase to be spoken\r
+        */    \r
+    public Vector<TTSChunk> getTtsChunks() {\r
+       if (parameters.get(Names.ttsChunks) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.ttsChunks);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof TTSChunk) {\r
+                       return (Vector<TTSChunk>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<TTSChunk> newList = new Vector<TTSChunk>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new TTSChunk((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+       }\r
+        return null;\r
+    }\r
+       /**\r
+        * Sets a Vector<TTSChunk> representing an array of 1-100 TTSChunk structs\r
+        * which, taken together, specify the phrase to be spoken\r
+        * \r
+        * @param ttsChunks\r
+        *            a Vector<TTSChunk> value representing an array of 1-100 TTSChunk structs\r
+        * which specify the phrase to be spoken\r
+        *            <p>\r
+        *            <ul>\r
+        *            <li>The array must have 1-100 elements</li>\r
+        *            <li>The total length of the phrase composed from the ttsChunks\r
+        *            provided must be less than 500 characters or the request will\r
+        *            be rejected</li>\r
+        *            <li>Each chunk can be no more than 500 characters</li>\r
+        *            </ul>\r
+        */    \r
+    public void setTtsChunks( Vector<TTSChunk> ttsChunks ) {\r
+        if (ttsChunks != null) {\r
+            parameters.put(Names.ttsChunks, ttsChunks );\r
+        }\r
+    }\r
+}\r
index 06fa77f..681feec 100755 (executable)
@@ -1,18 +1,32 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCResponse;
-
-public class SpeakResponse extends RPCResponse {
-
-    public SpeakResponse() {
-        super("Speak");
-    }
-    public SpeakResponse(Hashtable hash) {
-        super(hash);
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Speak Response is sent, when Speak has been called\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class SpeakResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new SpeakResponse object\r
+        */\r
+    public SpeakResponse() {\r
+        super("Speak");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new SpeakResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public SpeakResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
index 23802de..404dc30 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCStruct;
-import com.smartdevicelink.proxy.constants.Names;
-
-public class StartTime extends RPCStruct {
-
-    public StartTime() { }
-    public StartTime(Hashtable hash) {
-        super(hash);
-    }
-    public Integer getHours() {
-        return (Integer) store.get( Names.hours );
-    }
-    public void setHours( Integer hours ) {
-        if (hours != null) {
-            store.put(Names.hours, hours );
-        }
-    }
-    public Integer getMinutes() {
-        return (Integer) store.get( Names.minutes );
-    }
-    public void setMinutes( Integer minutes ) {
-        if (minutes != null) {
-            store.put(Names.minutes, minutes );
-        }
-    }
-    public Integer getSeconds() {
-        return (Integer) store.get( Names.seconds );
-    }
-    public void setSeconds( Integer seconds ) {
-        if (seconds != null) {
-            store.put(Names.seconds, seconds );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Describes the hour, minute and second values used to set the media clock.\r
+ * <p><b> Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>hours</td>\r
+ *                     <td>Int16</td>\r
+ *                     <td>The hour. Minvalue="0", maxvalue="59"\r
+ *                                     <p><b>Note:</b>Some display types only support a max value of 19. If out of range, it will be rejected.\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+  *            <tr>\r
+ *                     <td>minutes</td>\r
+ *                     <td>Int16</td>\r
+ *                     <td>The minute. Minvalue="0", maxvalue="59".</td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ *     <tr>\r
+ *                     <td>seconds</td>\r
+ *                     <td>Int16</td>\r
+ *                     <td>The second. Minvalue="0", maxvalue="59".</td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ * </table>\r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class StartTime extends RPCStruct {\r
+\r
+       /**\r
+        * Constructs a newly allocated StartTime object\r
+        */\r
+       public StartTime() { }\r
+    /**\r
+     * Constructs a newly allocated StartTime object indicated by the Hashtable parameter\r
+     * @param hash The Hashtable to use\r
+     */\r
+    public StartTime(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * Get the hour. Minvalue="0", maxvalue="59"\r
+ *                                     <p><b>Note:</b>Some display types only support a max value of 19. If out of range, it will be rejected.\r
+     * @return hours Minvalue="0", maxvalue="59"\r
+     */    \r
+    public Integer getHours() {\r
+        return (Integer) store.get( Names.hours );\r
+    }\r
+    /**\r
+     * Set the hour. Minvalue="0", maxvalue="59"\r
+ *                                     <p><b>Note:</b>Some display types only support a max value of 19. If out of range, it will be rejected.\r
+     * @param hours min: 0; max: 59\r
+     */    \r
+    public void setHours( Integer hours ) {\r
+        if (hours != null) {\r
+            store.put(Names.hours, hours );\r
+        }\r
+    }\r
+    /**\r
+     * Get the minute. Minvalue="0", maxvalue="59".\r
+     * @return minutes Minvalue="0", maxvalue="59"\r
+     */    \r
+    public Integer getMinutes() {\r
+        return (Integer) store.get( Names.minutes );\r
+    }\r
+    /**\r
+     * Set the minute. Minvalue="0", maxvalue="59".\r
+     * @param minutes min: 0; max: 59\r
+     */    \r
+    public void setMinutes( Integer minutes ) {\r
+        if (minutes != null) {\r
+            store.put(Names.minutes, minutes );\r
+        }\r
+    }\r
+    /**\r
+     * Get the second. Minvalue="0", maxvalue="59".\r
+     * @return seconds. Minvalue="0", maxvalue="59".\r
+     */    \r
+    public Integer getSeconds() {\r
+        return (Integer) store.get( Names.seconds );\r
+    }\r
+    /**\r
+     * Set the second. Minvalue="0", maxvalue="59".\r
+     * @param seconds min: 0 max: 59\r
+     */    \r
+    public void setSeconds( Integer seconds ) {\r
+        if (seconds != null) {\r
+            store.put(Names.seconds, seconds );\r
+        }\r
+    }\r
+}\r
index 671ffcf..426cf12 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCRequest;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.ButtonName;
-import com.smartdevicelink.util.DebugTool;
-
-public class SubscribeButton extends RPCRequest {
-
-    public SubscribeButton() {
-        super("SubscribeButton");
-    }
-    public SubscribeButton(Hashtable hash) {
-        super(hash);
-    }
-    public ButtonName getButtonName() {
-        Object obj = parameters.get(Names.buttonName);
-        if (obj instanceof ButtonName) {
-            return (ButtonName) obj;
-        } else if (obj instanceof String) {
-            ButtonName theCode = null;
-            try {
-                theCode = ButtonName.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.buttonName, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setButtonName( ButtonName buttonName ) {
-        if (buttonName != null) {
-            parameters.put(Names.buttonName, buttonName );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.ButtonName;\r
+import com.smartdevicelink.util.DebugTool;\r
+/**\r
+ * Establishes a subscription to button notifications for HMI buttons. Buttons\r
+ * are not necessarily physical buttons, but can also be "soft" buttons on a\r
+ * touch screen, depending on the display in the vehicle. Once subscribed to a\r
+ * particular button, an application will receive both\r
+ * {@linkplain OnButtonEvent} and {@linkplain OnButtonPress} notifications\r
+ * whenever that button is pressed. The application may also unsubscribe from\r
+ * notifications for a button by invoking the {@linkplain UnsubscribeButton}\r
+ * operation\r
+ * <p>\r
+ * When a button is depressed, an {@linkplain OnButtonEvent} notification is\r
+ * sent to the application with a ButtonEventMode of BUTTONDOWN. When that same\r
+ * button is released, an {@linkplain OnButtonEvent} notification is sent to the\r
+ * application with a ButtonEventMode of BUTTONUP\r
+ * <p>\r
+ * When the duration of a button depression (that is, time between depression\r
+ * and release) is less than two seconds, an {@linkplain OnButtonPress}\r
+ * notification is sent to the application (at the moment the button is\r
+ * released) with a ButtonPressMode of SHORT. When the duration is two or more\r
+ * seconds, an {@linkplain OnButtonPress} notification is sent to the\r
+ * application (at the moment the two seconds have elapsed) with a\r
+ * ButtonPressMode of LONG\r
+ * <p>\r
+ * The purpose of {@linkplain OnButtonPress} notifications is to allow for\r
+ * programmatic detection of long button presses similar to those used to store\r
+ * presets while listening to the radio, for example\r
+ * <p>\r
+ * When a button is depressed and released, the sequence in which notifications\r
+ * will be sent to the application is as follows:\r
+ * <p>\r
+ * For short presses:<br/>\r
+ * <ul>\r
+ * <li>OnButtonEvent (ButtonEventMode = BUTTONDOWN)</li>\r
+ * <li>OnButtonEvent (ButtonEventMode = BUTTONUP)</li>\r
+ * <li>OnButtonPress (ButtonPressMode = SHORT)</li>\r
+ * </ul>\r
+ * <p>\r
+ * For long presses:<br/>\r
+ * <ul>\r
+ * <li>OnButtonEvent (ButtonEventMode = BUTTONDOWN)</li>\r
+ * <li>OnButtonEvent (ButtonEventMode = BUTTONUP)</li>\r
+ * <li>OnButtonPress (ButtonPressMode = LONG)</li>\r
+ * </ul>\r
+ * <p>\r
+ * <b>HMILevel needs to be FULL, LIMITED or BACKGROUND</b>\r
+ * </p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ * @see UnsubscribeButton\r
+ */\r
+public class SubscribeButton extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new SubscribeButton object\r
+        */\r
+    public SubscribeButton() {\r
+        super("SubscribeButton");\r
+    }\r
+       /**\r
+        * Constructs a new SubscribeButton object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */    \r
+    public SubscribeButton(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+       /**\r
+        * Gets the name of the button to subscribe to\r
+        * @return ButtonName -an enum value, see <i>{@linkplain com.smartdevicelink.proxy.rpc.enums.ButtonName}</i>\r
+        */    \r
+    public ButtonName getButtonName() {\r
+        Object obj = parameters.get(Names.buttonName);\r
+        if (obj instanceof ButtonName) {\r
+            return (ButtonName) obj;\r
+        } else if (obj instanceof String) {\r
+            ButtonName theCode = null;\r
+            try {\r
+                theCode = ButtonName.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.buttonName, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+       /**\r
+        * Sets a name of the button to subscribe to\r
+        * @param buttonName a <i>{@linkplain com.smartdevicelink.proxy.rpc.enums.ButtonName}</i> value\r
+        */    \r
+    public void setButtonName( ButtonName buttonName ) {\r
+        if (buttonName != null) {\r
+            parameters.put(Names.buttonName, buttonName );\r
+        }\r
+    }\r
+}\r
index 1e33931..48acf55 100755 (executable)
@@ -1,18 +1,32 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCResponse;
-
-public class SubscribeButtonResponse extends RPCResponse {
-
-    public SubscribeButtonResponse() {
-        super("SubscribeButton");
-    }
-    public SubscribeButtonResponse(Hashtable hash) {
-        super(hash);
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Sub scribeButton Response is sent, when SubscribeButton has been called\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class SubscribeButtonResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new SubscribeButtonResponse object\r
+        */\r
+    public SubscribeButtonResponse() {\r
+        super("SubscribeButton");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new SubscribeButtonResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public SubscribeButtonResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SubscribeVehicleData.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SubscribeVehicleData.java
new file mode 100755 (executable)
index 0000000..09f829e
--- /dev/null
@@ -0,0 +1,919 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.VehicleDataType;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Subscribes for specific published vehicle data items. The data will be only\r
+ * sent, if it has changed. The application will be notified by the\r
+ * onVehicleData notification whenever new data is available. The update rate is\r
+ * very much dependent on sensors, vehicle architecture and vehicle type. Be\r
+ * also prepared for the situation that a signal is not available on a vehicle\r
+ * <p>\r
+ * Function Group: Location, VehicleInfo and DrivingChara\r
+ * <p>\r
+ * <b>HMILevel needs to be FULL, LIMITED or BACKGROUND</b>\r
+ * </p>\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ * @see UnsubscribeVehicleData\r
+ * @see GetVehicleData\r
+ */\r
+public class SubscribeVehicleData extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new SubscribeVehicleData object\r
+        */\r
+    public SubscribeVehicleData() {\r
+        super("SubscribeVehicleData");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new SubscribeVehicleData object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public SubscribeVehicleData(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes Gps data\r
+        * \r
+        * @param gps\r
+        *            a boolean value\r
+        */\r
+    public void setGps(Boolean gps) {\r
+        if (gps != null) {\r
+            parameters.put(Names.gps, gps);\r
+        } else {\r
+               parameters.remove(Names.gps);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Gps data has been subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Gps data has been\r
+        *         subscribed.\r
+        */\r
+    public Boolean getGps() {\r
+        return (Boolean) parameters.get(Names.gps);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes speed data\r
+        * \r
+        * @param speed\r
+        *            a boolean value\r
+        */\r
+    public void setSpeed(Boolean speed) {\r
+        if (speed != null) {\r
+            parameters.put(Names.speed, speed);\r
+        } else {\r
+               parameters.remove(Names.speed);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Speed data has been subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Speed data has been\r
+        *         subscribed.\r
+        */\r
+    public Boolean getSpeed() {\r
+        return (Boolean) parameters.get(Names.speed);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes rpm data\r
+        * \r
+        * @param rpm\r
+        *            a boolean value\r
+        */\r
+    public void setRpm(Boolean rpm) {\r
+        if (rpm != null) {\r
+            parameters.put(Names.rpm, rpm);\r
+        } else {\r
+               parameters.remove(Names.rpm);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the rpm data has been subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the rpm data has been\r
+        *         subscribed.\r
+        */\r
+    public Boolean getRpm() {\r
+        return (Boolean) parameters.get(Names.rpm);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes FuelLevel data\r
+        * \r
+        * @param fuelLevel\r
+        *            a boolean value\r
+        */\r
+    public void setFuelLevel(Boolean fuelLevel) {\r
+        if (fuelLevel != null) {\r
+            parameters.put(Names.fuelLevel, fuelLevel);\r
+        } else {\r
+               parameters.remove(Names.fuelLevel);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the FuelLevel data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the FuelLevel data has\r
+        *         been subscribed.\r
+        */\r
+    public Boolean getFuelLevel() {\r
+        return (Boolean) parameters.get(Names.fuelLevel);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes fuelLevel_State data\r
+        * \r
+        * @param fuelLevel_State\r
+        *            a boolean value\r
+        */\r
+    public void setFuelLevel_State(Boolean fuelLevel_State) {\r
+        if (fuelLevel_State != null) {\r
+            parameters.put(Names.fuelLevel_State, fuelLevel_State);\r
+        } else {\r
+               parameters.remove(Names.fuelLevel_State);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the fuelLevel_State data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the fuelLevel_State data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getFuelLevel_State() {\r
+        return (Boolean) parameters.get(Names.fuelLevel_State);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes instantFuelConsumption data\r
+        * \r
+        * @param instantFuelConsumption\r
+        *            a boolean value\r
+        */\r
+    public void setInstantFuelConsumption(Boolean instantFuelConsumption) {\r
+        if (instantFuelConsumption != null) {\r
+            parameters.put(Names.instantFuelConsumption, instantFuelConsumption);\r
+        } else {\r
+               parameters.remove(Names.instantFuelConsumption);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the getInstantFuelConsumption data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the getInstantFuelConsumption data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getInstantFuelConsumption() {\r
+        return (Boolean) parameters.get(Names.instantFuelConsumption);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes externalTemperature data\r
+        * \r
+        * @param externalTemperature\r
+        *            a boolean value\r
+        */\r
+    public void setExternalTemperature(Boolean externalTemperature) {\r
+        if (externalTemperature != null) {\r
+            parameters.put(Names.externalTemperature, externalTemperature);\r
+        } else {\r
+               parameters.remove(Names.externalTemperature);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the externalTemperature data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the externalTemperature data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getExternalTemperature() {\r
+        return (Boolean) parameters.get(Names.externalTemperature);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes Currently selected gear data\r
+        * \r
+        * @param prndl\r
+        *            a boolean value\r
+        */\r
+    public void setPrndl(Boolean prndl) {\r
+        if (prndl != null) {\r
+            parameters.put(Names.prndl, prndl);\r
+        } else {\r
+               parameters.remove(Names.prndl);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Currently selected gear data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Currently selected gear data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getPrndl() {\r
+        return (Boolean) parameters.get(Names.prndl);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes tire pressure status data\r
+        * \r
+        * @param tirePressure\r
+        *            a boolean value\r
+        */\r
+    public void setTirePressure(Boolean tirePressure) {\r
+        if (tirePressure != null) {\r
+            parameters.put(Names.tirePressure, tirePressure);\r
+        } else {\r
+               parameters.remove(Names.tirePressure);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the tire pressure status data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the tire pressure status data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getTirePressure() {\r
+        return (Boolean) parameters.get(Names.tirePressure);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes odometer data\r
+        * \r
+        * @param odometer\r
+        *            a boolean value\r
+        */\r
+    public void setOdometer(Boolean odometer) {\r
+        if (odometer != null) {\r
+            parameters.put(Names.odometer, odometer);\r
+        } else {\r
+               parameters.remove(Names.odometer);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the odometer data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the odometer data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getOdometer() {\r
+        return (Boolean) parameters.get(Names.odometer);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes belt Status data\r
+        * \r
+        * @param beltStatus\r
+        *            a boolean value\r
+        */\r
+    public void setBeltStatus(Boolean beltStatus) {\r
+        if (beltStatus != null) {\r
+            parameters.put(Names.beltStatus, beltStatus);\r
+        } else {\r
+               parameters.remove(Names.beltStatus);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the belt Status data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the belt Status data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getBeltStatus() {\r
+        return (Boolean) parameters.get(Names.beltStatus);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes body Information data\r
+        * \r
+        * @param bodyInformation\r
+        *            a boolean value\r
+        */\r
+    public void setBodyInformation(Boolean bodyInformation) {\r
+        if (bodyInformation != null) {\r
+            parameters.put(Names.bodyInformation, bodyInformation);\r
+        } else {\r
+               parameters.remove(Names.bodyInformation);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the body Information data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the body Information data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getBodyInformation() {\r
+        return (Boolean) parameters.get(Names.bodyInformation);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes device Status data\r
+        * \r
+        * @param deviceStatus\r
+        *            a boolean value\r
+        */\r
+    public void setDeviceStatus(Boolean deviceStatus) {\r
+        if (deviceStatus != null) {\r
+            parameters.put(Names.deviceStatus, deviceStatus);\r
+        } else {\r
+               parameters.remove(Names.deviceStatus);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the device Status data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the device Status data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getDeviceStatus() {\r
+        return (Boolean) parameters.get(Names.deviceStatus);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes driver Braking data\r
+        * \r
+        * @param driverBraking\r
+        *            a boolean value\r
+        */\r
+    public void setDriverBraking(Boolean driverBraking) {\r
+        if (driverBraking != null) {\r
+            parameters.put(Names.driverBraking, driverBraking);\r
+        } else {\r
+               parameters.remove(Names.driverBraking);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the driver Braking data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the driver Braking data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getDriverBraking() {\r
+        return (Boolean) parameters.get(Names.driverBraking);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes wiper Status data\r
+        * \r
+        * @param wiperStatus\r
+        *            a boolean value\r
+        */\r
+    public void setWiperStatus(Boolean wiperStatus) {\r
+        if (wiperStatus != null) {\r
+            parameters.put(Names.wiperStatus, wiperStatus);\r
+        } else {\r
+               parameters.remove(Names.wiperStatus);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the wiper Status data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the wiper Status data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getWiperStatus() {\r
+        return (Boolean) parameters.get(Names.wiperStatus);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes fuel Economy data\r
+        * \r
+        * @param fuelEconomy\r
+        *            a boolean value\r
+        */\r
+    public void setFuelEconomy(Boolean fuelEconomy) {\r
+        if (fuelEconomy != null) {\r
+            parameters.put(Names.fuelEconomy, fuelEconomy);\r
+        } else {\r
+               parameters.remove(Names.fuelEconomy);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the fuel Economy data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the fuel Economy data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getFuelEconomy() {\r
+        return (Boolean) parameters.get(Names.fuelEconomy);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes Engine Oil Life data\r
+        * \r
+        * @param engineOilLife\r
+        *            a boolean value\r
+        */\r
+    public void setEngineOilLife(Boolean engineOilLife) {\r
+        if (engineOilLife != null) {\r
+            parameters.put(Names.engineOilLife, engineOilLife);\r
+        } else {\r
+               parameters.remove(Names.engineOilLife);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Engine Oil Life data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Engine Oil Life data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getEngineOilLife() {\r
+        return (Boolean) parameters.get(Names.engineOilLife);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes Head Lamp Status data\r
+        * \r
+        * @param headLampStatus\r
+        *            a boolean value\r
+        */\r
+    public void setHeadLampStatus(Boolean headLampStatus) {\r
+        if (headLampStatus != null) {\r
+            parameters.put(Names.headLampStatus, headLampStatus);\r
+        } else {\r
+               parameters.remove(Names.headLampStatus);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Head Lamp Status data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Head Lamp Status data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getHeadLampStatus() {\r
+        return (Boolean) parameters.get(Names.headLampStatus);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes Battery Voltage data\r
+        * \r
+        * @param batteryVoltage\r
+        *            a boolean value\r
+        */\r
+    public void setBatteryVoltage(Boolean batteryVoltage) {\r
+        if (batteryVoltage != null) {\r
+            parameters.put(Names.batteryVoltage, batteryVoltage);\r
+        } else {\r
+               parameters.remove(Names.batteryVoltage);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Battery Voltage data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Battery Voltage data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getBatteryVoltage() {\r
+        return (Boolean) parameters.get(Names.batteryVoltage);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes Brake Torque data\r
+        * \r
+        * @param brakeTorque\r
+        *            a boolean value\r
+        */\r
+    public void setBrakeTorque(Boolean brakeTorque) {\r
+        if (brakeTorque != null) {\r
+            parameters.put(Names.brakeTorque, brakeTorque);\r
+        } else {\r
+               parameters.remove(Names.brakeTorque);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Brake Torque data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Brake Torque data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getBrakeTorque() {\r
+        return (Boolean) parameters.get(Names.brakeTorque);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes Engine Torque data\r
+        * \r
+        * @param engineTorque\r
+        *            a boolean value\r
+        */\r
+    public void setEngineTorque(Boolean engineTorque) {\r
+        if (engineTorque != null) {\r
+            parameters.put(Names.engineTorque, engineTorque);\r
+        } else {\r
+               parameters.remove(Names.engineTorque);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Engine Torque data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Engine Torque data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getEngineTorque() {\r
+        return (Boolean) parameters.get(Names.engineTorque);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes Turbo Boost data\r
+        * \r
+        * @param turboBoost\r
+        *            a boolean value\r
+        */\r
+    public void setTurboBoost(Boolean turboBoost) {\r
+        if (turboBoost != null) {\r
+            parameters.put(Names.turboBoost, turboBoost);\r
+        } else {\r
+               parameters.remove(Names.turboBoost);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Turbo Boost data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Turbo Boost data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getTurboBoost() {\r
+        return (Boolean) parameters.get(Names.turboBoost);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes Coolant Temp data\r
+        * \r
+        * @param coolantTemp\r
+        *            a boolean value\r
+        */\r
+    public void setCoolantTemp(Boolean coolantTemp) {\r
+        if (coolantTemp != null) {\r
+            parameters.put(Names.coolantTemp, coolantTemp);\r
+        } else {\r
+               parameters.remove(Names.coolantTemp);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Coolant Temp data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Coolant Temp data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getCoolantTemp() {\r
+        return (Boolean) parameters.get(Names.coolantTemp);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes Air Fuel Ratio data\r
+        * \r
+        * @param airFuelRatio\r
+        *            a boolean value\r
+        */\r
+    public void setAirFuelRatio(Boolean airFuelRatio) {\r
+        if (airFuelRatio != null) {\r
+            parameters.put(Names.airFuelRatio, airFuelRatio);\r
+        } else {\r
+               parameters.remove(Names.airFuelRatio);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Air Fuel Ratio data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Air Fuel Ratio data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getAirFuelRatio() {\r
+        return (Boolean) parameters.get(Names.airFuelRatio);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes Cooling Head Temp data\r
+        * \r
+        * @param coolingHeadTemp\r
+        *            a boolean value\r
+        */\r
+    public void setCoolingHeadTemp(Boolean coolingHeadTemp) {\r
+        if (coolingHeadTemp != null) {\r
+            parameters.put(Names.coolingHeadTemp, coolingHeadTemp);\r
+        } else {\r
+               parameters.remove(Names.coolingHeadTemp);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Cooling Head Temp data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Cooling Head Temp data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getCoolingHeadTemp() {\r
+        return (Boolean) parameters.get(Names.coolingHeadTemp);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes Cooling Oil Temp data\r
+        * \r
+        * @param oilTemp\r
+        *            a boolean value\r
+        */\r
+    public void setOilTemp(Boolean oilTemp) {\r
+        if (oilTemp != null) {\r
+            parameters.put(Names.oilTemp, oilTemp);\r
+        } else {\r
+               parameters.remove(Names.oilTemp);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Oil Temp data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Oil Temp data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getOilTemp() {\r
+        return (Boolean) parameters.get(Names.oilTemp);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes Intake Air Temp data\r
+        * \r
+        * @param intakeAirTemp\r
+        *            a boolean value\r
+        */\r
+    public void setIntakeAirTemp(Boolean intakeAirTemp) {\r
+        if (intakeAirTemp != null) {\r
+            parameters.put(Names.intakeAirTemp, intakeAirTemp);\r
+        } else {\r
+               parameters.remove(Names.intakeAirTemp);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Intake Air Temp data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Intake Air Temp data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getIntakeAirTemp() {\r
+        return (Boolean) parameters.get(Names.intakeAirTemp);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes Gear Shift Advice data\r
+        * \r
+        * @param gearShiftAdvice\r
+        *            a boolean value\r
+        */\r
+    public void setGearShiftAdvice(Boolean gearShiftAdvice) {\r
+        if (gearShiftAdvice != null) {\r
+            parameters.put(Names.gearShiftAdvice, gearShiftAdvice);\r
+        } else {\r
+               parameters.remove(Names.gearShiftAdvice);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Gear Shift Advice data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Gear Shift Advice data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getGearShiftAdvice() {\r
+        return (Boolean) parameters.get(Names.gearShiftAdvice);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes acceleration data\r
+        * \r
+        * @param acceleration\r
+        *            a boolean value\r
+        */\r
+    public void setAcceleration(Boolean acceleration) {\r
+        if (acceleration != null) {\r
+            parameters.put(Names.acceleration, acceleration);\r
+        } else {\r
+               parameters.remove(Names.acceleration);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the acceleration data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the acceleration data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getAcceleration() {\r
+        return (Boolean) parameters.get(Names.acceleration);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes accPedalPosition data\r
+        * \r
+        * @param accPedalPosition\r
+        *            a boolean value\r
+        */\r
+    public void setAccPedalPosition(Boolean accPedalPosition) {\r
+        if (accPedalPosition != null) {\r
+            parameters.put(Names.accPedalPosition, accPedalPosition);\r
+        } else {\r
+               parameters.remove(Names.accPedalPosition);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the accPedalPosition data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the accPedalPosition data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getAccPedalPosition() {\r
+        return (Boolean) parameters.get(Names.accPedalPosition);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes ClutchPedal Position data\r
+        * \r
+        * @param clutchPedalPosition\r
+        *            a boolean value\r
+        */\r
+    public void setClutchPedalPosition(Boolean clutchPedalPosition) {\r
+        if (clutchPedalPosition != null) {\r
+            parameters.put(Names.clutchPedalPosition, clutchPedalPosition);\r
+        } else {\r
+               parameters.remove(Names.clutchPedalPosition);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the ClutchPedal Position data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the ClutchPedal Position data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getClutchPedalPosition() {\r
+        return (Boolean) parameters.get(Names.clutchPedalPosition);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes Reverse Gear Status data\r
+        * \r
+        * @param reverseGearStatus\r
+        *            a boolean value\r
+        */\r
+    public void setReverseGearStatus(Boolean reverseGearStatus) {\r
+        if (reverseGearStatus != null) {\r
+            parameters.put(Names.reverseGearStatus, reverseGearStatus);\r
+        } else {\r
+               parameters.remove(Names.reverseGearStatus);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Reverse Gear Status data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Reverse Gear Status data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getReverseGearStatus() {\r
+        return (Boolean) parameters.get(Names.reverseGearStatus);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes accTorque data\r
+        * \r
+        * @param accTorque\r
+        *            a boolean value\r
+        */\r
+    public void setAccTorque(Boolean accTorque) {\r
+        if (accTorque != null) {\r
+            parameters.put(Names.accTorque, accTorque);\r
+        } else {\r
+               parameters.remove(Names.accTorque);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the accTorque data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the accTorque data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getAccTorque() {\r
+        return (Boolean) parameters.get(Names.accTorque);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes evInfo data\r
+        * \r
+        * @param evInfo\r
+        *            a boolean value\r
+        */\r
+    public void setEvInfo(Boolean evInfo) {\r
+        if (evInfo != null) {\r
+            parameters.put(Names.evInfo, evInfo);\r
+        } else {\r
+               parameters.remove(Names.evInfo);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the evInfo data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the evInfo data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getEvInfo() {\r
+        return (Boolean) parameters.get(Names.evInfo);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, subscribes Ambient Light Status data\r
+        * \r
+        * @param ambientLightStatus\r
+        *            a boolean value\r
+        */\r
+    public void setAmbientLightStatus(Boolean ambientLightStatus) {\r
+        if (ambientLightStatus != null) {\r
+            parameters.put(Names.ambientLightStatus, ambientLightStatus);\r
+        } else {\r
+               parameters.remove(Names.ambientLightStatus);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Ambient Light Status data has been\r
+        * subscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Ambient Light Status data\r
+        *         has been subscribed.\r
+        */\r
+    public Boolean getAmbientLightStatus() {\r
+        return (Boolean) parameters.get(Names.ambientLightStatus);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SubscribeVehicleDataResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SubscribeVehicleDataResponse.java
new file mode 100755 (executable)
index 0000000..568ef9f
--- /dev/null
@@ -0,0 +1,1018 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Iterator;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.FileType;\r
+import com.smartdevicelink.proxy.rpc.enums.VehicleDataType;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Subscribe Vehicle Data Response is sent, when SubscribeVehicleData has been called\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class SubscribeVehicleDataResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new SubscribeVehicleDataResponse object\r
+        */\r
+    public SubscribeVehicleDataResponse() {\r
+        super("SubscribeVehicleData");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new SubscribeVehicleDataResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public SubscribeVehicleDataResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * Sets gps\r
+     * @param gps\r
+     */\r
+    public void setGps(VehicleDataResult gps) {\r
+        if (gps != null) {\r
+            parameters.put(Names.gps, gps);\r
+        } else {\r
+               parameters.remove(Names.gps);\r
+        }\r
+    }\r
+    /**\r
+     * Gets gps\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getGps() {\r
+       Object obj = parameters.get(Names.gps);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.gps, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets speed\r
+     * @param speed\r
+     */\r
+    public void setSpeed(VehicleDataResult speed) {\r
+        if (speed != null) {\r
+            parameters.put(Names.speed, speed);\r
+        } else {\r
+               parameters.remove(Names.speed);\r
+        }\r
+    }\r
+    /**\r
+     * Gets speed\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getSpeed() {\r
+       Object obj = parameters.get(Names.speed);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.speed, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets rpm\r
+     * @param rpm\r
+     */\r
+    public void setRpm(VehicleDataResult rpm) {\r
+        if (rpm != null) {\r
+            parameters.put(Names.rpm, rpm);\r
+        } else {\r
+               parameters.remove(Names.rpm);\r
+        }\r
+    }\r
+    /**\r
+     * Gets rpm\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getRpm() {\r
+       Object obj = parameters.get(Names.rpm);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.rpm, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Fuel Level\r
+     * @param fuelLevel\r
+     */\r
+    public void setFuelLevel(VehicleDataResult fuelLevel) {\r
+        if (fuelLevel != null) {\r
+            parameters.put(Names.fuelLevel, fuelLevel);\r
+        } else {\r
+               parameters.remove(Names.fuelLevel);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Fuel Level\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getFuelLevel() {\r
+       Object obj = parameters.get(Names.fuelLevel);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.fuelLevel, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Fuel Level State\r
+     * @param fuelLevel_State\r
+     */\r
+    public void setFuelLevel_State(VehicleDataResult fuelLevel_State) {\r
+        if (fuelLevel_State != null) {\r
+            parameters.put(Names.fuelLevel_State, fuelLevel_State);\r
+        } else {\r
+               parameters.remove(Names.fuelLevel_State);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Fuel Level State\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getFuelLevel_State() {\r
+       Object obj = parameters.get(Names.fuelLevel_State);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.fuelLevel_State, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Instant Fuel Comsumption\r
+     * @param instantFuelConsumption\r
+     */\r
+    public void setInstantFuelConsumption(VehicleDataResult instantFuelConsumption) {\r
+        if (instantFuelConsumption != null) {\r
+            parameters.put(Names.instantFuelConsumption, instantFuelConsumption);\r
+        } else {\r
+               parameters.remove(Names.instantFuelConsumption);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Instant Fuel Consumption\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getInstantFuelConsumption() {\r
+       Object obj = parameters.get(Names.instantFuelConsumption);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.instantFuelConsumption, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets External Temperature\r
+     * @param externalTemperature\r
+     */\r
+    public void setExternalTemperature(VehicleDataResult externalTemperature) {\r
+        if (externalTemperature != null) {\r
+            parameters.put(Names.externalTemperature, externalTemperature);\r
+        } else {\r
+               parameters.remove(Names.externalTemperature);\r
+        }\r
+    }\r
+    /**\r
+     * Gets External Temperature\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getExternalTemperature() {\r
+       Object obj = parameters.get(Names.externalTemperature);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.externalTemperature, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets currently selected gear data\r
+     * @param prndl\r
+     */\r
+    public void setPrndl(VehicleDataResult prndl) {\r
+        if (prndl != null) {\r
+            parameters.put(Names.prndl, prndl);\r
+        } else {\r
+               parameters.remove(Names.prndl);\r
+        }\r
+    }\r
+    /**\r
+     * Gets currently selected gear data\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getPrndl() {\r
+       Object obj = parameters.get(Names.prndl);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.prndl, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Tire Pressure\r
+     * @param tirePressure\r
+     */\r
+    public void setTirePressure(VehicleDataResult tirePressure) {\r
+        if (tirePressure != null) {\r
+            parameters.put(Names.tirePressure, tirePressure);\r
+        } else {\r
+               parameters.remove(Names.tirePressure);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Tire Pressure\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getTirePressure() {\r
+       Object obj = parameters.get(Names.tirePressure);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.tirePressure, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Odometer\r
+     * @param odometer\r
+     */\r
+    public void setOdometer(VehicleDataResult odometer) {\r
+        if (odometer != null) {\r
+            parameters.put(Names.odometer, odometer);\r
+        } else {\r
+               parameters.remove(Names.odometer);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Odometer\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getOdometer() {\r
+       Object obj = parameters.get(Names.odometer);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.odometer, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Belt Status\r
+     * @param beltStatus\r
+     */\r
+    public void setBeltStatus(VehicleDataResult beltStatus) {\r
+        if (beltStatus != null) {\r
+            parameters.put(Names.beltStatus, beltStatus);\r
+        } else {\r
+               parameters.remove(Names.beltStatus);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Belt Status\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getBeltStatus() {\r
+       Object obj = parameters.get(Names.beltStatus);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.beltStatus, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Body Information\r
+     * @param bodyInformation\r
+     */\r
+    public void setBodyInformation(VehicleDataResult bodyInformation) {\r
+        if (bodyInformation != null) {\r
+            parameters.put(Names.bodyInformation, bodyInformation);\r
+        } else {\r
+               parameters.remove(Names.bodyInformation);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Body Information\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getBodyInformation() {\r
+       Object obj = parameters.get(Names.bodyInformation);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.bodyInformation, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Device Status\r
+     * @param deviceStatus\r
+     */\r
+    public void setDeviceStatus(VehicleDataResult deviceStatus) {\r
+        if (deviceStatus != null) {\r
+            parameters.put(Names.deviceStatus, deviceStatus);\r
+        } else {\r
+               parameters.remove(Names.deviceStatus);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Device Status\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getDeviceStatus() {\r
+       Object obj = parameters.get(Names.deviceStatus);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.deviceStatus, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Driver Barking\r
+     * @param driverBraking\r
+     */\r
+    public void setDriverBraking(VehicleDataResult driverBraking) {\r
+        if (driverBraking != null) {\r
+            parameters.put(Names.driverBraking, driverBraking);\r
+        } else {\r
+               parameters.remove(Names.driverBraking);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Driver Barking\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getDriverBraking() {\r
+       Object obj = parameters.get(Names.driverBraking);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.driverBraking, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets wiper Status\r
+     * @param wiperStatus\r
+     */\r
+    public void setWiperStatus(VehicleDataResult wiperStatus) {\r
+        if (wiperStatus != null) {\r
+            parameters.put(Names.wiperStatus, wiperStatus);\r
+        } else {\r
+               parameters.remove(Names.wiperStatus);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Wiper Status\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getWiperStatus() {\r
+       Object obj = parameters.get(Names.wiperStatus);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.wiperStatus, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Fuel Economy\r
+     * @param fuelEconomy\r
+     */\r
+    public void setFuelEconomy(VehicleDataResult fuelEconomy) {\r
+        if (fuelEconomy != null) {\r
+            parameters.put(Names.fuelEconomy, fuelEconomy);\r
+        } else {\r
+               parameters.remove(Names.fuelEconomy);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Fuel Economy\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getFuelEconomy() {\r
+       Object obj = parameters.get(Names.fuelEconomy);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.fuelEconomy, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Engine Oil Life\r
+     * @param engineOilLife\r
+     */\r
+    public void setEngineOilLife(VehicleDataResult engineOilLife) {\r
+        if (engineOilLife != null) {\r
+            parameters.put(Names.engineOilLife, engineOilLife);\r
+        } else {\r
+               parameters.remove(Names.engineOilLife);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Engine Oil Lift\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getEngineOilLife() {\r
+       Object obj = parameters.get(Names.engineOilLife);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.engineOilLife, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Head Lamp Status\r
+     * @param headLampStatus\r
+     */\r
+    public void setHeadLampStatus(VehicleDataResult headLampStatus) {\r
+        if (headLampStatus != null) {\r
+            parameters.put(Names.headLampStatus, headLampStatus);\r
+        } else {\r
+               parameters.remove(Names.headLampStatus);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Head Lamp Status\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getHeadLampStatus() {\r
+       Object obj = parameters.get(Names.headLampStatus);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.headLampStatus, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Battery Voltage\r
+     * @param batteryVoltage\r
+     */\r
+    public void setBatteryVoltage(VehicleDataResult batteryVoltage) {\r
+        if (batteryVoltage != null) {\r
+            parameters.put(Names.batteryVoltage, batteryVoltage);\r
+        } else {\r
+               parameters.remove(Names.batteryVoltage);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Battery Voltage\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getBatteryVoltage() {\r
+       Object obj = parameters.get(Names.batteryVoltage);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.batteryVoltage, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Brake Torque\r
+     * @param brakeTorque\r
+     */\r
+    public void setBrakeTorque(VehicleDataResult brakeTorque) {\r
+        if (brakeTorque != null) {\r
+            parameters.put(Names.brakeTorque, brakeTorque);\r
+        } else {\r
+               parameters.remove(Names.brakeTorque);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Brake Torque\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getBrakeTorque() {\r
+       Object obj = parameters.get(Names.brakeTorque);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.brakeTorque, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Engine Torque\r
+     * @param engineTorque\r
+     */\r
+    public void setEngineTorque(VehicleDataResult engineTorque) {\r
+        if (engineTorque != null) {\r
+            parameters.put(Names.engineTorque, engineTorque);\r
+        } else {\r
+               parameters.remove(Names.engineTorque);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Engine Torque\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getEngineTorque() {\r
+       Object obj = parameters.get(Names.engineTorque);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.engineTorque, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Turbo Boost\r
+     * @param turboBoost\r
+     */\r
+    public void setTurboBoost(VehicleDataResult turboBoost) {\r
+        if (turboBoost != null) {\r
+            parameters.put(Names.turboBoost, turboBoost);\r
+        } else {\r
+               parameters.remove(Names.turboBoost);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Turbo Boost\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getTurboBoost() {\r
+       Object obj = parameters.get(Names.turboBoost);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.turboBoost, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Coolant Temp\r
+     * @param coolantTemp\r
+     */\r
+    public void setCoolantTemp(VehicleDataResult coolantTemp) {\r
+        if (coolantTemp != null) {\r
+            parameters.put(Names.coolantTemp, coolantTemp);\r
+        } else {\r
+               parameters.remove(Names.coolantTemp);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Coolant Temp\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getCoolantTemp() {\r
+       Object obj = parameters.get(Names.coolantTemp);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.coolantTemp, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Air Fuel Ratio\r
+     * @param airFuelRatio\r
+     */\r
+    public void setAirFuelRatio(VehicleDataResult airFuelRatio) {\r
+        if (airFuelRatio != null) {\r
+            parameters.put(Names.airFuelRatio, airFuelRatio);\r
+        } else {\r
+               parameters.remove(Names.airFuelRatio);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Air Fuel Ratio\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getAirFuelRatio() {\r
+       Object obj = parameters.get(Names.airFuelRatio);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.airFuelRatio, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Cooling Head Temo\r
+     * @param coolingHeadTemp\r
+     */\r
+    public void setCoolingHeadTemp(VehicleDataResult coolingHeadTemp) {\r
+        if (coolingHeadTemp != null) {\r
+            parameters.put(Names.coolingHeadTemp, coolingHeadTemp);\r
+        } else {\r
+               parameters.remove(Names.coolingHeadTemp);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Cooling Head Temp\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getCoolingHeadTemp() {\r
+       Object obj = parameters.get(Names.coolingHeadTemp);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.coolingHeadTemp, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Oil Temp\r
+     * @param oilTemp\r
+     */\r
+    public void setOilTemp(VehicleDataResult oilTemp) {\r
+        if (oilTemp != null) {\r
+            parameters.put(Names.oilTemp, oilTemp);\r
+        } else {\r
+               parameters.remove(Names.oilTemp);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Oil Temp\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getOilTemp() {\r
+       Object obj = parameters.get(Names.oilTemp);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.oilTemp, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Intake Air Temp\r
+     * @param intakeAirTemp\r
+     */\r
+    public void setIntakeAirTemp(VehicleDataResult intakeAirTemp) {\r
+        if (intakeAirTemp != null) {\r
+            parameters.put(Names.intakeAirTemp, intakeAirTemp);\r
+        } else {\r
+               parameters.remove(Names.intakeAirTemp);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Intake Air Temp\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getIntakeAirTemp() {\r
+       Object obj = parameters.get(Names.intakeAirTemp);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.intakeAirTemp, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Gear Shift Advice\r
+     * @param gearShiftAdvice\r
+     */\r
+    public void setGearShiftAdvice(VehicleDataResult gearShiftAdvice) {\r
+        if (gearShiftAdvice != null) {\r
+            parameters.put(Names.gearShiftAdvice, gearShiftAdvice);\r
+        } else {\r
+               parameters.remove(Names.gearShiftAdvice);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Gear Shift Advice\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getGearShiftAdvice() {\r
+       Object obj = parameters.get(Names.gearShiftAdvice);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.gearShiftAdvice, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Acceleration\r
+     * @param acceleration\r
+     */\r
+    public void setAcceleration(VehicleDataResult acceleration) {\r
+        if (acceleration != null) {\r
+            parameters.put(Names.acceleration, acceleration);\r
+        } else {\r
+               parameters.remove(Names.acceleration);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Acceleration\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getAcceleration() {\r
+       Object obj = parameters.get(Names.acceleration);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.acceleration, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets AccPedal Position\r
+     * @param accPedalPosition\r
+     */\r
+    public void setAccPedalPosition(VehicleDataResult accPedalPosition) {\r
+        if (accPedalPosition != null) {\r
+            parameters.put(Names.accPedalPosition, accPedalPosition);\r
+        } else {\r
+               parameters.remove(Names.accPedalPosition);\r
+        }\r
+    }\r
+    /**\r
+     * Gets AccPedal Position\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getAccPedalPosition() {\r
+       Object obj = parameters.get(Names.accPedalPosition);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.accPedalPosition, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets ClutchPedal Position\r
+     * @param clutchPedalPosition\r
+     */\r
+    public void setClutchPedalPosition(VehicleDataResult clutchPedalPosition) {\r
+        if (clutchPedalPosition != null) {\r
+            parameters.put(Names.clutchPedalPosition, clutchPedalPosition);\r
+        } else {\r
+               parameters.remove(Names.clutchPedalPosition);\r
+        }\r
+    }\r
+    /**\r
+     * Gets ClutchPedal Position\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getClutchPedalPosition() {\r
+       Object obj = parameters.get(Names.clutchPedalPosition);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.clutchPedalPosition, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Reverse Gear Status\r
+     * @param reverseGearStatus\r
+     */\r
+    public void setReverseGearStatus(VehicleDataResult reverseGearStatus) {\r
+        if (reverseGearStatus != null) {\r
+            parameters.put(Names.reverseGearStatus, reverseGearStatus);\r
+        } else {\r
+               parameters.remove(Names.reverseGearStatus);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Reverse Gear Status\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getReverseGearStatus() {\r
+       Object obj = parameters.get(Names.reverseGearStatus);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.reverseGearStatus, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets AccTorque\r
+     * @param accTorque\r
+     */\r
+    public void setAccTorque(VehicleDataResult accTorque) {\r
+        if (accTorque != null) {\r
+            parameters.put(Names.accTorque, accTorque);\r
+        } else {\r
+               parameters.remove(Names.accTorque);\r
+        }\r
+    }\r
+    /**\r
+     * Gets AccTorque\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getAccTorque() {\r
+       Object obj = parameters.get(Names.accTorque);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.accTorque, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets EvInfo\r
+     * @param evInfo\r
+     */\r
+    public void setEvInfo(VehicleDataResult evInfo) {\r
+        if (evInfo != null) {\r
+            parameters.put(Names.evInfo, evInfo);\r
+        } else {\r
+               parameters.remove(Names.evInfo);\r
+        }\r
+    }\r
+    /**\r
+     * Gets EvInfo\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getEvInfo() {\r
+       Object obj = parameters.get(Names.evInfo);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.evInfo, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Ambient Light Status\r
+     * @param ambientLightStatus\r
+     */\r
+    public void setAmbientLightStatus(VehicleDataResult ambientLightStatus) {\r
+        if (ambientLightStatus != null) {\r
+            parameters.put(Names.ambientLightStatus, ambientLightStatus);\r
+        } else {\r
+               parameters.remove(Names.ambientLightStatus);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Ambient Light Status\r
+     * @return VehicleDataResult \r
+     */\r
+    public VehicleDataResult getAmbientLightStatus() {\r
+       Object obj = parameters.get(Names.ambientLightStatus);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.ambientLightStatus, e);\r
+            }\r
+        }\r
+        return null;\r
+    }   \r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SyncMsgVersion.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SyncMsgVersion.java
deleted file mode 100755 (executable)
index 8d6cbde..0000000
+++ /dev/null
@@ -1,33 +0,0 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCStruct;
-import com.smartdevicelink.proxy.constants.Names;
-
-public class SyncMsgVersion extends RPCStruct {
-
-    public SyncMsgVersion() { }
-    public SyncMsgVersion(Hashtable hash) {
-        super(hash);
-    }
-    public Integer getMajorVersion() {
-        return (Integer) store.get( Names.majorVersion );
-    }
-    public void setMajorVersion( Integer majorVersion ) {
-        if (majorVersion != null) {
-            store.put(Names.majorVersion, majorVersion );
-        }
-    }
-    public Integer getMinorVersion() {
-        return (Integer) store.get( Names.minorVersion );
-    }
-    public void setMinorVersion( Integer minorVersion ) {
-        if (minorVersion != null) {
-            store.put(Names.minorVersion, minorVersion );
-        }
-    }
-}
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SyncPData.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SyncPData.java
new file mode 100755 (executable)
index 0000000..d14cd4b
--- /dev/null
@@ -0,0 +1,25 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+public class SyncPData extends RPCRequest {\r
+       public SyncPData() {\r
+        super("SyncPData");\r
+    }\r
+    public SyncPData(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public void setSyncPData(byte[] syncPData) {\r
+        if (syncPData != null) {\r
+            parameters.put(Names.bulkData, syncPData);\r
+        } else {\r
+               parameters.remove(Names.bulkData);\r
+        }\r
+    }\r
+    public byte[] getSyncPData() {\r
+        return (byte[]) parameters.get(Names.bulkData);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SyncPDataResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/SyncPDataResponse.java
new file mode 100755 (executable)
index 0000000..132583f
--- /dev/null
@@ -0,0 +1,14 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+public class SyncPDataResponse  extends RPCResponse {\r
+       public SyncPDataResponse() {\r
+        super("SyncPDataResponse");\r
+    }\r
+    public SyncPDataResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
index c46919d..a547420 100755 (executable)
@@ -1,47 +1,98 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCStruct;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.SpeechCapabilities;
-import com.smartdevicelink.util.DebugTool;
-
-public class TTSChunk extends RPCStruct {
-
-    public TTSChunk() { }
-    public TTSChunk(Hashtable hash) {
-        super(hash);
-    }
-    public String getText() {
-        return (String) store.get( Names.text );
-    }
-    public void setText( String text ) {
-        if (text != null) {
-            store.put(Names.text, text );
-        }
-    }
-    public SpeechCapabilities getType() {
-        Object obj = store.get(Names.type);
-        if (obj instanceof SpeechCapabilities) {
-            return (SpeechCapabilities) obj;
-        } else if (obj instanceof String) {
-            SpeechCapabilities theCode = null;
-            try {
-                theCode = SpeechCapabilities.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.type, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setType( SpeechCapabilities type ) {
-        if (type != null) {
-            store.put(Names.type, type );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.SpeechCapabilities;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Specifies what is to be spoken. This can be simply a text phrase, which SMARTDEVICELINK will speak according to its own rules.\r
+ *  It can also be phonemes from either the Microsoft SAPI phoneme set, or from the LHPLUS phoneme set. \r
+ *  It can also be a pre-recorded sound in WAV format (either developer-defined, or provided by the SMARTDEVICELINK platform).\r
+ *  \r
+ *  <p>In SMARTDEVICELINK, words, and therefore sentences, can be built up from phonemes and are used to explicitly provide the proper pronounciation to the TTS engine.\r
+ *   For example, to have SMARTDEVICELINK pronounce the word "read" as "red", rather than as when it is pronounced like "reed",\r
+ *   the developer would use phonemes to express this desired pronounciation.\r
+ *  <p>For more information about phonemes, see <a href="http://en.wikipedia.org/wiki/Phoneme">http://en.wikipedia.org/wiki/Phoneme</a>.\r
+ *  <p><b> Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>text</td>\r
+ *                     <td>String</td>\r
+ *                     <td>Text to be spoken, or a phoneme specification, or the name of a pre-recorded sound. The contents of this field are indicated by the "type" field.</td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>type</td>\r
+ *                     <td>SpeechCapabilities</td>\r
+ *                     <td>Indicates the type of information in the "text" field (e.g. phrase to be spoken, phoneme specification, name of pre-recorded sound).        </td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ *  </table>\r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class TTSChunk extends RPCStruct {\r
+       /**\r
+        * Constructs a newly allocated TTSChunk object\r
+        */\r
+    public TTSChunk() { }\r
+    /**\r
+     * Constructs a newly allocated TTSChunk object indicated by the Hashtable parameter\r
+     * @param hash The Hashtable to use\r
+     */    \r
+    public TTSChunk(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * Get text to be spoken, or a phoneme specification, or the name of a pre-recorded sound. The contents of this field are indicated by the "type" field.\r
+     * @return text to be spoken, or a phoneme specification, or the name of a pre-recorded sound\r
+     */    \r
+    public String getText() {\r
+        return (String) store.get( Names.text );\r
+    }\r
+    /**\r
+     * Set the text to be spoken, or a phoneme specification, or the name of a pre-recorded sound. The contents of this field are indicated by the "type" field.\r
+     * @param text to be spoken, or a phoneme specification, or the name of a pre-recorded sound.\r
+     */    \r
+    public void setText( String text ) {\r
+        if (text != null) {\r
+            store.put(Names.text, text );\r
+        }\r
+    }\r
+    /**\r
+     * Get the type of information in the "text" field (e.g. phrase to be spoken, phoneme specification, name of pre-recorded sound).  \r
+     * @return the type of information in the "text" field\r
+     */    \r
+    public SpeechCapabilities getType() {\r
+        Object obj = store.get(Names.type);\r
+        if (obj instanceof SpeechCapabilities) {\r
+            return (SpeechCapabilities) obj;\r
+        } else if (obj instanceof String) {\r
+            SpeechCapabilities theCode = null;\r
+            try {\r
+                theCode = SpeechCapabilities.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.type, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Set the type of information in the "text" field (e.g. phrase to be spoken, phoneme specification, name of pre-recorded sound).  \r
+     * @param type the type of information in the "text" field\r
+     */    \r
+    public void setType( SpeechCapabilities type ) {\r
+        if (type != null) {\r
+            store.put(Names.type, type );\r
+        }\r
+    }\r
+}\r
index 33a5c40..6802081 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCStruct;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.CharacterSet;
-import com.smartdevicelink.proxy.rpc.enums.TextFieldName;
-import com.smartdevicelink.util.DebugTool;
-
-public class TextField extends RPCStruct {
-
-    public TextField() { }
-    public TextField(Hashtable hash) {
-        super(hash);
-    }
-    public TextFieldName getName() {
-        Object obj = store.get(Names.name);
-        if (obj instanceof TextFieldName) {
-            return (TextFieldName) obj;
-        } else if (obj instanceof String) {
-            TextFieldName theCode = null;
-            try {
-                theCode = TextFieldName.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.name, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setName( TextFieldName name ) {
-        if (name != null) {
-            store.put(Names.name, name );
-        }
-    }
-    public CharacterSet getCharacterSet() {
-        Object obj = store.get(Names.characterSet);
-        if (obj instanceof CharacterSet) {
-            return (CharacterSet) obj;
-        } else if (obj instanceof String) {
-            CharacterSet theCode = null;
-            try {
-                theCode = CharacterSet.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.characterSet, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setCharacterSet( CharacterSet characterSet ) {
-        if (characterSet != null) {
-            store.put(Names.characterSet, characterSet );
-        }
-    }
-    public Integer getWidth() {
-        return (Integer) store.get( Names.width );
-    }
-    public void setWidth( Integer width ) {
-        if (width != null) {
-            store.put(Names.width, width );
-        }
-    }
-    public Integer getRows() {
-        return (Integer) store.get( Names.rows );
-    }
-    public void setRows( Integer rows ) {
-        if (rows != null) {
-            store.put(Names.rows, rows );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.CharacterSet;\r
+import com.smartdevicelink.proxy.rpc.enums.TextFieldName;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Struct defining the characteristics of a displayed field on the HMI.\r
+ * <p><b> Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>name</td>\r
+ *                     <td>TextFieldName</td>\r
+ *                     <td>Enumeration identifying the field.  </td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>characterSet</td>\r
+ *                     <td>CharacterSet</td>\r
+ *                     <td>The character set that is supported in this field.  </td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>width</td>\r
+ *                     <td>Int16</td>\r
+ *                     <td>The number of characters in one row of this field.\r
+ *                                     <ul>\r
+ *                                     <li>Minvalue="1"</li>\r
+ *                                     <li>maxvalue="500"</li>\r
+ *                                     </ul>\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>rows</td>\r
+ *                     <td>Int16</td>\r
+ *                     <td>The number of rows for this text field.\r
+ *                                     <ul>\r
+ *                                     <li>Minvalue="1"</li>\r
+ *                                     <li>maxvalue="3"</li>\r
+ *                                     </ul>\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ *  </table>\r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class TextField extends RPCStruct {\r
+       /**\r
+        * Constructs a newly allocated TextField object\r
+        */\r
+    public TextField() { }\r
+    /**\r
+     * Constructs a newly allocated TextField object indicated by the Hashtable parameter\r
+     * @param hash The Hashtable to use\r
+     */    \r
+    public TextField(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * Get the enumeration identifying the field.      \r
+     * @return the name of TextField\r
+     */    \r
+    public TextFieldName getName() {\r
+        Object obj = store.get(Names.name);\r
+        if (obj instanceof TextFieldName) {\r
+            return (TextFieldName) obj;\r
+        } else if (obj instanceof String) {\r
+            TextFieldName theCode = null;\r
+            try {\r
+                theCode = TextFieldName.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.name, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Set the enumeration identifying the field.      \r
+     * @param name the name of TextField\r
+     */    \r
+    public void setName( TextFieldName name ) {\r
+        if (name != null) {\r
+            store.put(Names.name, name );\r
+        }\r
+    }\r
+    /**\r
+     * Get the character set that is supported in this field.\r
+     * @return the character set\r
+     */    \r
+    public CharacterSet getCharacterSet() {\r
+        Object obj = store.get(Names.characterSet);\r
+        if (obj instanceof CharacterSet) {\r
+            return (CharacterSet) obj;\r
+        } else if (obj instanceof String) {\r
+            CharacterSet theCode = null;\r
+            try {\r
+                theCode = CharacterSet.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.characterSet, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Set the character set that is supported in this field.\r
+     * @param characterSet - the character set\r
+     */    \r
+    public void setCharacterSet( CharacterSet characterSet ) {\r
+        if (characterSet != null) {\r
+            store.put(Names.characterSet, characterSet );\r
+        }\r
+    }\r
+    /**\r
+     * Get the number of characters in one row of this field.\r
+     *                                         <ul>\r
+     *                                 <li>Minvalue="1"</li>\r
+     *                                 <li>maxvalue="500"</li>\r
+     *                                 </ul>\r
+     * @return the number of characters in one row of this field\r
+     */    \r
+    public Integer getWidth() {\r
+        return (Integer) store.get( Names.width );\r
+    }\r
+    /**\r
+     * Set the number of characters in one row of this field.\r
+     *                                         <ul>\r
+     *                                 <li>Minvalue="1"</li>\r
+     *                                 <li>maxvalue="500"</li>\r
+     *                                 </ul>\r
+     * @param width  the number of characters in one row of this field\r
+     */    \r
+    public void setWidth( Integer width ) {\r
+        if (width != null) {\r
+            store.put(Names.width, width );\r
+        }\r
+    }\r
+    /**\r
+     *Get the number of rows for this text field.\r
+     *                                         <ul>\r
+     *                                 <li>Minvalue="1"</li>\r
+     *                                 <li>maxvalue="3"</li>\r
+     *                                 </ul>\r
+     * @return  the number of rows for this text field\r
+     */    \r
+    public Integer getRows() {\r
+        return (Integer) store.get( Names.rows );\r
+    }\r
+    public void setRows( Integer rows ) {\r
+        if (rows != null) {\r
+            store.put(Names.rows, rows );\r
+        }\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/TireStatus.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/TireStatus.java
new file mode 100755 (executable)
index 0000000..52ebdaf
--- /dev/null
@@ -0,0 +1,159 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.TirePressureTellTale;\r
+import com.smartdevicelink.proxy.rpc.enums.WarningLightStatus;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+public class TireStatus extends RPCStruct {\r
+\r
+    public TireStatus() { }\r
+    public TireStatus(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public void setPressureTellTale(WarningLightStatus pressureTellTale) {\r
+       if (pressureTellTale != null) {\r
+               store.put(Names.pressureTellTale, pressureTellTale);\r
+       } else {\r
+               store.remove(Names.pressureTellTale);\r
+       }\r
+    }\r
+    public WarningLightStatus getPressureTellTale() {\r
+        Object obj = store.get(Names.pressureTellTale);\r
+        if (obj instanceof WarningLightStatus) {\r
+            return (WarningLightStatus) obj;\r
+        } else if (obj instanceof String) {\r
+               WarningLightStatus theCode = null;\r
+            try {\r
+                theCode = WarningLightStatus.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.pressureTellTale, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setLeftFront(SingleTireStatus leftFront) {\r
+       if (leftFront != null) {\r
+               store.put(Names.leftFront, leftFront);\r
+       } else {\r
+               store.remove(Names.leftFront);\r
+       }\r
+    }\r
+    public SingleTireStatus getLeftFront() {\r
+       Object obj = store.get(Names.leftFront);\r
+        if (obj instanceof SingleTireStatus) {\r
+            return (SingleTireStatus) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new SingleTireStatus((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.leftFront, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setRightFront(SingleTireStatus rightFront) {\r
+       if (rightFront != null) {\r
+               store.put(Names.rightFront, rightFront);\r
+       } else {\r
+               store.remove(Names.rightFront);\r
+       }\r
+    }\r
+    public SingleTireStatus getRightFront() {\r
+       Object obj = store.get(Names.rightFront);\r
+        if (obj instanceof SingleTireStatus) {\r
+            return (SingleTireStatus) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new SingleTireStatus((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.rightFront, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setLeftRear(SingleTireStatus leftRear) {\r
+       if (leftRear != null) {\r
+               store.put(Names.leftRear, leftRear);\r
+       } else {\r
+               store.remove(Names.leftRear);\r
+       }\r
+    }\r
+    public SingleTireStatus getLeftRear() {\r
+       Object obj = store.get(Names.leftRear);\r
+        if (obj instanceof SingleTireStatus) {\r
+            return (SingleTireStatus) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new SingleTireStatus((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.leftRear, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setRightRear(SingleTireStatus rightRear) {\r
+       if (rightRear != null) {\r
+               store.put(Names.rightRear, rightRear);\r
+       } else {\r
+               store.remove(Names.rightRear);\r
+       }\r
+    }\r
+    public SingleTireStatus getRightRear() {\r
+       Object obj = store.get(Names.rightRear);\r
+        if (obj instanceof SingleTireStatus) {\r
+            return (SingleTireStatus) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new SingleTireStatus((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.rightRear, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setInnerLeftRear(SingleTireStatus innerLeftRear) {\r
+       if (innerLeftRear != null) {\r
+               store.put(Names.innerLeftRear, innerLeftRear);\r
+       } else {\r
+               store.remove(Names.innerLeftRear);\r
+       }\r
+    }\r
+    public SingleTireStatus getInnerLeftRear() {\r
+       Object obj = store.get(Names.innerLeftRear);\r
+        if (obj instanceof SingleTireStatus) {\r
+            return (SingleTireStatus) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new SingleTireStatus((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.innerLeftRear, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setInnerRightRear(SingleTireStatus innerRightRear) {\r
+       if (innerRightRear != null) {\r
+               store.put(Names.innerRightRear, innerRightRear);\r
+       } else {\r
+               store.remove(Names.innerRightRear);\r
+       }\r
+    }\r
+    public SingleTireStatus getInnerRightRear() {\r
+       Object obj = store.get(Names.innerRightRear);\r
+        if (obj instanceof SingleTireStatus) {\r
+            return (SingleTireStatus) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new SingleTireStatus((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.innerRightRear, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/Turn.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/Turn.java
new file mode 100755 (executable)
index 0000000..a4ec2dc
--- /dev/null
@@ -0,0 +1,97 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Describes a navigation turn including an optional icon\r
+ * <p><b>Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>navigationText</td>\r
+ *                     <td>String</td>\r
+ *                     <td>Text to describe the turn (e.g. streetname)\r
+ *                              <ul>\r
+ *                                     <li>Maxlength = 500</li>\r
+ *                              </ul> \r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>turnIcon</td>\r
+ *                     <td>Image</td>\r
+ *                     <td>Image to be shown for a turn\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *  </table>\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class Turn extends RPCStruct {\r
+\r
+       /**\r
+        * Constructs a newly allocated Turn object\r
+        */\r
+       public Turn() { }\r
+       \r
+       /**\r
+        * Constructs a newly allocated Turn object indicated by the Hashtable parameter\r
+        * @param hash The Hashtable to use\r
+        */\r
+    public Turn(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    \r
+    /**\r
+     * set the text to describe the turn (e.g. streetname)\r
+     * @param navigationText the text to describe the turn (e.g. streetname)\r
+     */\r
+    public void setNavigationText(String navigationText) {\r
+        if (navigationText != null) {\r
+            store.put(Names.navigationText, navigationText);\r
+        } else {\r
+               store.remove(Names.navigationText);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get the text to describe the turn (e.g. streetname)\r
+     * @return the text to describe the turn (e.g. streetname)\r
+     */\r
+    public String getNavigationText() {\r
+        return (String) store.get(Names.navigationText);\r
+    }\r
+    \r
+    /**\r
+     * set Image to be shown for a turn\r
+     * @param turnIcon the image to be shown for a turn\r
+     */\r
+    public void setTurnIcon(Image turnIcon) {\r
+        if (turnIcon != null) {\r
+               store.put(Names.turnIcon, turnIcon);\r
+        } else {\r
+               store.remove(Names.turnIcon);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get the image to be shown for a turn\r
+     * @return the image to be shown for a turn\r
+     */\r
+    public Image getTurnIcon() {\r
+       Object obj = store.get(Names.turnIcon);\r
+        if (obj instanceof Image) {\r
+            return (Image) obj;\r
+        } else {\r
+               return new Image((Hashtable) obj);\r
+        }\r
+    }\r
+}\r
index b309426..20665f2 100755 (executable)
@@ -1,18 +1,41 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCRequest;
-
-public class UnregisterAppInterface extends RPCRequest {
-
-    public UnregisterAppInterface() {
-        super("UnregisterAppInterface");
-    }
-    public UnregisterAppInterface(Hashtable hash) {
-        super(hash);
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+\r
+/**\r
+ * Terminates an application's interface registration. This causes SMARTDEVICELINK&reg; to\r
+ * dispose of all resources associated with the application's interface\r
+ * registration (e.g. Command Menu items, Choice Sets, button subscriptions,\r
+ * etc.)\r
+ * <p>\r
+ * After the UnregisterAppInterface operation is performed, no other operations\r
+ * can be performed until a new app interface registration is established by\r
+ * calling <i>{@linkplain RegisterAppInterface}</i>\r
+ * <p>\r
+ * <b>HMILevel can be FULL, LIMITED, BACKGROUND or NONE</b>\r
+ * </p>\r
+ * \r
+ * @see RegisterAppInterface\r
+ * @see OnAppInterfaceUnregistered\r
+ */\r
+public class UnregisterAppInterface extends RPCRequest {\r
+       /**\r
+        * Constructs a new UnregisterAppInterface object\r
+        */\r
+    public UnregisterAppInterface() {\r
+        super("UnregisterAppInterface");\r
+    }\r
+       /**\r
+        * Constructs a new UnregisterAppInterface object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */    \r
+    public UnregisterAppInterface(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
index 599ef2f..7b0c3bf 100755 (executable)
@@ -1,18 +1,32 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCResponse;
-
-public class UnregisterAppInterfaceResponse extends RPCResponse {
-
-    public UnregisterAppInterfaceResponse() {
-        super("UnregisterAppInterface");
-    }
-    public UnregisterAppInterfaceResponse(Hashtable hash) {
-        super(hash);
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Unregister AppInterface Response is sent, when UnregisterAppInterface has been called\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class UnregisterAppInterfaceResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new UnregisterAppInterfaceResponse object\r
+        */\r
+    public UnregisterAppInterfaceResponse() {\r
+        super("UnregisterAppInterface");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new UnregisterAppInterfaceResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public UnregisterAppInterfaceResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
index 02787ad..93600bf 100755 (executable)
@@ -1,41 +1,75 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCRequest;
-import com.smartdevicelink.proxy.constants.Names;
-import com.smartdevicelink.proxy.rpc.enums.ButtonName;
-import com.smartdevicelink.util.DebugTool;
-
-public class UnsubscribeButton extends RPCRequest {
-
-    public UnsubscribeButton() {
-        super("UnsubscribeButton");
-    }
-    public UnsubscribeButton(Hashtable hash) {
-        super(hash);
-    }
-    public ButtonName getButtonName() {
-        Object obj = parameters.get(Names.buttonName);
-        if (obj instanceof ButtonName) {
-            return (ButtonName) obj;
-        } else if (obj instanceof String) {
-            ButtonName theCode = null;
-            try {
-                theCode = ButtonName.valueForString((String) obj);
-            } catch (Exception e) {
-               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.buttonName, e);
-            }
-            return theCode;
-        }
-        return null;
-    }
-    public void setButtonName( ButtonName buttonName ) {
-        if (buttonName != null) {
-            parameters.put(Names.buttonName, buttonName );
-        }
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.ButtonName;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Deletes a subscription to button notifications for the specified button. For\r
+ * more information about button subscriptions, see {@linkplain SubscribeButton}\r
+ * <p>\r
+ * Application can unsubscribe from a button that is currently being pressed\r
+ * (i.e. has not yet been released), but app will not get button event\r
+ * <p>\r
+ * <b>HMILevel needs to be FULL, LIMITED or BACKGROUND</b>\r
+ * <p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ * @see SubscribeButton\r
+ */\r
+public class UnsubscribeButton extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new UnsubscribeButton object\r
+        */    \r
+       public UnsubscribeButton() {\r
+        super("UnsubscribeButton");\r
+    }\r
+       /**\r
+        * Constructs a new UnsubscribeButton object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */     \r
+    public UnsubscribeButton(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+       /**\r
+        * Gets a name of the button to unsubscribe from\r
+        * \r
+        * @return ButtonName -an Enumeration value, see <i>\r
+        *         {@linkplain com.smartdevicelink.proxy.rpc.enums.ButtonName}</i>\r
+        */    \r
+    public ButtonName getButtonName() {\r
+        Object obj = parameters.get(Names.buttonName);\r
+        if (obj instanceof ButtonName) {\r
+            return (ButtonName) obj;\r
+        } else if (obj instanceof String) {\r
+            ButtonName theCode = null;\r
+            try {\r
+                theCode = ButtonName.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.buttonName, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+       /**\r
+        * Sets the name of the button to unsubscribe from\r
+        * \r
+        * @param buttonName\r
+        *            an enum value, see <i>\r
+        *            {@linkplain com.smartdevicelink.proxy.rpc.enums.ButtonName}</i>\r
+        */    \r
+    public void setButtonName( ButtonName buttonName ) {\r
+        if (buttonName != null) {\r
+            parameters.put(Names.buttonName, buttonName );\r
+        }\r
+    }\r
+}\r
index e5d7907..e884055 100755 (executable)
@@ -1,18 +1,32 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc;
-
-import java.util.Hashtable;
-
-import com.smartdevicelink.proxy.RPCResponse;
-
-public class UnsubscribeButtonResponse extends RPCResponse {
-
-    public UnsubscribeButtonResponse() {
-        super("UnsubscribeButton");
-    }
-    public UnsubscribeButtonResponse(Hashtable hash) {
-        super(hash);
-    }
-}
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Unsubscribe Button Response is sent, when UnsubscribeButton has been called\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class UnsubscribeButtonResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new UnsubscribeButtonResponse object\r
+        */\r
+    public UnsubscribeButtonResponse() {\r
+        super("UnsubscribeButton");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new UnsubscribeButtonResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public UnsubscribeButtonResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/UnsubscribeVehicleData.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/UnsubscribeVehicleData.java
new file mode 100755 (executable)
index 0000000..441d0e5
--- /dev/null
@@ -0,0 +1,916 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.VehicleDataType;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * This function is used to unsubscribe the notifications from the\r
+ * subscribeVehicleData function\r
+ * <p>\r
+ * Function Group: Location, VehicleInfo and DrivingChara\r
+ * <p>\r
+ * <b>HMILevel needs to be FULL, LIMITED or BACKGROUND</b>\r
+ * </p>\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ * @see SubscribeVehicleData\r
+ * @see GetVehicleData\r
+ */\r
+public class UnsubscribeVehicleData extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new UnsubscribeVehicleData object\r
+        */\r
+    public UnsubscribeVehicleData() {\r
+        super("UnsubscribeVehicleData");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new UnsubscribeVehicleData object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public UnsubscribeVehicleData(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes Gps data\r
+        * \r
+        * @param gps\r
+        *            a boolean value\r
+        */\r
+    public void setGps(Boolean gps) {\r
+        if (gps != null) {\r
+            parameters.put(Names.gps, gps);\r
+        } else {\r
+               parameters.remove(Names.gps);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Gps data has been unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Gps data has been\r
+        *         unsubscribed.\r
+        */\r
+    public Boolean getGps() {\r
+        return (Boolean) parameters.get(Names.gps);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes speed data\r
+        * \r
+        * @param speed\r
+        *            a boolean value\r
+        */\r
+    public void setSpeed(Boolean speed) {\r
+        if (speed != null) {\r
+            parameters.put(Names.speed, speed);\r
+        } else {\r
+               parameters.remove(Names.speed);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Speed data has been unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Speed data has been\r
+        *         unsubscribed.\r
+        */\r
+    public Boolean getSpeed() {\r
+        return (Boolean) parameters.get(Names.speed);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribe data\r
+        * \r
+        * @param rpm\r
+        *            a boolean value\r
+        */\r
+    public void setRpm(Boolean rpm) {\r
+        if (rpm != null) {\r
+            parameters.put(Names.rpm, rpm);\r
+        } else {\r
+               parameters.remove(Names.rpm);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the rpm data has been unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the rpm data has been\r
+        *         unsubscribed.\r
+        */\r
+    public Boolean getRpm() {\r
+        return (Boolean) parameters.get(Names.rpm);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes FuelLevel data\r
+        * \r
+        * @param fuelLevel\r
+        *            a boolean value\r
+        */\r
+    public void setFuelLevel(Boolean fuelLevel) {\r
+        if (fuelLevel != null) {\r
+            parameters.put(Names.fuelLevel, fuelLevel);\r
+        } else {\r
+               parameters.remove(Names.fuelLevel);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the FuelLevel data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the FuelLevel data has\r
+        *         been unsubscribed.\r
+        */\r
+    public Boolean getFuelLevel() {\r
+        return (Boolean) parameters.get(Names.fuelLevel);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes fuelLevel_State data\r
+        * \r
+        * @param fuelLevel_State\r
+        *            a boolean value\r
+        */\r
+    public void setFuelLevel_State(Boolean fuelLevel_State) {\r
+        if (fuelLevel_State != null) {\r
+            parameters.put(Names.fuelLevel_State, fuelLevel_State);\r
+        } else {\r
+               parameters.remove(Names.fuelLevel_State);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the fuelLevel_State data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the fuelLevel_State data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getFuelLevel_State() {\r
+        return (Boolean) parameters.get(Names.fuelLevel_State);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes instantFuelConsumption data\r
+        * \r
+        * @param instantFuelConsumption\r
+        *            a boolean value\r
+        */\r
+    public void setInstantFuelConsumption(Boolean instantFuelConsumption) {\r
+        if (instantFuelConsumption != null) {\r
+            parameters.put(Names.instantFuelConsumption, instantFuelConsumption);\r
+        } else {\r
+               parameters.remove(Names.instantFuelConsumption);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the getInstantFuelConsumption data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the getInstantFuelConsumption data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getInstantFuelConsumption() {\r
+        return (Boolean) parameters.get(Names.instantFuelConsumption);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes externalTemperature data\r
+        * \r
+        * @param externalTemperature\r
+        *            a boolean value\r
+        */\r
+    public void setExternalTemperature(Boolean externalTemperature) {\r
+        if (externalTemperature != null) {\r
+            parameters.put(Names.externalTemperature, externalTemperature);\r
+        } else {\r
+               parameters.remove(Names.externalTemperature);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the externalTemperature data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the externalTemperature data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getExternalTemperature() {\r
+        return (Boolean) parameters.get(Names.externalTemperature);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes Currently selected gear data\r
+        * \r
+        * @param prndl\r
+        *            a boolean value\r
+        */\r
+    public void setPrndl(Boolean prndl) {\r
+        if (prndl != null) {\r
+            parameters.put(Names.prndl, prndl);\r
+        } else {\r
+               parameters.remove(Names.prndl);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Currently selected gear data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Currently selected gear data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getPrndl() {\r
+        return (Boolean) parameters.get(Names.prndl);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes tire pressure status data\r
+        * \r
+        * @param tirePressure\r
+        *            a boolean value\r
+        */\r
+    public void setTirePressure(Boolean tirePressure) {\r
+        if (tirePressure != null) {\r
+            parameters.put(Names.tirePressure, tirePressure);\r
+        } else {\r
+               parameters.remove(Names.tirePressure);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the tire pressure status data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the tire pressure status data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getTirePressure() {\r
+        return (Boolean) parameters.get(Names.tirePressure);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes odometer data\r
+        * \r
+        * @param odometer\r
+        *            a boolean value\r
+        */\r
+    public void setOdometer(Boolean odometer) {\r
+        if (odometer != null) {\r
+            parameters.put(Names.odometer, odometer);\r
+        } else {\r
+               parameters.remove(Names.odometer);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the odometer data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the odometer data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getOdometer() {\r
+        return (Boolean) parameters.get(Names.odometer);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes belt Status data\r
+        * \r
+        * @param beltStatus\r
+        *            a boolean value\r
+        */\r
+    public void setBeltStatus(Boolean beltStatus) {\r
+        if (beltStatus != null) {\r
+            parameters.put(Names.beltStatus, beltStatus);\r
+        } else {\r
+               parameters.remove(Names.beltStatus);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the belt Status data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the belt Status data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getBeltStatus() {\r
+        return (Boolean) parameters.get(Names.beltStatus);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes body Information data\r
+        * \r
+        * @param bodyInformation\r
+        *            a boolean value\r
+        */\r
+    public void setBodyInformation(Boolean bodyInformation) {\r
+        if (bodyInformation != null) {\r
+            parameters.put(Names.bodyInformation, bodyInformation);\r
+        } else {\r
+               parameters.remove(Names.bodyInformation);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the body Information data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the body Information data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getBodyInformation() {\r
+        return (Boolean) parameters.get(Names.bodyInformation);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes device Status data\r
+        * \r
+        * @param deviceStatus\r
+        *            a boolean value\r
+        */\r
+    public void setDeviceStatus(Boolean deviceStatus) {\r
+        if (deviceStatus != null) {\r
+            parameters.put(Names.deviceStatus, deviceStatus);\r
+        } else {\r
+               parameters.remove(Names.deviceStatus);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the device Status data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the device Status data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getDeviceStatus() {\r
+        return (Boolean) parameters.get(Names.deviceStatus);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes driver Braking data\r
+        * \r
+        * @param driverBraking\r
+        *            a boolean value\r
+        */\r
+    public void setDriverBraking(Boolean driverBraking) {\r
+        if (driverBraking != null) {\r
+            parameters.put(Names.driverBraking, driverBraking);\r
+        } else {\r
+               parameters.remove(Names.driverBraking);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the driver Braking data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the driver Braking data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getDriverBraking() {\r
+        return (Boolean) parameters.get(Names.driverBraking);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes wiper Status data\r
+        * \r
+        * @param wiperStatus\r
+        *            a boolean value\r
+        */\r
+    public void setWiperStatus(Boolean wiperStatus) {\r
+        if (wiperStatus != null) {\r
+            parameters.put(Names.wiperStatus, wiperStatus);\r
+        } else {\r
+               parameters.remove(Names.wiperStatus);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the wiper Status data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the wiper Status data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getWiperStatus() {\r
+        return (Boolean) parameters.get(Names.wiperStatus);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes fuel Economy data\r
+        * \r
+        * @param fuelEconomy\r
+        *            a boolean value\r
+        */\r
+    public void setFuelEconomy(Boolean fuelEconomy) {\r
+        if (fuelEconomy != null) {\r
+            parameters.put(Names.fuelEconomy, fuelEconomy);\r
+        } else {\r
+               parameters.remove(Names.fuelEconomy);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the fuel Economy data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the fuel Economy data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getFuelEconomy() {\r
+        return (Boolean) parameters.get(Names.fuelEconomy);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes Engine Oil Life data\r
+        * \r
+        * @param engineOilLife\r
+        *            a boolean value\r
+        */\r
+    public void setEngineOilLife(Boolean engineOilLife) {\r
+        if (engineOilLife != null) {\r
+            parameters.put(Names.engineOilLife, engineOilLife);\r
+        } else {\r
+               parameters.remove(Names.engineOilLife);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Engine Oil Life data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Engine Oil Life data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getEngineOilLife() {\r
+        return (Boolean) parameters.get(Names.engineOilLife);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes Head Lamp Status data\r
+        * \r
+        * @param headLampStatus\r
+        *            a boolean value\r
+        */\r
+    public void setHeadLampStatus(Boolean headLampStatus) {\r
+        if (headLampStatus != null) {\r
+            parameters.put(Names.headLampStatus, headLampStatus);\r
+        } else {\r
+               parameters.remove(Names.headLampStatus);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Head Lamp Status data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Head Lamp Status data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getHeadLampStatus() {\r
+        return (Boolean) parameters.get(Names.headLampStatus);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes Battery Voltage data\r
+        * \r
+        * @param batteryVoltage\r
+        *            a boolean value\r
+        */\r
+    public void setBatteryVoltage(Boolean batteryVoltage) {\r
+        if (batteryVoltage != null) {\r
+            parameters.put(Names.batteryVoltage, batteryVoltage);\r
+        } else {\r
+               parameters.remove(Names.batteryVoltage);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Battery Voltage data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Battery Voltage data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getBatteryVoltage() {\r
+        return (Boolean) parameters.get(Names.batteryVoltage);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes Brake Torque data\r
+        * \r
+        * @param brakeTorque\r
+        *            a boolean value\r
+        */\r
+    public void setBrakeTorque(Boolean brakeTorque) {\r
+        if (brakeTorque != null) {\r
+            parameters.put(Names.brakeTorque, brakeTorque);\r
+        } else {\r
+               parameters.remove(Names.brakeTorque);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Brake Torque data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Brake Torque data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getBrakeTorque() {\r
+        return (Boolean) parameters.get(Names.brakeTorque);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes Engine Torque data\r
+        * \r
+        * @param engineTorque\r
+        *            a boolean value\r
+        */\r
+    public void setEngineTorque(Boolean engineTorque) {\r
+        if (engineTorque != null) {\r
+            parameters.put(Names.engineTorque, engineTorque);\r
+        } else {\r
+               parameters.remove(Names.engineTorque);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Engine Torque data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Engine Torque data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getEngineTorque() {\r
+        return (Boolean) parameters.get(Names.engineTorque);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes Turbo Boost data\r
+        * \r
+        * @param turboBoost\r
+        *            a boolean value\r
+        */\r
+    public void setTurboBoost(Boolean turboBoost) {\r
+        if (turboBoost != null) {\r
+            parameters.put(Names.turboBoost, turboBoost);\r
+        } else {\r
+               parameters.remove(Names.turboBoost);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Turbo Boost data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Turbo Boost data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getTurboBoost() {\r
+        return (Boolean) parameters.get(Names.turboBoost);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes Coolant Temp data\r
+        * \r
+        * @param coolantTemp\r
+        *            a boolean value\r
+        */\r
+    public void setCoolantTemp(Boolean coolantTemp) {\r
+        if (coolantTemp != null) {\r
+            parameters.put(Names.coolantTemp, coolantTemp);\r
+        } else {\r
+               parameters.remove(Names.coolantTemp);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Coolant Temp data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Coolant Temp data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getCoolantTemp() {\r
+        return (Boolean) parameters.get(Names.coolantTemp);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes Air Fuel Ratio data\r
+        * \r
+        * @param airFuelRatio\r
+        *            a boolean value\r
+        */\r
+    public void setAirFuelRatio(Boolean airFuelRatio) {\r
+        if (airFuelRatio != null) {\r
+            parameters.put(Names.airFuelRatio, airFuelRatio);\r
+        } else {\r
+               parameters.remove(Names.airFuelRatio);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Air Fuel Ratio data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Air Fuel Ratio data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getAirFuelRatio() {\r
+        return (Boolean) parameters.get(Names.airFuelRatio);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes Cooling Head Temp data\r
+        * \r
+        * @param coolingHeadTemp\r
+        *            a boolean value\r
+        */\r
+    public void setCoolingHeadTemp(Boolean coolingHeadTemp) {\r
+        if (coolingHeadTemp != null) {\r
+            parameters.put(Names.coolingHeadTemp, coolingHeadTemp);\r
+        } else {\r
+               parameters.remove(Names.coolingHeadTemp);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Cooling Head Temp data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Cooling Head Temp data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getCoolingHeadTemp() {\r
+        return (Boolean) parameters.get(Names.coolingHeadTemp);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes Cooling Oil Temp data\r
+        * \r
+        * @param oilTemp\r
+        *            a boolean value\r
+        */\r
+    public void setOilTemp(Boolean oilTemp) {\r
+        if (oilTemp != null) {\r
+            parameters.put(Names.oilTemp, oilTemp);\r
+        } else {\r
+               parameters.remove(Names.oilTemp);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Oil Temp data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Oil Temp data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getOilTemp() {\r
+        return (Boolean) parameters.get(Names.oilTemp);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes Intake Air Temp data\r
+        * \r
+        * @param intakeAirTemp\r
+        *            a boolean value\r
+        */\r
+    public void setIntakeAirTemp(Boolean intakeAirTemp) {\r
+        if (intakeAirTemp != null) {\r
+            parameters.put(Names.intakeAirTemp, intakeAirTemp);\r
+        } else {\r
+               parameters.remove(Names.intakeAirTemp);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Intake Air Temp data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Intake Air Temp data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getIntakeAirTemp() {\r
+        return (Boolean) parameters.get(Names.intakeAirTemp);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes Gear Shift Advice data\r
+        * \r
+        * @param gearShiftAdvice\r
+        *            a boolean value\r
+        */\r
+    public void setGearShiftAdvice(Boolean gearShiftAdvice) {\r
+        if (gearShiftAdvice != null) {\r
+            parameters.put(Names.gearShiftAdvice, gearShiftAdvice);\r
+        } else {\r
+               parameters.remove(Names.gearShiftAdvice);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Gear Shift Advice data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Gear Shift Advice data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getGearShiftAdvice() {\r
+        return (Boolean) parameters.get(Names.gearShiftAdvice);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes acceleration data\r
+        * \r
+        * @param acceleration\r
+        *            a boolean value\r
+        */\r
+    public void setAcceleration(Boolean acceleration) {\r
+        if (acceleration != null) {\r
+            parameters.put(Names.acceleration, acceleration);\r
+        } else {\r
+               parameters.remove(Names.acceleration);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the acceleration data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the acceleration data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getAcceleration() {\r
+        return (Boolean) parameters.get(Names.acceleration);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes accPedalPosition data\r
+        * \r
+        * @param accPedalPosition\r
+        *            a boolean value\r
+        */\r
+    public void setAccPedalPosition(Boolean accPedalPosition) {\r
+        if (accPedalPosition != null) {\r
+            parameters.put(Names.accPedalPosition, accPedalPosition);\r
+        } else {\r
+               parameters.remove(Names.accPedalPosition);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the accPedalPosition data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the accPedalPosition data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getAccPedalPosition() {\r
+        return (Boolean) parameters.get(Names.accPedalPosition);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes ClutchPedal Position data\r
+        * \r
+        * @param clutchPedalPosition\r
+        *            a boolean value\r
+        */\r
+    public void setClutchPedalPosition(Boolean clutchPedalPosition) {\r
+        if (clutchPedalPosition != null) {\r
+            parameters.put(Names.clutchPedalPosition, clutchPedalPosition);\r
+        } else {\r
+               parameters.remove(Names.clutchPedalPosition);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the ClutchPedal Position data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the ClutchPedal Position data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getClutchPedalPosition() {\r
+        return (Boolean) parameters.get(Names.clutchPedalPosition);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes Reverse Gear Status data\r
+        * \r
+        * @param reverseGearStatus\r
+        *            a boolean value\r
+        */\r
+    public void setReverseGearStatus(Boolean reverseGearStatus) {\r
+        if (reverseGearStatus != null) {\r
+            parameters.put(Names.reverseGearStatus, reverseGearStatus);\r
+        } else {\r
+               parameters.remove(Names.reverseGearStatus);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Reverse Gear Status data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Reverse Gear Status data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getReverseGearStatus() {\r
+        return (Boolean) parameters.get(Names.reverseGearStatus);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes accTorque data\r
+        * \r
+        * @param accTorque\r
+        *            a boolean value\r
+        */\r
+    public void setAccTorque(Boolean accTorque) {\r
+        if (accTorque != null) {\r
+            parameters.put(Names.accTorque, accTorque);\r
+        } else {\r
+               parameters.remove(Names.accTorque);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the accTorque data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the accTorque data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getAccTorque() {\r
+        return (Boolean) parameters.get(Names.accTorque);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes evInfo data\r
+        * \r
+        * @param evInfo\r
+        *            a boolean value\r
+        */\r
+    public void setEvInfo(Boolean evInfo) {\r
+        if (evInfo != null) {\r
+            parameters.put(Names.evInfo, evInfo);\r
+        } else {\r
+               parameters.remove(Names.evInfo);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the evInfo data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the evInfo data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getEvInfo() {\r
+        return (Boolean) parameters.get(Names.evInfo);\r
+    }\r
+\r
+       /**\r
+        * Sets a boolean value. If true, unsubscribes Ambient Light Status data\r
+        * \r
+        * @param ambientLightStatus\r
+        *            a boolean value\r
+        */\r
+    public void setAmbientLightStatus(Boolean ambientLightStatus) {\r
+        if (ambientLightStatus != null) {\r
+            parameters.put(Names.ambientLightStatus, ambientLightStatus);\r
+        } else {\r
+               parameters.remove(Names.ambientLightStatus);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a boolean value. If true, means the Ambient Light Status data has been\r
+        * unsubscribed.\r
+        * \r
+        * @return Boolean -a Boolean value. If true, means the Ambient Light Status data\r
+        *         has been unsubscribed.\r
+        */\r
+    public Boolean getAmbientLightStatus() {\r
+        return (Boolean) parameters.get(Names.ambientLightStatus);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/UnsubscribeVehicleDataResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/UnsubscribeVehicleDataResponse.java
new file mode 100755 (executable)
index 0000000..9cca680
--- /dev/null
@@ -0,0 +1,1017 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Iterator;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.VehicleDataType;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Unsubscribe Vehicle Data Response is sent, when UnsubscribeVehicleData has been called\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class UnsubscribeVehicleDataResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new UnsubscribeVehicleDataResponse object\r
+        */\r
+    public UnsubscribeVehicleDataResponse() {\r
+        super("UnsubscribeVehicleData");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new UnsubscribeVehicleDataResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public UnsubscribeVehicleDataResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * Sets Gps\r
+     * @param gps\r
+     */\r
+    public void setGps(VehicleDataResult gps) {\r
+        if (gps != null) {\r
+            parameters.put(Names.gps, gps);\r
+        } else {\r
+               parameters.remove(Names.gps);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Gps\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getGps() {\r
+       Object obj = parameters.get(Names.gps);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.gps, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Speed\r
+     * @param speed\r
+     */\r
+    public void setSpeed(VehicleDataResult speed) {\r
+        if (speed != null) {\r
+            parameters.put(Names.speed, speed);\r
+        } else {\r
+               parameters.remove(Names.speed);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Speed\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getSpeed() {\r
+       Object obj = parameters.get(Names.speed);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.speed, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets rpm\r
+     * @param rpm\r
+     */\r
+    public void setRpm(VehicleDataResult rpm) {\r
+        if (rpm != null) {\r
+            parameters.put(Names.rpm, rpm);\r
+        } else {\r
+               parameters.remove(Names.rpm);\r
+        }\r
+    }\r
+    /**\r
+     * Gets rpm\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getRpm() {\r
+       Object obj = parameters.get(Names.rpm);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.rpm, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Fuel Level\r
+     * @param fuelLevel\r
+     */\r
+    public void setFuelLevel(VehicleDataResult fuelLevel) {\r
+        if (fuelLevel != null) {\r
+            parameters.put(Names.fuelLevel, fuelLevel);\r
+        } else {\r
+               parameters.remove(Names.fuelLevel);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Fuel Level\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getFuelLevel() {\r
+       Object obj = parameters.get(Names.fuelLevel);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.fuelLevel, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Fuel Level State\r
+     * @param fuelLevel_State\r
+     */\r
+    public void setFuelLevel_State(VehicleDataResult fuelLevel_State) {\r
+        if (fuelLevel_State != null) {\r
+            parameters.put(Names.fuelLevel_State, fuelLevel_State);\r
+        } else {\r
+               parameters.remove(Names.fuelLevel_State);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Fuel Level State\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getFuelLevel_State() {\r
+       Object obj = parameters.get(Names.fuelLevel_State);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.fuelLevel_State, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Instant Fuel Comsumption\r
+     * @param instantFuelConsumption\r
+     */\r
+    public void setInstantFuelConsumption(VehicleDataResult instantFuelConsumption) {\r
+        if (instantFuelConsumption != null) {\r
+            parameters.put(Names.instantFuelConsumption, instantFuelConsumption);\r
+        } else {\r
+               parameters.remove(Names.instantFuelConsumption);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Instant Fuel Comsumption\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getInstantFuelConsumption() {\r
+       Object obj = parameters.get(Names.instantFuelConsumption);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.instantFuelConsumption, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets External Temperature\r
+     * @param externalTemperature\r
+     */\r
+    public void setExternalTemperature(VehicleDataResult externalTemperature) {\r
+        if (externalTemperature != null) {\r
+            parameters.put(Names.externalTemperature, externalTemperature);\r
+        } else {\r
+               parameters.remove(Names.externalTemperature);\r
+        }\r
+    }\r
+    /**\r
+     * Gets External Temperature\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getExternalTemperature() {\r
+       Object obj = parameters.get(Names.externalTemperature);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.externalTemperature, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Gets currently selected gear data\r
+     * @param prndl\r
+     */\r
+    public void setPrndl(VehicleDataResult prndl) {\r
+        if (prndl != null) {\r
+            parameters.put(Names.prndl, prndl);\r
+        } else {\r
+               parameters.remove(Names.prndl);\r
+        }\r
+    }\r
+    /**\r
+     * Gets currently selected gear data\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getPrndl() {\r
+       Object obj = parameters.get(Names.prndl);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.prndl, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Tire Pressure\r
+     * @param tirePressure\r
+     */\r
+    public void setTirePressure(VehicleDataResult tirePressure) {\r
+        if (tirePressure != null) {\r
+            parameters.put(Names.tirePressure, tirePressure);\r
+        } else {\r
+               parameters.remove(Names.tirePressure);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Tire Pressure\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getTirePressure() {\r
+       Object obj = parameters.get(Names.tirePressure);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.tirePressure, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Odometer\r
+     * @param odometer\r
+     */\r
+    public void setOdometer(VehicleDataResult odometer) {\r
+        if (odometer != null) {\r
+            parameters.put(Names.odometer, odometer);\r
+        } else {\r
+               parameters.remove(Names.odometer);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Odometer\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getOdometer() {\r
+       Object obj = parameters.get(Names.odometer);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.odometer, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Belt Status\r
+     * @param beltStatus\r
+     */\r
+    public void setBeltStatus(VehicleDataResult beltStatus) {\r
+        if (beltStatus != null) {\r
+            parameters.put(Names.beltStatus, beltStatus);\r
+        } else {\r
+               parameters.remove(Names.beltStatus);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Belt Status\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getBeltStatus() {\r
+       Object obj = parameters.get(Names.beltStatus);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.beltStatus, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Body Information\r
+     * @param bodyInformation\r
+     */\r
+    public void setBodyInformation(VehicleDataResult bodyInformation) {\r
+        if (bodyInformation != null) {\r
+            parameters.put(Names.bodyInformation, bodyInformation);\r
+        } else {\r
+               parameters.remove(Names.bodyInformation);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Body Information\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getBodyInformation() {\r
+       Object obj = parameters.get(Names.bodyInformation);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.bodyInformation, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Device Status\r
+     * @param deviceStatus\r
+     */\r
+    public void setDeviceStatus(VehicleDataResult deviceStatus) {\r
+        if (deviceStatus != null) {\r
+            parameters.put(Names.deviceStatus, deviceStatus);\r
+        } else {\r
+               parameters.remove(Names.deviceStatus);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Device Status\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getDeviceStatus() {\r
+       Object obj = parameters.get(Names.deviceStatus);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.deviceStatus, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Driver Braking\r
+     * @param driverBraking\r
+     */\r
+    public void setDriverBraking(VehicleDataResult driverBraking) {\r
+        if (driverBraking != null) {\r
+            parameters.put(Names.driverBraking, driverBraking);\r
+        } else {\r
+               parameters.remove(Names.driverBraking);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Driver Braking\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getDriverBraking() {\r
+       Object obj = parameters.get(Names.driverBraking);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.driverBraking, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Wiper Status\r
+     * @param wiperStatus\r
+     */\r
+    public void setWiperStatus(VehicleDataResult wiperStatus) {\r
+        if (wiperStatus != null) {\r
+            parameters.put(Names.wiperStatus, wiperStatus);\r
+        } else {\r
+               parameters.remove(Names.wiperStatus);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Wiper Status\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getWiperStatus() {\r
+       Object obj = parameters.get(Names.wiperStatus);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.wiperStatus, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Fuel Economy\r
+     * @param fuelEconomy\r
+     */\r
+    public void setFuelEconomy(VehicleDataResult fuelEconomy) {\r
+        if (fuelEconomy != null) {\r
+            parameters.put(Names.fuelEconomy, fuelEconomy);\r
+        } else {\r
+               parameters.remove(Names.fuelEconomy);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Fuel Economy\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getFuelEconomy() {\r
+       Object obj = parameters.get(Names.fuelEconomy);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.fuelEconomy, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Engine Oil Life\r
+     * @param engineOilLife\r
+     */\r
+    public void setEngineOilLife(VehicleDataResult engineOilLife) {\r
+        if (engineOilLife != null) {\r
+            parameters.put(Names.engineOilLife, engineOilLife);\r
+        } else {\r
+               parameters.remove(Names.engineOilLife);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Engine Oil Life\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getEngineOilLife() {\r
+       Object obj = parameters.get(Names.engineOilLife);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.engineOilLife, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Head Lamp Status\r
+     * @param headLampStatus\r
+     */\r
+    public void setHeadLampStatus(VehicleDataResult headLampStatus) {\r
+        if (headLampStatus != null) {\r
+            parameters.put(Names.headLampStatus, headLampStatus);\r
+        } else {\r
+               parameters.remove(Names.headLampStatus);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Head Lamp Status\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getHeadLampStatus() {\r
+       Object obj = parameters.get(Names.headLampStatus);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.headLampStatus, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Battery Voltage\r
+     * @param batteryVoltage\r
+     */\r
+    public void setBatteryVoltage(VehicleDataResult batteryVoltage) {\r
+        if (batteryVoltage != null) {\r
+            parameters.put(Names.batteryVoltage, batteryVoltage);\r
+        } else {\r
+               parameters.remove(Names.batteryVoltage);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Battery Voltage\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getBatteryVoltage() {\r
+       Object obj = parameters.get(Names.batteryVoltage);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.batteryVoltage, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Brake Torque\r
+     * @param brakeTorque\r
+     */\r
+    public void setBrakeTorque(VehicleDataResult brakeTorque) {\r
+        if (brakeTorque != null) {\r
+            parameters.put(Names.brakeTorque, brakeTorque);\r
+        } else {\r
+               parameters.remove(Names.brakeTorque);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Brake Torque\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getBrakeTorque() {\r
+       Object obj = parameters.get(Names.brakeTorque);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.brakeTorque, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Engine Torque\r
+     * @param engineTorque\r
+     */\r
+    public void setEngineTorque(VehicleDataResult engineTorque) {\r
+        if (engineTorque != null) {\r
+            parameters.put(Names.engineTorque, engineTorque);\r
+        } else {\r
+               parameters.remove(Names.engineTorque);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Engine Torque\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getEngineTorque() {\r
+       Object obj = parameters.get(Names.engineTorque);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.engineTorque, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Turbo Boost\r
+     * @param turboBoost\r
+     */\r
+    public void setTurboBoost(VehicleDataResult turboBoost) {\r
+        if (turboBoost != null) {\r
+            parameters.put(Names.turboBoost, turboBoost);\r
+        } else {\r
+               parameters.remove(Names.turboBoost);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Turbo Boost\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getTurboBoost() {\r
+       Object obj = parameters.get(Names.turboBoost);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.turboBoost, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Coolant Temp\r
+     * @param coolantTemp\r
+     */\r
+    public void setCoolantTemp(VehicleDataResult coolantTemp) {\r
+        if (coolantTemp != null) {\r
+            parameters.put(Names.coolantTemp, coolantTemp);\r
+        } else {\r
+               parameters.remove(Names.coolantTemp);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Coolant Temp\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getCoolantTemp() {\r
+       Object obj = parameters.get(Names.coolantTemp);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.coolantTemp, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Air Fuel Ratio\r
+     * @param airFuelRatio\r
+     */\r
+    public void setAirFuelRatio(VehicleDataResult airFuelRatio) {\r
+        if (airFuelRatio != null) {\r
+            parameters.put(Names.airFuelRatio, airFuelRatio);\r
+        } else {\r
+               parameters.remove(Names.airFuelRatio);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Air Fuel Ratio\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getAirFuelRatio() {\r
+       Object obj = parameters.get(Names.airFuelRatio);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.airFuelRatio, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Cooling Head Temp\r
+     * @param coolingHeadTemp\r
+     */\r
+    public void setCoolingHeadTemp(VehicleDataResult coolingHeadTemp) {\r
+        if (coolingHeadTemp != null) {\r
+            parameters.put(Names.coolingHeadTemp, coolingHeadTemp);\r
+        } else {\r
+               parameters.remove(Names.coolingHeadTemp);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Cooling Head Temp\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getCoolingHeadTemp() {\r
+       Object obj = parameters.get(Names.coolingHeadTemp);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.coolingHeadTemp, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Oil Temp\r
+     * @param oilTemp\r
+     */\r
+    public void setOilTemp(VehicleDataResult oilTemp) {\r
+        if (oilTemp != null) {\r
+            parameters.put(Names.oilTemp, oilTemp);\r
+        } else {\r
+               parameters.remove(Names.oilTemp);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Oil Temp\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getOilTemp() {\r
+       Object obj = parameters.get(Names.oilTemp);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.oilTemp, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Intake Air Temp\r
+     * @param intakeAirTemp\r
+     */\r
+    public void setIntakeAirTemp(VehicleDataResult intakeAirTemp) {\r
+        if (intakeAirTemp != null) {\r
+            parameters.put(Names.intakeAirTemp, intakeAirTemp);\r
+        } else {\r
+               parameters.remove(Names.intakeAirTemp);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Intake Air Temp\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getIntakeAirTemp() {\r
+       Object obj = parameters.get(Names.intakeAirTemp);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.intakeAirTemp, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Gear Shift Advice\r
+     * @param gearShiftAdvice\r
+     */\r
+    public void setGearShiftAdvice(VehicleDataResult gearShiftAdvice) {\r
+        if (gearShiftAdvice != null) {\r
+            parameters.put(Names.gearShiftAdvice, gearShiftAdvice);\r
+        } else {\r
+               parameters.remove(Names.gearShiftAdvice);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Gear Shift Advice\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getGearShiftAdvice() {\r
+       Object obj = parameters.get(Names.gearShiftAdvice);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.gearShiftAdvice, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Acceleration\r
+     * @param acceleration\r
+     */\r
+    public void setAcceleration(VehicleDataResult acceleration) {\r
+        if (acceleration != null) {\r
+            parameters.put(Names.acceleration, acceleration);\r
+        } else {\r
+               parameters.remove(Names.acceleration);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Acceleration\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getAcceleration() {\r
+       Object obj = parameters.get(Names.acceleration);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.acceleration, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets AccPedal Position\r
+     * @param accPedalPosition\r
+     */\r
+    public void setAccPedalPosition(VehicleDataResult accPedalPosition) {\r
+        if (accPedalPosition != null) {\r
+            parameters.put(Names.accPedalPosition, accPedalPosition);\r
+        } else {\r
+               parameters.remove(Names.accPedalPosition);\r
+        }\r
+    }\r
+    /**\r
+     * Gets AccPedal Position\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getAccPedalPosition() {\r
+       Object obj = parameters.get(Names.accPedalPosition);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.accPedalPosition, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets ClutchPedal Position\r
+     * @param clutchPedalPosition\r
+     */\r
+    public void setClutchPedalPosition(VehicleDataResult clutchPedalPosition) {\r
+        if (clutchPedalPosition != null) {\r
+            parameters.put(Names.clutchPedalPosition, clutchPedalPosition);\r
+        } else {\r
+               parameters.remove(Names.clutchPedalPosition);\r
+        }\r
+    }\r
+    /**\r
+     * Gets ClutchPedal Position\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getClutchPedalPosition() {\r
+       Object obj = parameters.get(Names.clutchPedalPosition);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.clutchPedalPosition, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Reverse Gear Status\r
+     * @param reverseGearStatus\r
+     */\r
+    public void setReverseGearStatus(VehicleDataResult reverseGearStatus) {\r
+        if (reverseGearStatus != null) {\r
+            parameters.put(Names.reverseGearStatus, reverseGearStatus);\r
+        } else {\r
+               parameters.remove(Names.reverseGearStatus);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Reverse Gear Status\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getReverseGearStatus() {\r
+       Object obj = parameters.get(Names.reverseGearStatus);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.reverseGearStatus, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets AccTorque\r
+     * @param accTorque\r
+     */\r
+    public void setAccTorque(VehicleDataResult accTorque) {\r
+        if (accTorque != null) {\r
+            parameters.put(Names.accTorque, accTorque);\r
+        } else {\r
+               parameters.remove(Names.accTorque);\r
+        }\r
+    }\r
+    /**\r
+     * Gets AccTorque\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getAccTorque() {\r
+       Object obj = parameters.get(Names.accTorque);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.accTorque, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Event Info\r
+     * @param evInfo\r
+     */\r
+    public void setEvInfo(VehicleDataResult evInfo) {\r
+        if (evInfo != null) {\r
+            parameters.put(Names.evInfo, evInfo);\r
+        } else {\r
+               parameters.remove(Names.evInfo);\r
+        }\r
+    }\r
+    /**\r
+     * Gets Event Info\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getEvInfo() {\r
+       Object obj = parameters.get(Names.evInfo);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.evInfo, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    /**\r
+     * Sets Ambient Light Status\r
+     * @param ambientLightStatus\r
+     */\r
+    public void setAmbientLightStatus(VehicleDataResult ambientLightStatus) {\r
+        if (ambientLightStatus != null) {\r
+            parameters.put(Names.ambientLightStatus, ambientLightStatus);\r
+        } else {\r
+               parameters.remove(Names.ambientLightStatus);\r
+        }\r
+    }\r
+    /**\r
+     * Get Ambient Light Status\r
+     * @return VehicleDataResult\r
+     */\r
+    public VehicleDataResult getAmbientLightStatus() {\r
+       Object obj = parameters.get(Names.ambientLightStatus);\r
+        if (obj instanceof VehicleDataResult) {\r
+            return (VehicleDataResult) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new VehicleDataResult((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.ambientLightStatus, e);\r
+            }\r
+        }\r
+        return null;\r
+    }   \r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/UpdateTurnList.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/UpdateTurnList.java
new file mode 100755 (executable)
index 0000000..77c0005
--- /dev/null
@@ -0,0 +1,122 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Updates the list of next maneuvers, which can be requested by the user\r
+ * pressing the softbutton "Turns" on the Navigation base screen. Three\r
+ * softbuttons are predefined by the system: Up, Down, Close\r
+ * <p>\r
+ * Function Group: Navigation\r
+ * <p>\r
+ * <b>HMILevel needs to be FULL, LIMITED or BACKGROUND</b>\r
+ * <p>\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ * @see ShowConstantTBT\r
+ */\r
+public class UpdateTurnList extends RPCRequest {\r
+\r
+       /**\r
+        * Constructs a new UpdateTurnList object\r
+        */\r
+    public UpdateTurnList() {\r
+        super("UpdateTurnList");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new UpdateTurnList object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public UpdateTurnList(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+\r
+       /**\r
+        * Sets a list of turns to be shown to the user\r
+        * \r
+        * @param turnList\r
+        *            a Vector<Turn> value representing a list of turns to be shown\r
+        *            to the user\r
+        *            <p>\r
+        *            <b>Notes: </b>Minsize=1; Maxsize=100\r
+        */\r
+    public void setTurnList(Vector<Turn> turnList) {\r
+        if (turnList != null) {\r
+            parameters.put(Names.turnList, turnList);\r
+        } else {\r
+               parameters.remove(Names.turnList);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets a list of turns to be shown to the user\r
+        * \r
+        * @return Vector<Turn> -a Vector value representing a list of turns\r
+        */\r
+    public Vector<Turn> getTurnList() {\r
+        if (parameters.get(Names.turnList) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.turnList);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof Turn) {\r
+                       return (Vector<Turn>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<Turn> newList = new Vector<Turn>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new Turn((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+\r
+       /**\r
+        * Sets soft buttons in the screen. If omitted on supported displays,\r
+        * app-defined SoftButton will be left blank\r
+        * <p>\r
+        * <b>Notes: </b>Minsize=0; Maxsize=1\r
+        * \r
+        * @param softButtons a Vector value\r
+        */\r
+    public void setSoftButtons(Vector<SoftButton> softButtons) {\r
+        if (softButtons != null) {\r
+            parameters.put(Names.softButtons, softButtons);\r
+        } else {\r
+               parameters.remove(Names.softButtons);\r
+        }\r
+    }\r
+\r
+       /**\r
+        * Gets soft buttons in the screen\r
+        * @return Vector -a Vector<SoftButton> value\r
+        */\r
+    public Vector<SoftButton> getSoftButtons() {\r
+        if (parameters.get(Names.softButtons) instanceof Vector<?>) {\r
+               Vector<?> list = (Vector<?>)parameters.get(Names.softButtons);\r
+               if (list != null && list.size() > 0) {\r
+                   Object obj = list.get(0);\r
+                   if (obj instanceof SoftButton) {\r
+                       return (Vector<SoftButton>) list;\r
+                   } else if (obj instanceof Hashtable) {\r
+                       Vector<SoftButton> newList = new Vector<SoftButton>();\r
+                       for (Object hashObj : list) {\r
+                           newList.add(new SoftButton((Hashtable)hashObj));\r
+                       }\r
+                       return newList;\r
+                   }\r
+               }\r
+        }\r
+        return null;\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/UpdateTurnListResponse.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/UpdateTurnListResponse.java
new file mode 100755 (executable)
index 0000000..360d3b0
--- /dev/null
@@ -0,0 +1,32 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+\r
+/**\r
+ * Update Turn List Response is sent, when UpdateTurnList has been called\r
+ * \r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class UpdateTurnListResponse extends RPCResponse {\r
+\r
+       /**\r
+        * Constructs a new UpdateTurnListResponse object\r
+        */\r
+    public UpdateTurnListResponse() {\r
+        super("UpdateTurnList");\r
+    }\r
+\r
+       /**\r
+        * Constructs a new UpdateTurnListResponse object indicated by the Hashtable\r
+        * parameter\r
+        * <p>\r
+        * \r
+        * @param hash\r
+        *            The Hashtable to use\r
+        */\r
+    public UpdateTurnListResponse(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+}
\ No newline at end of file
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/VehicleDataResult.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/VehicleDataResult.java
new file mode 100755 (executable)
index 0000000..c1d199e
--- /dev/null
@@ -0,0 +1,62 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.proxy.rpc.enums.DisplayType;\r
+import com.smartdevicelink.proxy.rpc.enums.VehicleDataResultCode;\r
+import com.smartdevicelink.proxy.rpc.enums.VehicleDataType;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+public class VehicleDataResult extends RPCStruct {\r
+\r
+    public VehicleDataResult() { }\r
+    public VehicleDataResult(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public void setDataType(VehicleDataType dataType) {\r
+       if (dataType != null) {\r
+               store.put(Names.dataType, dataType);\r
+       } else {\r
+               store.remove(Names.dataType);\r
+       }\r
+    }\r
+    public VehicleDataType getDataType() {\r
+        Object obj = store.get(Names.dataType);\r
+        if (obj instanceof VehicleDataType) {\r
+            return (VehicleDataType) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataType theCode = null;\r
+            try {\r
+                theCode = VehicleDataType.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.dataType, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+    public void setResultCode(VehicleDataResultCode resultCode) {\r
+       if (resultCode != null) {\r
+               store.put(Names.resultCode, resultCode);\r
+       } else {\r
+               store.remove(Names.resultCode);\r
+       }\r
+    }\r
+    public VehicleDataResultCode getResultCode() {\r
+        Object obj = store.get(Names.resultCode);\r
+        if (obj instanceof VehicleDataResultCode) {\r
+            return (VehicleDataResultCode) obj;\r
+        } else if (obj instanceof String) {\r
+               VehicleDataResultCode theCode = null;\r
+            try {\r
+                theCode = VehicleDataResultCode.valueForString((String) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.resultCode, e);\r
+            }\r
+            return theCode;\r
+        }\r
+        return null;\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/VehicleType.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/VehicleType.java
new file mode 100755 (executable)
index 0000000..7811100
--- /dev/null
@@ -0,0 +1,155 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Describes the type of vehicle the mobile phone is connected with.\r
+ * <p><b>Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>make</td>\r
+ *                     <td>String</td>\r
+ *                     <td>Make of the vehicle, e.g. Ford\r
+ *                              <ul>\r
+ *                                     <li>Maxlength = 500</li>\r
+ *                              </ul> \r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>Model</td>\r
+ *                     <td>String</td>\r
+ *                     <td>Model of the vehicle, e.g. Fiesta\r
+ *                              <ul>\r
+ *                                     <li>Maxlength = 500</li>\r
+ *                              </ul> \r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>modelYear</td>\r
+ *                     <td>String</td>\r
+ *                     <td>Model Year of the vehicle, e.g. 2013\r
+ *                              <ul>\r
+ *                                     <li>Maxlength = 500</li>\r
+ *                              </ul> \r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>trim</td>\r
+ *                     <td>String</td>\r
+ *                     <td>Trim of the vehicle, e.g. SE\r
+ *                              <ul>\r
+ *                                     <li>Maxlength = 500</li>\r
+ *                              </ul> \r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 2.0</td>\r
+ *             </tr>\r
+ *  </table>\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public class VehicleType extends RPCStruct {\r
+\r
+       /**\r
+        * Constructs a newly allocated VehicleType object\r
+        */\r
+    public VehicleType() { }\r
+    \r
+    /**\r
+     * Constructs a newly allocated VehicleType object indicated by the Hashtable parameter\r
+     * @param hash The Hashtable to use\r
+     */\r
+    public VehicleType(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    \r
+    /**\r
+     * get the make of the vehicle\r
+     * @return the make of the vehicle\r
+     */\r
+    public String getMake() {\r
+        return (String) store.get(Names.make);\r
+    }\r
+    \r
+    /**\r
+     * set the make of the vehicle\r
+     *@param make the make of the vehicle\r
+     */\r
+    public void setMake(String make) {\r
+        if (make != null) {\r
+            store.put(Names.make, make);\r
+        } else {\r
+               store.remove(Names.make);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get the model of the vehicle\r
+     * @return the model of the vehicle\r
+     */\r
+    public String getModel() {\r
+        return (String) store.get(Names.model);\r
+    }\r
+    \r
+    /**\r
+     * set the model of the vehicle\r
+     * @param model the model of the vehicle\r
+     */\r
+    public void setModel(String model) {\r
+        if (model != null) {\r
+            store.put(Names.model, model);\r
+        } else {\r
+               store.remove(Names.model);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get the model year of the vehicle\r
+     * @return the model year of the vehicle\r
+     */\r
+    public String getModelYear() {\r
+        return (String) store.get(Names.modelYear);\r
+    }\r
+    \r
+    /**\r
+     * set the model year of the vehicle\r
+     * @param modelYear the model year of the vehicle\r
+     */\r
+    public void setModelYear(String modelYear) {\r
+        if (modelYear != null) {\r
+            store.put(Names.modelYear, modelYear);\r
+        } else {\r
+               store.remove(Names.modelYear);\r
+        }\r
+    }\r
+    \r
+    /**\r
+     * get the trim of the vehicle\r
+     * @return the trim of the vehicle\r
+     */\r
+    public String getTrim() {\r
+        return (String) store.get(Names.trim);\r
+    }\r
+    \r
+    /**\r
+     * set the trim of the vehicle\r
+     * @param trim the trim of the vehicle\r
+     */\r
+    public void setTrim(String trim) {\r
+        if (trim != null) {\r
+            store.put(Names.trim, trim);\r
+        } else {\r
+               store.remove(Names.trim);\r
+        }\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/VrHelpItem.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/VrHelpItem.java
new file mode 100755 (executable)
index 0000000..20c9a1e
--- /dev/null
@@ -0,0 +1,55 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+public class VrHelpItem extends RPCStruct {\r
+\r
+    public VrHelpItem() { }\r
+    public VrHelpItem(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    public void setText(String text) {\r
+        if (text != null) {\r
+            store.put(Names.text, text);\r
+        } else {\r
+               store.remove(Names.text);\r
+        }\r
+    }\r
+    public String getText() {\r
+        return (String) store.get(Names.text);\r
+    }\r
+    public void setImage(Image image) {\r
+        if (image != null) {\r
+            store.put(Names.image, image);\r
+        } else {\r
+               store.remove(Names.image);\r
+        }\r
+    }\r
+    public Image getImage() {\r
+       Object obj = store.get(Names.image);\r
+        if (obj instanceof Image) {\r
+            return (Image) obj;\r
+        } else if (obj instanceof Hashtable) {\r
+               try {\r
+                       return new Image((Hashtable) obj);\r
+            } catch (Exception e) {\r
+               DebugTool.logError("Failed to parse " + getClass().getSimpleName() + "." + Names.image, e);\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+    public void setPosition(Integer position) {\r
+        if (position != null) {\r
+            store.put(Names.position, position);\r
+        } else {\r
+               store.remove(Names.position);\r
+        }\r
+    }\r
+    public Integer getPosition() {\r
+        return (Integer) store.get(Names.position);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/AmbientLightStatus.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/AmbientLightStatus.java
new file mode 100755 (executable)
index 0000000..0e67a49
--- /dev/null
@@ -0,0 +1,14 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+public enum AmbientLightStatus {\r
+       DARK,\r
+       LIGHT,\r
+       TWILIGHT,\r
+       TUNNEL_ON,\r
+       TUNNEL_OFF,\r
+       NO_DATA_EXISTS;\r
+\r
+    public static AmbientLightStatus valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/AppHMIType.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/AppHMIType.java
new file mode 100755 (executable)
index 0000000..e8c58db
--- /dev/null
@@ -0,0 +1,54 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Enumeration listing possible app hmi types.\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public enum AppHMIType {\r
+       /**\r
+        * The App will have default rights.\r
+        */\r
+    DEFAULT,\r
+    /**\r
+     * Communication type of App\r
+     */\r
+    COMMUNICATION,\r
+    /**\r
+     * App dealing with Media\r
+     */\r
+    MEDIA,\r
+    /**\r
+     * Messaging App\r
+     */\r
+    MESSAGING,\r
+    /**\r
+     * Navigation App\r
+     */\r
+    NAVIGATION,\r
+    /**\r
+     * Information App\r
+     */\r
+    INFORMATION,\r
+    /**\r
+     * App dealing with social media\r
+     */\r
+    SOCIAL,\r
+    BACKGROUND_PROCESS,\r
+    /**\r
+     * App only for Testing purposes\r
+     */\r
+    TESTING,\r
+    /**\r
+     * System App\r
+     */\r
+    SYSTEM;\r
+\r
+    /**\r
+     * Convert String to AppHMIType\r
+     * @param value String\r
+     * @return AppHMIType\r
+     */      \r
+    public static AppHMIType valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
index 8c96fb4..b3bde86 100755 (executable)
@@ -1,22 +1,83 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-
-public enum AppInterfaceUnregisteredReason {
-    USER_EXIT,
-    IGNITION_OFF,
-    BLUETOOTH_OFF,
-    USB_DISCONNECTED,
-    REQUEST_WHILE_IN_NONE_HMI_LEVEL,
-    TOO_MANY_REQUESTS,
-    DRIVER_DISTRACTION_VIOLATION,
-    LANGUAGE_CHANGE,
-    MASTER_RESET,
-    FACTORY_DEFAULTS;
-
-    public static AppInterfaceUnregisteredReason valueForString(String value) {
-        return valueOf(value);
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Indicates reason why app interface was unregistered. The application is being\r
+ * disconnected by SMARTDEVICELINK.\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public enum AppInterfaceUnregisteredReason {\r
+       USER_EXIT,\r
+       /**\r
+        * Vehicle ignition turned off.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       IGNITION_OFF,\r
+       /**\r
+        * Bluetooth was turned off, causing termination of a necessary Bluetooth\r
+        * connection.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       BLUETOOTH_OFF,\r
+       /**\r
+        * USB was disconnected, causing termination of a necessary iAP connection.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       USB_DISCONNECTED,\r
+       /**\r
+        * Application attempted SmartDeviceLink RPC request while {@linkplain HMILevel}\r
+        * =NONE. App must have HMILevel other than NONE to issue RPC requests or\r
+        * get notifications or RPC responses.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       REQUEST_WHILE_IN_NONE_HMI_LEVEL,\r
+       /**\r
+        * Either too many -- or too many per unit of time -- requests were made by\r
+        * the application.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       TOO_MANY_REQUESTS,\r
+       /**\r
+        * The application has issued requests which cause driver distraction rules\r
+        * to be violated.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       DRIVER_DISTRACTION_VIOLATION,\r
+       /**\r
+        * The user has changed the language in effect on the SMARTDEVICELINK platform to a\r
+        * language that is incompatible with the language declared by the\r
+        * application in its RegisterAppInterface request.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       LANGUAGE_CHANGE,\r
+       /**\r
+        * The user performed a MASTER RESET on the SMARTDEVICELINK platform, causing removal\r
+        * of a necessary Bluetooth pairing.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       MASTER_RESET,\r
+       /**\r
+        * The user restored settings to FACTORY DEFAULTS on the SMARTDEVICELINK platform.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       FACTORY_DEFAULTS, \r
+       /**\r
+        * The app is not being authorized by Ford to be connected to SMARTDEVICELINK.\r
+        * \r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+       APP_UNAUTHORIZED;\r
+\r
+    public static AppInterfaceUnregisteredReason valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
index 4c9d945..dea3504 100755 (executable)
@@ -1,13 +1,37 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum AudioStreamingState {
-    AUDIBLE,
-    NOT_AUDIBLE;
-
-    public static AudioStreamingState valueForString(String value) {
-        return valueOf(value);
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Describes whether or not streaming audio is currently audible to the user.\r
+ * Though provided in every OnHMIStatus notification, this information is only\r
+ * relevant for applications that declare themselves as media apps in\r
+ * RegisterAppInterface\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public enum AudioStreamingState {\r
+       /**\r
+        * Currently streaming audio, if any, is audible to user.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       AUDIBLE,\r
+\r
+       /**\r
+        * Some kind of audio mixing is taking place. Currently streaming audio, if\r
+        * any, is audible to the user at a lowered volume.\r
+        * \r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+       ATTENUATED,\r
+       /**\r
+        * Currently streaming audio, if any, is not audible to user. made via VR\r
+        * session.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       NOT_AUDIBLE;\r
+\r
+    public static AudioStreamingState valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/AudioType.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/AudioType.java
new file mode 100755 (executable)
index 0000000..f0f1f42
--- /dev/null
@@ -0,0 +1,18 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Describes different audio type options for PerformAudioPassThru\r
+ * \r
+ */\r
+public enum AudioType {\r
+       /**\r
+        * PCM raw audio\r
+        * \r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    PCM;\r
+\r
+    public static AudioType valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/BitsPerSample.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/BitsPerSample.java
new file mode 100755 (executable)
index 0000000..f0f2548
--- /dev/null
@@ -0,0 +1,41 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+import java.util.EnumSet;\r
+\r
+/**\r
+ * Describes different bit depth options for PerformAudioPassThru\r
+ * \r
+ */\r
+public enum BitsPerSample {\r
+       /**\r
+        * 8 bits per sample\r
+        * \r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+       _8_BIT("8_BIT"),\r
+       /**\r
+        * 16 bits per sample\r
+        * \r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+       _16_BIT("16_BIT");\r
+\r
+    String internalName;\r
+    \r
+    private BitsPerSample(String internalName) {\r
+        this.internalName = internalName;\r
+    }\r
+    \r
+    public String toString() {\r
+        return this.internalName;\r
+    }\r
+    \r
+    public static BitsPerSample valueForString(String value) {         \r
+       for (BitsPerSample anEnum : EnumSet.allOf(BitsPerSample.class)) {\r
+            if (anEnum.toString().equals(value)) {\r
+                return anEnum;\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+}\r
index 7a75345..46ab6d0 100755 (executable)
@@ -1,13 +1,31 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum ButtonEventMode {
-    BUTTONUP,
-    BUTTONDOWN;
-
-    public static ButtonEventMode valueForString(String value) {
-        return valueOf(value);
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Indicates whether the button was depressed or released. A BUTTONUP event will\r
+ * always be preceded by a BUTTONDOWN event\r
+ * <p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public enum ButtonEventMode {\r
+       /**\r
+        * The button was released\r
+        */\r
+       BUTTONUP,\r
+       /**\r
+        * The button was depressed\r
+        */\r
+       BUTTONDOWN;\r
+\r
+       /**\r
+        * Returns a ButtonEventMode (BUTTONUP or BUTTONDOWN)\r
+        * \r
+        * @param value\r
+        *            a String\r
+        * @return ButtonEventMode -BUTTONUP or BUTTONDOWN\r
+        */\r
+\r
+    public static ButtonEventMode valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
index 0c7cf59..8ab57d3 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum ButtonName{
-    OK,
-    SEEKLEFT,
-    SEEKRIGHT,
-    TUNEUP,
-    TUNEDOWN,
-    PRESET_0,
-    PRESET_1,
-    PRESET_2,
-    PRESET_3,
-    PRESET_4,
-    PRESET_5,
-    PRESET_6,
-    PRESET_7,
-    PRESET_8,
-    PRESET_9;
-
-    public static ButtonName valueForString(String value) {
-        return valueOf(value);
-    }
-    
-    /**
-     * indexForPresetButton returns the integer index for preset buttons
-     * which match the preset order. E.G.: indexForPresetButton(PRESET_1)
-     * returns the value 1. If the buttonName given is not a preset button,
-     * the method will return null.
-     *  
-     * @param buttonName
-     * @return Integer
-     */
-    public static Integer indexForPresetButton(ButtonName buttonName) {
-       
-       Integer returnIndex = null;
-       
-       switch(buttonName) {            
-               case PRESET_0:
-                       returnIndex = 0;
-                       break;
-               case PRESET_1:
-                       returnIndex = 1;
-                       break;
-               case PRESET_2:
-                       returnIndex = 2;
-                       break;
-               case PRESET_3:
-                       returnIndex = 3;
-                       break;
-               case PRESET_4:
-                       returnIndex = 4;
-                       break;
-               case PRESET_5:
-                       returnIndex = 5;
-                       break;
-               case PRESET_6:
-                       returnIndex = 6;
-                       break;
-               case PRESET_7:
-                       returnIndex = 7;
-                       break;
-               case PRESET_8:
-                       returnIndex = 8;
-                       break;
-               case PRESET_9:
-                       returnIndex = 9;
-                       break;
-       }
-       
-       return returnIndex;
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * <p>\r
+ * Defines logical buttons which, on a given SMARTDEVICELINK unit, would correspond to\r
+ * either physical or soft (touchscreen) buttons. These logical buttons present\r
+ * a standard functional abstraction which the developer can rely upon,\r
+ * independent of the SMARTDEVICELINK unit. For example, the developer can rely upon the OK\r
+ * button having the same meaning to the user across SMARTDEVICELINK platforms.\r
+ * </p>\r
+ * <p>\r
+ * The preset buttons (0-9) can typically be interpreted by the application as\r
+ * corresponding to some user-configured choices, though the application is free\r
+ * to interpret these button presses as it sees fit.\r
+ * </p>\r
+ * <p>\r
+ * The application can discover which buttons a given SMARTDEVICELINK unit implements by\r
+ * interrogating the ButtonCapabilities parameter of the\r
+ * RegisterAppInterface response.\r
+ * </p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public enum ButtonName{\r
+       /**\r
+        * Represents the button usually labeled "OK". A typical use of this button\r
+        * is for the user to press it to make a selection.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       OK,\r
+       /**\r
+        * Represents the seek-left button. A typical use of this button is for the\r
+        * user to scroll to the left through menu choices one menu item per press.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       SEEKLEFT,\r
+       /**\r
+        * Represents the seek-right button. A typical use of this button is for the\r
+        * user to scroll to the right through menu choices one menu item per press.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       SEEKRIGHT,\r
+       /**\r
+        * Represents a turn of the tuner knob in the clockwise direction one tick.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       TUNEUP,\r
+       /**\r
+        * Represents a turn of the tuner knob in the counter-clockwise direction\r
+        * one tick.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       TUNEDOWN,\r
+       /**\r
+        * Represents the preset 0 button.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       PRESET_0,\r
+       /**\r
+        * Represents the preset 1 button.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       PRESET_1,\r
+       /**\r
+        * Represents the preset 2 button.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       PRESET_2,\r
+       /**\r
+        * Represents the preset 3 button.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       PRESET_3,\r
+       /**\r
+        * Represents the preset 4 button.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       PRESET_4,\r
+       /**\r
+        * Represents the preset 5 button.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       PRESET_5,\r
+       /**\r
+        * Represents the preset 6 button.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       PRESET_6,\r
+       /**\r
+        * Represents the preset 7 button.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       PRESET_7,\r
+       /**\r
+        * Represents the preset 8 button.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       PRESET_8,\r
+       /**\r
+        * Represents the preset 9 button.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       PRESET_9, CUSTOM_BUTTON;\r
+\r
+    public static ButtonName valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+    \r
+    /**\r
+     * indexForPresetButton returns the integer index for preset buttons\r
+     * which match the preset order. E.G.: indexForPresetButton(PRESET_1)\r
+     * returns the value 1. If the buttonName given is not a preset button,\r
+     * the method will return null.\r
+     *  \r
+     * @param buttonName\r
+     * @return Integer\r
+     */\r
+    public static Integer indexForPresetButton(ButtonName buttonName) {\r
+       \r
+       Integer returnIndex = null;\r
+       \r
+       switch(buttonName) {            \r
+               case PRESET_0:\r
+                       returnIndex = 0;\r
+                       break;\r
+               case PRESET_1:\r
+                       returnIndex = 1;\r
+                       break;\r
+               case PRESET_2:\r
+                       returnIndex = 2;\r
+                       break;\r
+               case PRESET_3:\r
+                       returnIndex = 3;\r
+                       break;\r
+               case PRESET_4:\r
+                       returnIndex = 4;\r
+                       break;\r
+               case PRESET_5:\r
+                       returnIndex = 5;\r
+                       break;\r
+               case PRESET_6:\r
+                       returnIndex = 6;\r
+                       break;\r
+               case PRESET_7:\r
+                       returnIndex = 7;\r
+                       break;\r
+               case PRESET_8:\r
+                       returnIndex = 8;\r
+                       break;\r
+               case PRESET_9:\r
+                       returnIndex = 9;\r
+                       break;\r
+       }\r
+       \r
+       return returnIndex;\r
+    }\r
+}\r
index caf1b90..cb29119 100755 (executable)
@@ -1,13 +1,31 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum ButtonPressMode {
-    LONG,
-    SHORT;
-
-    public static ButtonPressMode valueForString(String value) {
-        return valueOf(value);
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Indicates whether this is a LONG or SHORT button press\r
+ * <p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public enum ButtonPressMode {\r
+       /**\r
+        * The button has been depressed for 2 seconds. The button may remain\r
+        * depressed after receiving this event\r
+        */\r
+       LONG,\r
+       /**\r
+        * The button was released before the 2-second long-press interval had\r
+        * elapsed\r
+        */\r
+       SHORT;\r
+       /**\r
+        * Returns a ButtonPressMode (LONG or SHORT)\r
+        * \r
+        * @param value\r
+        *            a String\r
+        * @return ButtonPressMode -LONG or SHORT\r
+        */\r
+\r
+    public static ButtonPressMode valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
index 6083835..4fc3ecd 100755 (executable)
@@ -1,15 +1,20 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum CharacterSet {
-    TYPE2SET,
-    TYPE5SET,
-    CID1SET,
-    CID2SET;
-
-    public static CharacterSet valueForString(String value) {
-        return valueOf(value);
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+/**\r
+ * Character sets supported by SMARTDEVICELINK.\r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public enum CharacterSet {\r
+    TYPE2SET,\r
+    TYPE5SET,\r
+    CID1SET,\r
+    CID2SET;\r
+\r
+    /**\r
+     * Convert String to CharacterSet\r
+     * @param value String\r
+     * @return CharacterSet\r
+     */\r
+    public static CharacterSet valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/CompassDirection.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/CompassDirection.java
new file mode 100755 (executable)
index 0000000..5c08761
--- /dev/null
@@ -0,0 +1,49 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * The list of potential compass directions\r
+ * @since SmartDeviceLink 2.0 \r
+ */\r
+public enum CompassDirection {\r
+       /**\r
+        * Direction North\r
+        */\r
+       NORTH,\r
+       /**\r
+        * Direction Northwest\r
+        */\r
+       NORTHWEST,\r
+       /**\r
+        * Direction West\r
+        */\r
+       WEST,\r
+       /**\r
+        * Direction Southwest\r
+        */\r
+       SOUTHWEST,\r
+       /**\r
+        * Direction South\r
+        */\r
+       SOUTH,\r
+       /**\r
+        * Direction Southeast\r
+        */\r
+       SOUTHEAST,\r
+       /**\r
+        * Direction East\r
+        */\r
+       EAST,\r
+       /**\r
+        * Direction Northeast\r
+        */\r
+       NORTHEAST;\r
+\r
+    /**\r
+     * Convert String to CompassDirection\r
+     * @param value String\r
+     * @return CompassDirection\r
+     */\r
+    public static CompassDirection valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/ComponentVolumeStatus.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/ComponentVolumeStatus.java
new file mode 100755 (executable)
index 0000000..e32b5ac
--- /dev/null
@@ -0,0 +1,41 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * The volume status of a vehicle component\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public enum ComponentVolumeStatus {\r
+       /**\r
+        * Unknown\r
+        */\r
+       UNKNOWN,\r
+       /**\r
+        * Normal\r
+        */\r
+       NORMAL,\r
+       /**\r
+        * Low\r
+        */\r
+       LOW,\r
+       /**\r
+        * Fault\r
+        */\r
+       FAULT,\r
+       /**\r
+        * Alert\r
+        */\r
+       ALERT,\r
+       /**\r
+        * Not supported\r
+        */\r
+       NOT_SUPPORTED;\r
+\r
+    /**\r
+     * Convert String to ComponentVolumeStatus\r
+     * @param value String\r
+     * @return ComponentVolumeStatus\r
+     */        \r
+    public static ComponentVolumeStatus valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/DeviceLevelStatus.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/DeviceLevelStatus.java
new file mode 100755 (executable)
index 0000000..af0f0e6
--- /dev/null
@@ -0,0 +1,41 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Reflects the reported battery status of the connected device, if reported.\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public enum DeviceLevelStatus {\r
+       /**\r
+        * Zero level bars\r
+        */\r
+       ZERO_LEVEL_BARS,\r
+       /**\r
+        * One level bars\r
+        */\r
+       ONE_LEVEL_BARS,\r
+       /**\r
+        * Two level bars\r
+        */\r
+       TWO_LEVEL_BARS,\r
+       /**\r
+        * Three level bars\r
+        */\r
+       THREE_LEVEL_BARS,\r
+       /**\r
+        * Four level bars\r
+        */\r
+       FOUR_LEVEL_BARS,\r
+       /**\r
+        * Not provided\r
+        */\r
+       NOT_PROVIDED;\r
+\r
+    /**\r
+     * Convert String to DeviceLevelStatus\r
+     * @param value String\r
+     * @return DeviceLevelStatus\r
+     */        \r
+    public static DeviceLevelStatus valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/Dimension.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/Dimension.java
new file mode 100755 (executable)
index 0000000..b95355d
--- /dev/null
@@ -0,0 +1,46 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+import java.util.EnumSet;\r
+\r
+/**\r
+ * The supported dimensions of the GPS.\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public enum Dimension {\r
+       /**\r
+        * No GPS at all\r
+        */\r
+    NO_FIX("NO_FIX"),\r
+    /**\r
+     * Longitude and latitude\r
+     */\r
+    _2D("2D"),\r
+    /**\r
+     * Longitude and latitude and altitude\r
+     */\r
+    _3D("3D");\r
+    \r
+    String internalName;\r
+\r
+    private Dimension(String internalName) {\r
+       this.internalName = internalName;\r
+    }\r
+    \r
+    public String toString() {\r
+        return this.internalName;\r
+    }\r
+    \r
+    /**\r
+     * Convert String to Dimension\r
+     * @param value String\r
+     * @return Dimension\r
+     */    \r
+    public static Dimension valueForString(String value) {\r
+       for (Dimension anEnum : EnumSet.allOf(Dimension.class)) {\r
+            if (anEnum.toString().equals(value)) {\r
+                return anEnum;\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+}\r
index df8dd1a..de1c907 100755 (executable)
@@ -1,18 +1,32 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum DisplayType {
-    CID,
-    TYPE2,
-    TYPE5,
-    NGN,
-    GEN2_4_DMA,
-    GEN2_8_DMA,
-    GEN2_4_HUD;
-
-    public static DisplayType valueForString(String value) {
-        return valueOf(value);
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Identifies the various display types used by SMARTDEVICELINK. See SmartDeviceLink TDK and Head Unit Guide for further information regarding the displays.\r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public enum DisplayType {\r
+       /**\r
+        * This display type provides a 2-line x 20 character "dot matrix" display.\r
+        */     \r
+    CID,\r
+    TYPE2,\r
+    TYPE5,\r
+    /**\r
+     * This display type provides an 8 inch touchscreen display.\r
+     */    \r
+    NGN,\r
+    GEN2_8_DMA,\r
+    GEN2_6_DMA,\r
+    MFD3,\r
+    MFD4,\r
+    MFD5;\r
+\r
+    /**\r
+     * Convert String to DisplayType\r
+     * @param value String\r
+     * @return DisplayType\r
+     */\r
+    public static DisplayType valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
index 112881e..ef7db42 100755 (executable)
@@ -1,13 +1,28 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum DriverDistractionState {
-       DD_ON,
-       DD_OFF;
-       
-       public static DriverDistractionState valueForString(String value) {
-       return valueOf(value);
-    }
-}
+/**\r
+ * \r
+ */\r
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Enumeration that describes possible states of driver distraction.\r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public enum DriverDistractionState {\r
+       /**\r
+        * Driver distraction rules are in effect.\r
+        */\r
+       DD_ON,\r
+       /**\r
+        * Driver distraction rules are NOT in effect.\r
+        */\r
+       DD_OFF;\r
+       \r
+       /**\r
+        * Convert String to DriverDistractionState\r
+        * @param value String\r
+        * @return DriverDistractionState\r
+        */\r
+       public static DriverDistractionState valueForString(String value) {\r
+       return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/FileType.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/FileType.java
new file mode 100755 (executable)
index 0000000..2d2f3e7
--- /dev/null
@@ -0,0 +1,37 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Enumeration listing possible file tpyes.\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public enum FileType {\r
+       /**\r
+        * BMP\r
+        */\r
+    GRAPHIC_BMP,\r
+    /**\r
+     * JPEG\r
+     */\r
+    GRAPHIC_JPEG,\r
+    /**\r
+     * PNG\r
+     */\r
+    GRAPHIC_PNG,\r
+    /**\r
+     * WAVE\r
+     */\r
+    AUDIO_WAVE,\r
+    /**\r
+     * MP3\r
+     */\r
+    AUDIO_MP3;\r
+\r
+    /**\r
+     * Convert String to FileType\r
+     * @param value String\r
+     * @return FileType\r
+     */      \r
+    public static FileType valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/FunctionID.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/FunctionID.java
new file mode 100755 (executable)
index 0000000..b77d3a0
--- /dev/null
@@ -0,0 +1,59 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+public enum FunctionID {\r
+       RESERVED,\r
+       RegisterAppInterface,\r
+       UnregisterAppInterface,\r
+       SetGlobalProperties,\r
+       ResetGlobalProperties,\r
+       AddCommand,\r
+       DeleteCommand,\r
+       AddSubMenu,\r
+       DeleteSubMenu,\r
+       CreateInteractionChoiceSet,\r
+       PerformInteraction,\r
+       DeleteInteractionChoiceSet,\r
+       Alert,\r
+       Show,\r
+       Speak,\r
+       SetMediaClockTimer,\r
+       EncodedSyncPData,\r
+       DialNumber,\r
+       PerformAudioPassThru,\r
+       EndAudioPassThru,\r
+       SubscribeButton,\r
+       UnsubscribeButton,\r
+       SubscribeVehicleData,\r
+       UnsubscribeVehicleData,\r
+       GetVehicleData,\r
+       ReadDID,\r
+       GetDTCs,\r
+       ScrollableMessage,\r
+       Slider,\r
+       ShowConstantTBT,\r
+       AlertManeuver,\r
+       UpdateTurnList,\r
+       ChangeLanguageRegistration,\r
+       GenericResponse,\r
+       PutFile,\r
+       DeleteFile,\r
+       ListFiles,\r
+       SetAppIcon,\r
+       SetDisplayLayout,\r
+       OnHMIStatus,\r
+       OnAppInterfaceUnregistered,\r
+       OnButtonEvent,\r
+       OnButtonPress,\r
+       OnVehicleData,\r
+       OnCommand,\r
+       OnEncodedSyncPData,\r
+       OnTBTClientState,\r
+       OnDriverDistraction,\r
+       OnPermissionsChange,\r
+       OnAudioPassThru,\r
+       OnLanguageChange;\r
+\r
+    public static FunctionID valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/GearShiftAdviceStatus.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/GearShiftAdviceStatus.java
new file mode 100755 (executable)
index 0000000..19ca8ba
--- /dev/null
@@ -0,0 +1,14 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+public enum GearShiftAdviceStatus {\r
+       NO_INDICATION,\r
+       UPSHIFT_FUEL_ECONOMY,\r
+       UPSHIFT_PERFORMANCE,\r
+       UPSHIFT_WARNING,\r
+       DOWNSHIFT_RECOMMENDATION,\r
+       SHIFT_TO_NEUTRAL;\r
+\r
+    public static GearShiftAdviceStatus valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
index d30523d..7b61ad0 100755 (executable)
@@ -1,13 +1,27 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum GlobalProperty{
-    HELPPROMPT,
-    TIMEOUTPROMPT;
-
-    public static GlobalProperty valueForString(String value) {
-        return valueOf(value);
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Properties of a user-initiated VR interaction (i.e. interactions started by the user pressing the PTT button).\r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public enum GlobalProperty{\r
+       /**\r
+        * The help prompt to be spoken if the user needs assistance during a user-initiated interaction.\r
+        */\r
+    HELPPROMPT,\r
+    /**\r
+     * The prompt to be spoken if the user-initiated interaction times out waiting for the user's verbal input.\r
+     */\r
+    TIMEOUTPROMPT,\r
+    VRHELPTITLE,\r
+    VRHELPITEMS;\r
+\r
+    /**\r
+     * Convert String to GlobalProperty\r
+     * @param value String\r
+     * @return GlobalProperty\r
+     */\r
+    public static GlobalProperty valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
index eb3ace7..5ff0930 100755 (executable)
@@ -1,32 +1,66 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-import java.util.EnumSet;
-
-public enum HMILevel {
-    HMI_FULL("FULL"),
-    HMI_LIMITED("LIMITED"),
-    HMI_BACKGROUND("BACKGROUND"),
-    HMI_NONE("NONE");
-
-    String internalName;
-    
-    private HMILevel(String internalName) {
-        this.internalName = internalName;
-    }
-    
-    public String toString() {
-        return this.internalName;
-    }
-    
-    public static HMILevel valueForString(String value) {
-        for (HMILevel anEnum : EnumSet.allOf(HMILevel.class)) {
-            if (anEnum.toString().equals(value)) {
-                return anEnum;
-            }
-        }
-        return null;
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+import java.util.EnumSet;\r
+\r
+/**\r
+ * Specifies current level of the HMI. An HMI level indicates the degree of user interaction possible through the HMI (e.g. TTS only, display only, VR, etc.). The HMI level varies for an application based on the type of display (i.e. Nav or non-Nav) and the user directing "focus" to other applications (e.g. phone, other mobile applications, etc.)\r
+ * <p>\r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public enum HMILevel {\r
+       /**\r
+        * The application has full use of the SMARTDEVICELINK HMI. The app may output via TTS, display, or streaming audio and may gather input via VR, Menu, and button presses\r
+        */\r
+    HMI_FULL("FULL"),\r
+    /**\r
+     * This HMI Level is only defined for a media application using an HMI with an 8 inch touchscreen (Nav) system. The application's {@linkplain com.smartdevicelink.proxy.rpc.Show} text is displayed and it receives button presses from media-oriented buttons (SEEKRIGHT, SEEKLEFT, TUNEUP, TUNEDOWN, PRESET_0-9)\r
+     */\r
+    HMI_LIMITED("LIMITED"),\r
+    /**\r
+     * App cannot interact with user via TTS, VR, Display or Button Presses. App can perform the following operations:<br/>\r
+     * <ul>\r
+     * <li>Operation {@linkplain com.smartdevicelink.proxy.rpc.AddCommand}</li>\r
+     * <li>Operation {@linkplain com.smartdevicelink.proxy.rpc.DeleteCommand}</li>\r
+     * <li>Operation {@linkplain com.smartdevicelink.proxy.rpc.AddSubMenu}</li>\r
+     * <li>Operation {@linkplain com.smartdevicelink.proxy.rpc.DeleteSubMenu}</li>\r
+     * <li>Operation {@linkplain com.smartdevicelink.proxy.rpc.CreateInteractionChoiceSet}</li>\r
+     * <li>Operation {@linkplain com.smartdevicelink.proxy.rpc.DeleteInteractionChoiceSet}</li>\r
+     * <li>Operation {@linkplain com.smartdevicelink.proxy.rpc.SubscribeButton}</li>\r
+     * <li>Operation {@linkplain com.smartdevicelink.proxy.rpc.UnsubscribeButton}</li>\r
+     * <li>Operation {@linkplain com.smartdevicelink.proxy.rpc.Show}</li>\r
+     * <li>Operation {@linkplain com.smartdevicelink.proxy.rpc.UnregisterAppInterface}</li>\r
+     * <li>Operation {@linkplain com.smartdevicelink.proxy.rpc.ResetGlobalProperties}</li>\r
+     * <li>Operation {@linkplain com.smartdevicelink.proxy.rpc.SetGlobalProperties}</li>\r
+     * </ul>\r
+     */\r
+    HMI_BACKGROUND("BACKGROUND"),\r
+    /**\r
+     * Application has been discovered by SMARTDEVICELINK, but application cannot send any requests or receive any notifications<br/>\r
+     * An HMILevel of NONE can also mean that the user has exited the application by saying "exit appname" or selecting "exit" from the application's menu. When this happens, the application still has an active interface registration with SMARTDEVICELINK and all SMARTDEVICELINK resources the application has created (e.g. Choice Sets, subscriptions, etc.) still exist. But while the HMILevel is NONE, the application cannot send any messages to SMARTDEVICELINK, except <i>{@linkplain com.smartdevicelink.proxy.rpc.UnregisterAppInterface}</li>\r
+     */\r
+    HMI_NONE("NONE");\r
+\r
+    String internalName;\r
+    \r
+    private HMILevel(String internalName) {\r
+        this.internalName = internalName;\r
+    }\r
+    \r
+    public String toString() {\r
+        return this.internalName;\r
+    }\r
+    \r
+    /**\r
+     * Returns a HMILevel Status (FULL, LIMITED, BACKGROUND or NONE)\r
+     * @param value a String\r
+     * @return HMILevel -a String value (FULL, LIMITED, BACKGROUND or NONE)\r
+     */\r
+    public static HMILevel valueForString(String value) {\r
+        for (HMILevel anEnum : EnumSet.allOf(HMILevel.class)) {\r
+            if (anEnum.toString().equals(value)) {\r
+                return anEnum;\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+}\r
index e652999..e9c04b7 100755 (executable)
@@ -1,13 +1,24 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum HmiZoneCapabilities {
-    FRONT,
-    BACK;
-
-    public static HmiZoneCapabilities valueForString(String value) {
-        return valueOf(value);
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Specifies HMI Zones in the vehicle.\r
+ * \r
+ */\r
+public enum HmiZoneCapabilities {\r
+       /**\r
+        * Indicates HMI available for front seat passengers.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       FRONT,\r
+       /**\r
+        * Indicates HMI available for rear seat passengers.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       BACK;\r
+\r
+    public static HmiZoneCapabilities valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/IgnitionStableStatus.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/IgnitionStableStatus.java
new file mode 100755 (executable)
index 0000000..acff462
--- /dev/null
@@ -0,0 +1,26 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Reflects the ignition switch stability.\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public enum IgnitionStableStatus {\r
+       /**\r
+        * The current ignition switch status is considered not to be stable.\r
+        */\r
+       IGNITION_SWITCH_NOT_STABLE,\r
+       /**\r
+        * The current ignition switch status is considered to be stable.\r
+        */\r
+       IGNITION_SWITCH_STABLE,\r
+       MISSING_FROM_TRANSMITTER;\r
+\r
+    /**\r
+     * Convert String to IgnitionStableStatus\r
+     * @param value String\r
+     * @return IgnitionStableStatus\r
+     */        \r
+    public static IgnitionStableStatus valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/IgnitionStatus.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/IgnitionStatus.java
new file mode 100755 (executable)
index 0000000..877b37c
--- /dev/null
@@ -0,0 +1,41 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Reflects the status of ignition..\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public enum IgnitionStatus {\r
+       /**\r
+        * Ignition status currently unknown\r
+        */\r
+       UNKNOWN,\r
+       /**\r
+        * Ignition is off\r
+        */\r
+       OFF,\r
+       /**\r
+        * Ignition is in mode accessory\r
+        */\r
+       ACCESSORY,\r
+       /**\r
+        * Ignition is in mode run\r
+        */\r
+       RUN,\r
+       /**\r
+        * Ignition is in mode run\r
+        */\r
+       START,\r
+       /**\r
+        * Signal is invalid\r
+        */\r
+       INVALID;\r
+\r
+    /**\r
+     * Convert String to IgnitionStatus\r
+     * @param value String\r
+     * @return IgnitionStatus\r
+     */        \r
+    public static IgnitionStatus valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/ImageType.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/ImageType.java
new file mode 100755 (executable)
index 0000000..c908366
--- /dev/null
@@ -0,0 +1,25 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Contains information about the type of image.\r
+ * @since SmartDeviceLink 2.0 \r
+ */\r
+public enum ImageType {\r
+       /**\r
+        * Just the static hex icon value to be used\r
+        */\r
+    STATIC,\r
+    /**\r
+     * Binary image file to be used (identifier to be sent by PutFile)\r
+     */\r
+    DYNAMIC;\r
+\r
+    /**\r
+     * Convert String to ImageType\r
+     * @param value String\r
+     * @return ImageType\r
+     */\r
+    public static ImageType valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
index cc898dc..30eb426 100755 (executable)
@@ -1,14 +1,54 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum InteractionMode {
-    MANUAL_ONLY,
-    VR_ONLY,
-    BOTH;
-
-    public static InteractionMode valueForString(String value) {
-        return valueOf(value);
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * For application-initiated interactions (<i>{@linkplain com.smartdevicelink.proxy.rpc.PerformInteraction}</i>), this specifies\r
+ * the mode by which the user is prompted and by which the user's selection is\r
+ * indicated\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public enum InteractionMode {\r
+       /**\r
+        * This mode causes the interaction to occur only on the display, meaning\r
+        * the choices are presented and selected only via the display. Selections\r
+        * are viewed with the SEEKRIGHT, SEEKLEFT, TUNEUP, TUNEDOWN buttons. User's\r
+        * selection is indicated with the OK button\r
+        */\r
+       MANUAL_ONLY,\r
+       /**\r
+        * This mode causes the interaction to occur only through TTS and VR. The\r
+        * user is prompted via TTS to select a choice by saying one of the choice's\r
+        * synonyms\r
+        */\r
+       VR_ONLY,\r
+       /**\r
+        * This mode is a combination of MANUAL_ONLY and VR_ONLY, meaning the user\r
+        * is prompted both visually and audibly. The user can make a selection\r
+        * either using the mode described in MANUAL_ONLY or using the mode\r
+        * described in VR_ONLY. If the user views selections as described in\r
+        * MANUAL_ONLY mode, the interaction becomes strictly, and irreversibly, a\r
+        * MANUAL_ONLY interaction (i.e. the VR session is cancelled, although the\r
+        * interaction itself is still in progress). If the user interacts with the\r
+        * VR session in any way (e.g. speaks a phrase, even if it is not a\r
+        * recognized choice), the interaction becomes strictly, and irreversibly, a\r
+        * VR_ONLY interaction (i.e. the MANUAL_ONLY mode forms of interaction will\r
+        * no longer be honored)\r
+        * <P>\r
+        * The TriggerSource parameter of the\r
+        * {@linkplain com.smartdevicelink.proxy.rpc.PerformInteraction} response will\r
+        * indicate which interaction mode the user finally chose to attempt the\r
+        * selection (even if the interaction did not end with a selection being\r
+        * made)\r
+        */\r
+       BOTH;\r
+\r
+       /**\r
+        * Returns InteractionMode (MANUAL_ONLY, VR_ONLY or BOTH)\r
+        * @param value a String\r
+        * @return InteractionMode -MANUAL_ONLY, VR_ONLY or BOTH\r
+        */\r
+\r
+    public static InteractionMode valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
index f4d2040..c5a345c 100755 (executable)
@@ -1,31 +1,63 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-import java.util.EnumSet;
-
-public enum Language {
-    EN_US("EN-US"),
-    ES_MX("ES-MX"),
-    FR_CA("FR-CA");
-
-    String internalName;
-    
-    private Language(String internalName) {
-        this.internalName = internalName;
-    }
-    
-    public String toString() {
-        return this.internalName;
-    }
-    
-    public static Language valueForString(String value) {              
-       for (Language anEnum : EnumSet.allOf(Language.class)) {
-            if (anEnum.toString().equals(value)) {
-                return anEnum;
-            }
-        }
-        return null;
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+import java.util.EnumSet;\r
+\r
+/**\r
+ * Specifies the language to be used for TTS, VR, displayed messages/menus\r
+ * <p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ *\r
+ */\r
+public enum Language {\r
+    EN_US("EN-US"),\r
+    ES_MX("ES-MX"),\r
+    FR_CA("FR-CA"),\r
+    DE_DE("DE-DE"),\r
+    ES_ES("ES-ES"),\r
+    EN_GB("EN-GB"),\r
+    RU_RU("RU-RU"),\r
+    TR_TR("TR-TR"),\r
+    PL_PL("PL-PL"),\r
+    FR_FR("FR-FR"),\r
+    IT_IT("IT-IT"),\r
+    SV_SE("SV-SE"),\r
+    PT_PT("PT-PT"),\r
+    NL_NL("NL-NL"),\r
+    EN_AU("EN-AU"),\r
+    ZH_CN("ZH-CN"),\r
+    ZH_TW("ZH-TW"),\r
+    JA_JP("JA-JP"),\r
+    AR_SA("AR-SA"),\r
+    KO_KR("KO-KR"),\r
+    PT_BR("PT-BR"),\r
+    CS_CZ("CS-CZ"),\r
+    DA_DK("DA-DK"),\r
+    NO_NO("NO-NO");\r
+\r
+    String internalName;\r
+    \r
+    private Language(String internalName) {\r
+        this.internalName = internalName;\r
+    }\r
+    /**\r
+     * Returns a String representing a kind of Language\r
+     */\r
+    public String toString() {\r
+        return this.internalName;\r
+    }\r
+    \r
+    /**\r
+     * Returns a Language's name\r
+     * @param value a String\r
+     * @return Language -EN-US, ES-MX or FR-CA\r
+     */\r
+    public static Language valueForString(String value) {              \r
+       for (Language anEnum : EnumSet.allOf(Language.class)) {\r
+            if (anEnum.toString().equals(value)) {\r
+                return anEnum;\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/LightSwitchStatus.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/LightSwitchStatus.java
new file mode 100755 (executable)
index 0000000..53a5cbd
--- /dev/null
@@ -0,0 +1,12 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+public enum LightSwitchStatus {\r
+       OFF,\r
+       PARKLAMP,\r
+       HEADLAMP,\r
+       AUTOLAMP;\r
+\r
+    public static LightSwitchStatus valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/MaintenanceModeStatus.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/MaintenanceModeStatus.java
new file mode 100755 (executable)
index 0000000..3914b3e
--- /dev/null
@@ -0,0 +1,12 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+public enum MaintenanceModeStatus {\r
+       NORMAL,\r
+       NEAR,\r
+       ACTIVE,\r
+       FEATURE_NOT_PRESENT;\r
+\r
+    public static MaintenanceModeStatus valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
index 98f40cc..50e8e3d 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum MediaClockFormat {
-    CLOCK1,
-    CLOCK2,
-    CLOCKTEXT1,
-    CLOCKTEXT2,
-    CLOCKTEXT3;
-
-    public static MediaClockFormat valueForString(String value) {
-        return valueOf(value);
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Indicates the format of the time displayed on the connected SMARTDEVICELINK unit.Format\r
+ * description follows the following nomenclature:<br> Sp = Space<br> | = or <br>c =\r
+ * character\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public enum MediaClockFormat {\r
+       /**\r
+        * <p>\r
+        * </p>\r
+        * <ul>\r
+        * <li>maxHours = 19</li>\r
+        * <li>maxMinutes = 59</li>\r
+        * <li>maxSeconds = 59</li>\r
+        * </ul>\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        * \r
+        */\r
+       CLOCK1,\r
+       /**\r
+        * <p>\r
+        * </p>\r
+        * <ul>\r
+        * <li>maxHours = 59</li>\r
+        * <li>maxMinutes = 59</li>\r
+        * <li>maxSeconds = 59</li>\r
+        * </ul>\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        * \r
+        */    \r
+       CLOCK2,\r
+       /**\r
+        * <p>\r
+        * </p>\r
+        * <ul>\r
+        * <li>maxHours = 9</li>\r
+        * <li>maxMinutes = 59</li>\r
+        * <li>maxSeconds = 59</li>\r
+        * </ul>\r
+        * \r
+        * @since SmartDeviceLink 2.0\r
+        * \r
+        */\r
+    CLOCK3,\r
+       /**\r
+        * <p>\r
+        * </p>\r
+        * <ul>\r
+        * <li>5 characters possible</li>\r
+        * <li>Format: 1|sp c :|sp c c</li>\r
+        * <li>1|sp : digit "1" or space</li>\r
+        * <li>c : character out of following character set: sp|0-9|[letters, see\r
+        * TypeII column in XLS.</li>\r
+        * <li>:|sp : colon or space</li>\r
+        * <li>used for Type II headunit</li>\r
+        * </ul>\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */    \r
+    CLOCKTEXT1,\r
+       /**\r
+        * <p>\r
+        * </p>\r
+        * <ul>\r
+        * <li>5 characters possible</li>\r
+        * <li>Format: 1|sp c :|sp c c</li>\r
+        * <li>1|sp : digit "1" or space</li>\r
+        * <li>c : character out of following character set: sp|0-9|[letters, see\r
+        * CID column in XLS.</li>\r
+        * <li>:|sp : colon or space</li>\r
+        * <li>used for CID headunit</li>\r
+        * </ul>\r
+        * difference between CLOCKTEXT1 and CLOCKTEXT2 is the supported character\r
+        * set\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */    \r
+    CLOCKTEXT2,\r
+       /**\r
+        * <p>\r
+        * </p>\r
+        * <ul>\r
+        * <li>6 chars possible</li>\r
+        * <li>Format: 1|sp c c :|sp c c</li>\r
+        * <li>1|sp : digit "1" or space</li>\r
+        * <li>c : character out of following character set: sp|0-9|[letters, see\r
+        * Type 5 column in XLS].</li>\r
+        * <li>:|sp : colon or space</li>\r
+        * <li>used for Type V headunit</li>\r
+        * </ul>\r
+        * difference between CLOCKTEXT1 and CLOCKTEXT2 is the supported character\r
+        * set\r
+        * \r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */    \r
+    CLOCKTEXT3,\r
+       /**\r
+        * <p>\r
+        * </p>\r
+        * <ul>\r
+        * <li>6 chars possible</li>\r
+        * <li>Format:      c   :|sp   c   c   :   c   c</li>\r
+        * <li>:|sp : colon or space</li>\r
+        * <li>c    : character out of following character set: sp|0-9|[letters]</li>\r
+        * <li>used for MFD3/4/5 headunits</li>\r
+        * </ul>\r
+        * \r
+        * \r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+    CLOCKTEXT4;\r
+\r
+    public static MediaClockFormat valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/MessageType.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/MessageType.java
new file mode 100755 (executable)
index 0000000..15d70de
--- /dev/null
@@ -0,0 +1,11 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+public enum MessageType {\r
+    request,\r
+    response,\r
+    notification;\r
+\r
+    public static MessageType valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/PRNDL.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/PRNDL.java
new file mode 100755 (executable)
index 0000000..1c256af
--- /dev/null
@@ -0,0 +1,62 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * The selected gear.\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public enum PRNDL {\r
+       /**\r
+        * Parking\r
+        */\r
+    PARK,\r
+    /**\r
+     * Reverse gear\r
+     */\r
+    REVERSE,\r
+    /**\r
+     * No gear\r
+     */\r
+    NEUTRAL,\r
+    DRIVE,\r
+    /**\r
+     * Drive Sport mode\r
+     */\r
+    SPORT,\r
+    /**\r
+     * 1st gear hold\r
+     */\r
+    LOWGEAR,\r
+    /**\r
+     * First gear\r
+     */\r
+    FIRST,\r
+    /**\r
+     * Second gear\r
+     */\r
+    SECOND,\r
+    /**\r
+     * Third gear\r
+     */\r
+    THIRD,\r
+    /**\r
+     * Fourth gear\r
+     */\r
+    FOURTH,\r
+    /**\r
+     * Fifth gear\r
+     */\r
+    FIFTH,\r
+    /**\r
+     * Sixth gear\r
+     */\r
+    SIXTH;\r
+\r
+    /**\r
+     * Convert String to PRNDL\r
+     * @param value String\r
+     * @return PRNDL\r
+     */         \r
+    public static PRNDL valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
index 4ae99bf..a564a9b 100755 (executable)
@@ -1,15 +1,21 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum PermissionStatus {
-       ALLOWED,
-       DISALLOWED,
-       USER_DISALLOWED,
-       USER_CONSENT_PENDING;
-       
-       public static PermissionStatus valueForString(String value) {
-        return valueOf(value);
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Enumeration that describes possible permission states of a policy table entry.\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public enum PermissionStatus {\r
+       ALLOWED,\r
+       DISALLOWED,\r
+       USER_DISALLOWED,\r
+       USER_CONSENT_PENDING;\r
+       \r
+    /**\r
+     * Convert String to PermissionStatus\r
+     * @param value String\r
+     * @return PermissionStatus\r
+     */    \r
+       public static PermissionStatus valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/PrimaryAudioSource.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/PrimaryAudioSource.java
new file mode 100755 (executable)
index 0000000..b42f3f8
--- /dev/null
@@ -0,0 +1,45 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Reflects the current primary audio source of SMARTDEVICELINK (if selected).\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public enum PrimaryAudioSource {\r
+       /**\r
+        * Currently no source selected\r
+        */\r
+    NO_SOURCE_SELECTED,\r
+    /**\r
+     * USB is current source\r
+     */\r
+    USB,\r
+    /**\r
+     * USB2 is current source\r
+     */\r
+    USB2,\r
+    /**\r
+     * Bluetooth Stereo is current source\r
+     */\r
+    BLUETOOTH_STEREO_BTST,\r
+    /**\r
+     * Line in is current source\r
+     */\r
+    LINE_IN,\r
+    /**\r
+     * iPod is current source\r
+     */\r
+    IPOD,\r
+    /**\r
+     * Mobile app is current source\r
+     */\r
+    MOBILE_APP;\r
+\r
+    /**\r
+     * Convert String to PrimaryAudioSource\r
+     * @param value String\r
+     * @return PrimaryAudioSource\r
+     */        \r
+    public static PrimaryAudioSource valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
index daf6f28..f5d4a28 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum Result {
-    SUCCESS,
-    INVALID_DATA,
-    UNSUPPORTED_REQUEST,
-    OUT_OF_MEMORY,
-    TOO_MANY_PENDING_REQUESTS,
-    INVALID_ID,
-    DUPLICATE_NAME,
-    TOO_MANY_APPLICATIONS,
-    APPLICATION_REGISTERED_ALREADY,
-    UNSUPPORTED_VERSION,
-    WRONG_LANGUAGE,
-    APPLICATION_NOT_REGISTERED,
-    IN_USE,
-    SUBSCRIBED_ALREADY,
-    VEHICLE_DATA_NOT_ALLOWED,
-    VEHICLE_DATA_NOT_AVAILABLE,
-    REJECTED,
-    ABORTED,
-    IGNORED,
-    UNSUPPORTED_BUTTON,
-    FILE_NOT_FOUND,
-    GENERIC_ERROR;
-
-    public static Result valueForString(String value) {
-        return valueOf(value);
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Defines the possible result codes returned by SMARTDEVICELINK to the application in a\r
+ * Response to a requested operation\r
+ * <p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public enum Result {\r
+       /**\r
+        * The request succeeded\r
+        */    \r
+       SUCCESS,\r
+       /**\r
+        * The data sent is invalid. For example:<br/>\r
+        * <ul>\r
+        * <li>Invalid Json syntax</li>\r
+        * <li>Parameters out of bounds (number or enum range)</li>\r
+        * <li>Mandatory parameters not provided</li>\r
+        * <li>Parameter provided with wrong type</li>\r
+        * <li>Invalid characters</li>\r
+        * <li>Empty string</li>\r
+        * </ul>\r
+        */    \r
+       INVALID_DATA,\r
+       /**\r
+        * The request is not supported by SMARTDEVICELINK\r
+        */    \r
+       UNSUPPORTED_REQUEST,\r
+       /**\r
+        * The system could not process the request because the necessary memory\r
+        * couldn't be allocated\r
+        */    \r
+       OUT_OF_MEMORY,\r
+       /**\r
+        * There are too many requests pending (means that the response has not been\r
+        * delivered yet). There is a limit of 1000 pending requests at a time\r
+        */    \r
+       TOO_MANY_PENDING_REQUESTS,\r
+       /**\r
+        * One of the provided IDs is not valid. For example:<br/>\r
+        * <ul>\r
+        * <li>CorrelationID</li>\r
+        * <li>CommandID</li>\r
+        * <li>MenuID</li>\r
+        * </ul>\r
+        */\r
+       INVALID_ID,\r
+       /**\r
+        * The provided name or synonym is a duplicate of some already-defined name\r
+        * or synonym\r
+        */    \r
+    DUPLICATE_NAME,\r
+       /**\r
+        * Specified application name is already associated with an active interface\r
+        * registration. Attempts at doing a second <i>\r
+        * {@linkplain com.smartdevicelink.proxy.rpc.RegisterAppInterface}</i> on a\r
+        * given protocol session will also cause this\r
+        */    \r
+    TOO_MANY_APPLICATIONS,\r
+       /**\r
+        * SMARTDEVICELINK does not support the interface version requested by the mobile\r
+        * application\r
+        */    \r
+    APPLICATION_REGISTERED_ALREADY,\r
+       /**\r
+        * The requested language is currently not supported. Might be because of a\r
+        * mismatch of the currently active language\r
+        */    \r
+    UNSUPPORTED_VERSION,\r
+       /**\r
+        * The request cannot be executed because no application interface has been\r
+        * registered via <i>\r
+        * {@linkplain com.smartdevicelink.proxy.rpc.RegisterAppInterface}</i>\r
+        */    \r
+       WRONG_LANGUAGE,\r
+       /**\r
+        * The request cannot be executed because no application interface has been\r
+        * registered via <i>\r
+        * {@linkplain com.smartdevicelink.proxy.rpc.RegisterAppInterface}</i>\r
+        */\r
+       APPLICATION_NOT_REGISTERED,\r
+       /**\r
+        * The data may not be changed, because it is currently in use. For example,\r
+        * when trying to delete a Choice Set that is currently involved in an\r
+        * interaction\r
+        */\r
+       IN_USE,\r
+       /**\r
+        * There is already an existing subscription for this item\r
+        */\r
+    VEHICLE_DATA_NOT_ALLOWED,\r
+       VEHICLE_DATA_NOT_AVAILABLE,\r
+       /**\r
+        * The requested operation was rejected. No attempt was made to perform the\r
+        * operation\r
+        */\r
+       REJECTED,\r
+       /**\r
+        * The requested operation was aborted due to some pre-empting event (e.g.\r
+        * button push, <i>{@linkplain com.smartdevicelink.proxy.rpc.Alert}</i>\r
+        * pre-empts <i>{@linkplain com.smartdevicelink.proxy.rpc.Speak}</i>, etc.)\r
+        */\r
+       ABORTED,\r
+       /**\r
+        * The requested operation was ignored because it was determined to be\r
+        * redundant (e.g. pause media clock when already paused)\r
+        */\r
+       IGNORED,\r
+       /**\r
+        * A button that was requested for subscription is not supported on the\r
+        * currently connected SMARTDEVICELINK platform. See DisplayCapabilities for further\r
+        * information on supported buttons on the currently connected SMARTDEVICELINK platform\r
+        */\r
+    UNSUPPORTED_RESOURCE,\r
+    FILE_NOT_FOUND,\r
+    GENERIC_ERROR,\r
+    DISALLOWED,\r
+    USER_DISALLOWED,\r
+    TIMED_OUT,\r
+    CANCEL_ROUTE,\r
+    TRUNCATED_DATA,\r
+    RETRY,\r
+    WARNINGS;\r
+\r
+    public static Result valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/SamplingRate.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/SamplingRate.java
new file mode 100755 (executable)
index 0000000..1f30cf0
--- /dev/null
@@ -0,0 +1,54 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+import java.util.EnumSet;\r
+\r
+/**\r
+ * Describes different sampling rates for PerformAudioPassThru\r
+ * \r
+ */\r
+public enum SamplingRate {\r
+\r
+       /**\r
+        * Sampling rate of 8 kHz\r
+        * \r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+       _8KHZ("8KHZ"),\r
+       /**\r
+        * Sampling rate of 16 kHz\r
+        * \r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+       _16KHZ("16KHZ"),\r
+       /**\r
+        * Sampling rate of 22 kHz\r
+        * \r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+       _22KHZ("22KHZ"),\r
+       /**\r
+        * Sampling rate of 44 kHz\r
+        * \r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+       _44KHZ("44KHZ");\r
+\r
+    String internalName;\r
+    \r
+    private SamplingRate(String internalName) {\r
+        this.internalName = internalName;\r
+    }\r
+    \r
+    public String toString() {\r
+        return this.internalName;\r
+    }\r
+    \r
+    public static SamplingRate valueForString(String value) {          \r
+       for (SamplingRate anEnum : EnumSet.allOf(SamplingRate.class)) {\r
+            if (anEnum.toString().equals(value)) {\r
+                return anEnum;\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+}\r
index 64d4d4c..b08f4d7 100755 (executable)
@@ -1,9 +1,6 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum SmartDeviceLinkConnectionState {
-       SMARTDEVICELINK_CONNECTED,
-       SMARTDEVICELINK_DISCONNECTED;
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+public enum SmartDeviceLinkConnectionState {\r
+       SMARTDEVICELINK_CONNECTED,\r
+       SMARTDEVICELINK_DISCONNECTED;\r
+}\r
index 47abbcf..631cb0a 100755 (executable)
@@ -1,55 +1,51 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum SmartDeviceLinkDisconnectedReason {
-       USER_EXIT,
-    IGNITION_OFF,
-    BLUETOOTH_OFF,
-    USB_DISCONNECTED,
-    REQUEST_WHILE_IN_NONE_HMI_LEVEL,
-    TOO_MANY_REQUESTS,
-    DRIVER_DISTRACTION_VIOLATION,
-    LANGUAGE_CHANGE,
-    MASTER_RESET,
-    FACTORY_DEFAULTS,
-    HEARTBEAT_PAST_DUE,
-    TRANSPORT_ERROR,
-    APPLICATION_REQUESTED_DISCONNECT,
-    DEFAULT;
-       
-       public static SmartDeviceLinkDisconnectedReason valueForString(String value) {
-        return valueOf(value);
-    }
-       
-       public static SmartDeviceLinkDisconnectedReason convertAppInterfaceUnregisteredReason(AppInterfaceUnregisteredReason reason) {
-               
-               SmartDeviceLinkDisconnectedReason returnReason = SmartDeviceLinkDisconnectedReason.DEFAULT;
-               
-               switch(reason) {
-                       case USER_EXIT:
-                               returnReason = SmartDeviceLinkDisconnectedReason.USER_EXIT;
-                       case IGNITION_OFF:
-                               returnReason = SmartDeviceLinkDisconnectedReason.IGNITION_OFF;
-                       case BLUETOOTH_OFF:
-                               returnReason = SmartDeviceLinkDisconnectedReason.BLUETOOTH_OFF;
-                       case USB_DISCONNECTED:
-                               returnReason = SmartDeviceLinkDisconnectedReason.USB_DISCONNECTED;
-                       case REQUEST_WHILE_IN_NONE_HMI_LEVEL:
-                               returnReason = SmartDeviceLinkDisconnectedReason.REQUEST_WHILE_IN_NONE_HMI_LEVEL;
-                       case TOO_MANY_REQUESTS:
-                               returnReason = SmartDeviceLinkDisconnectedReason.TOO_MANY_REQUESTS;
-                       case DRIVER_DISTRACTION_VIOLATION:
-                               returnReason = SmartDeviceLinkDisconnectedReason.DRIVER_DISTRACTION_VIOLATION;
-                       case LANGUAGE_CHANGE:
-                               returnReason = SmartDeviceLinkDisconnectedReason.LANGUAGE_CHANGE;
-                       case MASTER_RESET:
-                               returnReason = SmartDeviceLinkDisconnectedReason.MASTER_RESET;
-                       case FACTORY_DEFAULTS:
-                               returnReason = SmartDeviceLinkDisconnectedReason.FACTORY_DEFAULTS;
-               }
-               
-               return returnReason;
-       }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+public enum SmartDeviceLinkDisconnectedReason {\r
+       USER_EXIT,\r
+    IGNITION_OFF,\r
+    BLUETOOTH_OFF,\r
+    USB_DISCONNECTED,\r
+    REQUEST_WHILE_IN_NONE_HMI_LEVEL,\r
+    TOO_MANY_REQUESTS,\r
+    DRIVER_DISTRACTION_VIOLATION,\r
+    LANGUAGE_CHANGE,\r
+    MASTER_RESET,\r
+    FACTORY_DEFAULTS,\r
+    TRANSPORT_ERROR,\r
+    APPLICATION_REQUESTED_DISCONNECT,\r
+    DEFAULT;\r
+       \r
+       public static SmartDeviceLinkDisconnectedReason valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+       \r
+       public static SmartDeviceLinkDisconnectedReason convertAppInterfaceUnregisteredReason(AppInterfaceUnregisteredReason reason) {\r
+               \r
+               SmartDeviceLinkDisconnectedReason returnReason = SmartDeviceLinkDisconnectedReason.DEFAULT;\r
+               \r
+               switch(reason) {\r
+                       case USER_EXIT:\r
+                               returnReason = SmartDeviceLinkDisconnectedReason.USER_EXIT;\r
+                       case IGNITION_OFF:\r
+                               returnReason = SmartDeviceLinkDisconnectedReason.IGNITION_OFF;\r
+                       case BLUETOOTH_OFF:\r
+                               returnReason = SmartDeviceLinkDisconnectedReason.BLUETOOTH_OFF;\r
+                       case USB_DISCONNECTED:\r
+                               returnReason = SmartDeviceLinkDisconnectedReason.USB_DISCONNECTED;\r
+                       case REQUEST_WHILE_IN_NONE_HMI_LEVEL:\r
+                               returnReason = SmartDeviceLinkDisconnectedReason.REQUEST_WHILE_IN_NONE_HMI_LEVEL;\r
+                       case TOO_MANY_REQUESTS:\r
+                               returnReason = SmartDeviceLinkDisconnectedReason.TOO_MANY_REQUESTS;\r
+                       case DRIVER_DISTRACTION_VIOLATION:\r
+                               returnReason = SmartDeviceLinkDisconnectedReason.DRIVER_DISTRACTION_VIOLATION;\r
+                       case LANGUAGE_CHANGE:\r
+                               returnReason = SmartDeviceLinkDisconnectedReason.LANGUAGE_CHANGE;\r
+                       case MASTER_RESET:\r
+                               returnReason = SmartDeviceLinkDisconnectedReason.MASTER_RESET;\r
+                       case FACTORY_DEFAULTS:\r
+                               returnReason = SmartDeviceLinkDisconnectedReason.FACTORY_DEFAULTS;\r
+               }\r
+               \r
+               return returnReason;\r
+       }\r
+}\r
index d50e84c..0001365 100755 (executable)
@@ -1,9 +1,6 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum SmartDeviceLinkInterfaceAvailability {
-       SMARTDEVICELINK_INTERFACE_AVAILABLE,
-       SMARTDEVICELINK_INTERFACE_UNAVAILABLE;
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+public enum SmartDeviceLinkInterfaceAvailability {\r
+       SMARTDEVICELINK_INTERFACE_AVAILABLE,\r
+       SMARTDEVICELINK_INTERFACE_UNAVAILABLE;\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/SoftButtonType.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/SoftButtonType.java
new file mode 100755 (executable)
index 0000000..74d66cc
--- /dev/null
@@ -0,0 +1,28 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+import java.util.EnumSet;\r
+\r
+public enum SoftButtonType {\r
+       SBT_TEXT("TEXT"),\r
+       SBT_IMAGE("IMAGE"),\r
+       SBT_BOTH("BOTH");\r
+\r
+    String internalName;\r
+    \r
+    private SoftButtonType(String internalName) {\r
+        this.internalName = internalName;\r
+    }\r
+    \r
+    public String toString() {\r
+        return this.internalName;\r
+    }\r
+    \r
+    public static SoftButtonType valueForString(String value) {        \r
+       for (SoftButtonType anEnum : EnumSet.allOf(SoftButtonType.class)) {\r
+            if (anEnum.toString().equals(value)) {\r
+                return anEnum;\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+}\r
index f47f285..f5acc88 100755 (executable)
@@ -1,16 +1,22 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum SpeechCapabilities {
-    TEXT,
-    SAPI_PHONEMES,
-    LHPLUS_PHONEMES,
-    PRE_RECORDED,
-    SILENCE;
-
-    public static SpeechCapabilities valueForString(String value) {
-        return valueOf(value);
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+/**\r
+ * Contains information about TTS capabilities on the SMARTDEVICELINK platform.\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public enum SpeechCapabilities {\r
+       /**\r
+        * The SMARTDEVICELINK platform can speak text phrases.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */     \r
+    TEXT,\r
+    SAPI_PHONEMES,\r
+    LHPLUS_PHONEMES,\r
+    PRE_RECORDED,\r
+    SILENCE;\r
+\r
+    public static SpeechCapabilities valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/SystemAction.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/SystemAction.java
new file mode 100755 (executable)
index 0000000..abda20e
--- /dev/null
@@ -0,0 +1,11 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+public enum SystemAction {\r
+       DEFAULT_ACTION,\r
+       STEAL_FOCUS,\r
+       KEEP_CONTEXT;\r
+\r
+    public static SystemAction valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
index b2619a7..800c0b6 100755 (executable)
@@ -1,31 +1,63 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-import java.util.EnumSet;
-
-public enum SystemContext {
-    SYSCTXT_MAIN("MAIN"),
-    SYSCTXT_VRSESSION("VRSESSION"),
-    SYSCTXT_MENU("MENU");
-
-    String internalName;
-    
-    private SystemContext(String internalName) {
-        this.internalName = internalName;
-    }
-    
-    public String toString() {
-        return this.internalName;
-    }
-    
-    public static SystemContext valueForString(String value) {
-        for (SystemContext anEnum : EnumSet.allOf(SystemContext.class)) {
-            if (anEnum.toString().equals(value)) {
-                return anEnum;
-            }
-        }
-        return null;
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+import java.util.EnumSet;\r
+\r
+/**\r
+ * Indicates whether or not a user-initiated interaction is in progress, and if\r
+ * so, in what mode (i.e. MENU or VR).\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public enum SystemContext {\r
+       /**\r
+        * No user interaction (user-initiated or app-initiated) is in progress.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       SYSCTXT_MAIN("MAIN"),\r
+       /**\r
+        * VR-oriented, user-initiated or app-initiated interaction is in-progress.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       SYSCTXT_VRSESSION("VRSESSION"),\r
+       /**\r
+        * Menu-oriented, user-initiated or app-initiated interaction is\r
+        * in-progress.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */\r
+       SYSCTXT_MENU("MENU"),\r
+       /**\r
+        * The app's display HMI is currently being obscured by either a system or\r
+        * other app's overlay.\r
+        * \r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+       SYSCTXT_HMI_OBSCURED("HMI_OBSCURED"),\r
+       /**\r
+        * Broadcast only to whichever app has an alert currently being displayed.\r
+        * \r
+        * @since SmartDeviceLink 2.0\r
+        */\r
+       SYSCTXT_ALERT("ALERT");\r
+\r
+    String internalName;\r
+    \r
+    private SystemContext(String internalName) {\r
+        this.internalName = internalName;\r
+    }\r
+    \r
+    public String toString() {\r
+        return this.internalName;\r
+    }\r
+    \r
+    public static SystemContext valueForString(String value) {\r
+        for (SystemContext anEnum : EnumSet.allOf(SystemContext.class)) {\r
+            if (anEnum.toString().equals(value)) {\r
+                return anEnum;\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+}\r
index eb818d7..a3d070b 100755 (executable)
@@ -1,18 +1,30 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum TBTState {
-       ROUTE_CANCELLED,
-       DESTINATION_REACHED,
-       ROUTE_UPDATE_MANUAL,
-       OFF_ROUTE_UPDATE,
-       OFF_ROUTE_DECLINED,
-       ROUTE_ACCEPTED, 
-       ROUTE_REFUSED;
-
-    public static TBTState valueForString(String value) {
-        return valueOf(value);
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Describes possible states of turn-by-turn module.\r
+ * @since  SmartDeviceLink 1.0\r
+ */\r
+public enum TBTState {\r
+       /**\r
+        * Indicates that driver requested a route update.\r
+        */\r
+       ROUTE_UPDATE_REQUEST,\r
+    ROUTE_ACCEPTED,\r
+    ROUTE_REFUSED,\r
+    ROUTE_CANCELLED,\r
+    ETA_REQUEST,\r
+    NEXT_TURN_REQUEST,\r
+    ROUTE_STATUS_REQUEST,\r
+    ROUTE_SUMMARY_REQUEST,\r
+    TRIP_STATUS_REQUEST,\r
+    ROUTE_UPDATE_REQUEST_TIMEOUT;
+\r
+    /**\r
+     * Convert String to TBTState\r
+     * @param value String\r
+     * @return TBTState\r
+     */\r
+    public static TBTState valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
index 6ed7208..9c301f7 100755 (executable)
@@ -1,14 +1,29 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum TextAlignment {
-    LEFT_ALIGNED,
-    RIGHT_ALIGNED,
-    CENTERED;
-
-    public static TextAlignment valueForString(String value) {
-        return valueOf(value);
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * The list of possible alignments of text in a field.\r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public enum TextAlignment {\r
+       /**\r
+        * Text aligned left.\r
+        */\r
+    LEFT_ALIGNED,\r
+    /**\r
+     * Text aligned right.\r
+     */\r
+    RIGHT_ALIGNED,\r
+    /**\r
+     * Text aligned centered.\r
+     */\r
+    CENTERED;\r
+\r
+    /**\r
+     * Convert String to TextAlignment\r
+     * @param value String\r
+     * @return TextAlignment\r
+     */\r
+    public static TextAlignment valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
index 6667089..98a62e5 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum TextFieldName {
-    mainField1,
-    mainField2,
-    statusBar,
-    mediaClock,
-    mediaTrack,
-    alertText1,
-    alertText2;
-
-    public static TextFieldName valueForString(String value) {
-        return valueOf(value);
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Names of the text fields that can appear on a SMARTDEVICELINK display.\r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public enum TextFieldName {\r
+       /**\r
+        * The first line of the first set of main fields of the persistent display. Applies to {@linkplain com.smartdevicelink.proxy.rpc.Show}.\r
+        */\r
+       mainField1,\r
+    /**\r
+     * The second line of the first set of main fields of the persistent display. Applies to {@linkplain com.smartdevicelink.proxy.rpc.Show}.\r
+     */        \r
+    mainField2,\r
+    /**\r
+     * The first line of the second set of main fields of the persistent display. Applies to {@linkplain com.smartdevicelink.proxy.rpc.Show}.\r
+     * @since SmartDeviceLink 2.0\r
+     */\r
+    mainField3,\r
+    /**\r
+     * The second line of the second set of main fields of the persistent display. Applies to {@linkplain com.smartdevicelink.proxy.rpc.Show}.\r
+     * @since SmartDeviceLink 2.0\r
+     */    \r
+    mainField4,\r
+    /**\r
+     * The status bar on the NGN display. Applies to {@linkplain com.smartdevicelink.proxy.rpc.Show}.\r
+     */    \r
+    statusBar,\r
+    /**\r
+     * Text value for MediaClock field. Must be properly formatted according to MediaClockFormat. Applies to {@linkplain com.smartdevicelink.proxy.rpc.Show}.\r
+        * <p>This field is commonly used to show elapsed or remaining time in an audio track or audio capture\r
+     */    \r
+    mediaClock,\r
+    /**\r
+     * The track field of NGN type ACMs. This field is only available for media applications on a NGN display. Applies to {@linkplain com.smartdevicelink.proxy.rpc.Show}.\r
+        * <p>This field is commonly used to show the current track number\r
+     */    \r
+    mediaTrack,\r
+    /**\r
+     * The first line of the alert text field. Applies to {@linkplain com.smartdevicelink.proxy.rpc.Alert}.\r
+     */\r
+    alertText1,\r
+    /**\r
+     * The second line of the alert text field. Applies to {@linkplain com.smartdevicelink.proxy.rpc.Alert}.\r
+     */\r
+    alertText2,\r
+    /**\r
+     * The third line of the alert text field. Applies to {@linkplain com.smartdevicelink.proxy.rpc.Alert}.\r
+     * @since SmartDeviceLink 2.0\r
+     */\r
+    alertText3,\r
+    /**\r
+     * Long form body of text that can include newlines and tabs. Applies to ScrollableMessage TBD\r
+     * @since SmartDeviceLink 2.0\r
+     */\r
+    scrollableMessageBody,\r
+    /**\r
+     * First line suggestion for a user response (in the case of VR enabled interaction).\r
+     * @since SmartDeviceLink 2.0\r
+     */\r
+    initialInteractionText,\r
+    /**\r
+     * First line of navigation text.\r
+     * @since SmartDeviceLink 2.0\r
+     */\r
+    navigationText1,\r
+    /**\r
+     * Second  line of navigation text.\r
+     * @since SmartDeviceLink 2.0\r
+     */\r
+    navigationText2,\r
+    /**\r
+     * Estimated Time of Arrival time for navigation.\r
+     * @since SmartDeviceLink 2.0\r
+     */\r
+    ETA,\r
+    /**\r
+     * Total distance to destination for navigation.\r
+     * @since SmartDeviceLink 2.0\r
+     */\r
+    totalDistance,\r
+    /**\r
+     * First line of text for audio pass thru.\r
+     * @since SmartDeviceLink 2.0\r
+     */\r
+    audioPassThruDisplayText1,\r
+    /**\r
+     * Second line of text for audio pass thru.\r
+     * @since SmartDeviceLink 2.0\r
+     */\r
+    audioPassThruDisplayText2,\r
+    /**\r
+     * Header text for slider.\r
+     * @since SmartDeviceLink 2.0\r
+     */\r
+    sliderHeader,\r
+    /**\r
+     * Footer text for slider\r
+     * @since SmartDeviceLink 2.0\r
+     */\r
+    sliderFooter;\r
+    \r
+       /**\r
+     * Convert String to TextFieldName\r
+     * @param value String\r
+     * @return TextFieldName\r
+     */\r
+    public static TextFieldName valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/TirePressureTellTale.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/TirePressureTellTale.java
new file mode 100755 (executable)
index 0000000..3ab13f5
--- /dev/null
@@ -0,0 +1,11 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+public enum TirePressureTellTale {\r
+    OFF,\r
+    ON,\r
+    FLASH;\r
+\r
+    public static TirePressureTellTale valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
index 1d54282..1cbebcd 100755 (executable)
@@ -1,30 +1,41 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-import java.util.EnumSet;
-
-public enum TriggerSource {
-    TS_MENU("MENU"),
-    TS_VR("VR");
-
-    String internalName;
-    
-    private TriggerSource(String internalName) {
-        this.internalName = internalName;
-    }
-    
-    public String toString() {
-        return this.internalName;
-    }
-    
-    public static TriggerSource valueForString(String value) {
-        for (TriggerSource anEnum : EnumSet.allOf(TriggerSource.class)) {
-            if (anEnum.toString().equals(value)) {
-                return anEnum;
-            }
-        }
-        return null;
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+import java.util.EnumSet;\r
+\r
+/**\r
+ * Indicates whether choice/command was selected via VR or via a menu selection\r
+ * (using SEEKRIGHT/SEEKLEFT, TUNEUP, TUNEDOWN and OK buttons)\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ * \r
+ */\r
+public enum TriggerSource {\r
+       /**\r
+        * Selection made via menu (i.e. using SEEKRIGHT/SEEKLEFT, TUNEUP, TUNEDOWN\r
+        * and OK buttons)\r
+        */\r
+       TS_MENU("MENU"),\r
+       /**\r
+        * Selection made via VR session\r
+        */\r
+       TS_VR("VR");\r
+\r
+    String internalName;\r
+    \r
+    private TriggerSource(String internalName) {\r
+        this.internalName = internalName;\r
+    }\r
+    \r
+    public String toString() {\r
+        return this.internalName;\r
+    }\r
+    \r
+    public static TriggerSource valueForString(String value) {\r
+        for (TriggerSource anEnum : EnumSet.allOf(TriggerSource.class)) {\r
+            if (anEnum.toString().equals(value)) {\r
+                return anEnum;\r
+            }\r
+        }\r
+        return null;\r
+    }\r
+}\r
index 0938ef6..e4d001c 100755 (executable)
@@ -1,15 +1,38 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum UpdateMode {
-    COUNTUP,
-    COUNTDOWN,
-    PAUSE,
-    RESUME;
-
-    public static UpdateMode valueForString(String value) {
-        return valueOf(value);
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Specifies what function should be performed on the media clock/counter\r
+ * <p>\r
+ * \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public enum UpdateMode {\r
+       /**\r
+        * Starts the media clock timer counting upward, in increments of 1 second\r
+        */\r
+       COUNTUP,\r
+       /**\r
+        * Starts the media clock timer counting downward, in increments of 1 second\r
+        */\r
+       COUNTDOWN,\r
+       /**\r
+        * Pauses the media clock timer\r
+        */\r
+       PAUSE,\r
+       /**\r
+        * Resumes the media clock timer. The timer resumes counting in whatever\r
+        * mode was in effect before pausing (i.e. COUNTUP or COUNTDOWN)\r
+        */\r
+       RESUME,\r
+    CLEAR;\r
+\r
+       \r
+       /**\r
+        * Returns an UpdateMode value (COUNTUP, COUNTDOWN, PAUSE or RESUME)\r
+        * @param value a String\r
+        * @return UpdateMode -COUNTUP, COUNTDOWN, PAUSE or RESUME\r
+        */\r
+    public static UpdateMode valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/VehicleDataActiveStatus.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/VehicleDataActiveStatus.java
new file mode 100755 (executable)
index 0000000..922d5c4
--- /dev/null
@@ -0,0 +1,13 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+public enum VehicleDataActiveStatus {\r
+       INACTIVE_NOT_CONFIRMED,\r
+       INACTIVE_CONFIRMED,\r
+       ACTIVE_NOT_CONFIRMED,\r
+       ACTIVE_CONFIRMED,\r
+    FAULT;\r
+\r
+    public static VehicleDataActiveStatus valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/VehicleDataEventStatus.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/VehicleDataEventStatus.java
new file mode 100755 (executable)
index 0000000..25bac59
--- /dev/null
@@ -0,0 +1,28 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Reflects the status of a vehicle data event; e.g. a seat belt event status.\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public enum VehicleDataEventStatus {\r
+       /**\r
+        * No event available\r
+        */\r
+       NO_EVENT,\r
+       NO,\r
+       YES,\r
+       /**\r
+        * Vehicle data event is not support \r
+        */\r
+       NOT_SUPPORTED,\r
+       FAULT;\r
+\r
+    /**\r
+     * Convert String to VehicleDataEventStatus\r
+     * @param value String\r
+     * @return VehicleDataEventStatus\r
+     */        \r
+    public static VehicleDataEventStatus valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/VehicleDataNotificationStatus.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/VehicleDataNotificationStatus.java
new file mode 100755 (executable)
index 0000000..42a5d9f
--- /dev/null
@@ -0,0 +1,20 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Reflects the status of a vehicle data notification.\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public enum VehicleDataNotificationStatus {\r
+       NOT_SUPPORTED,\r
+       NORMAL,\r
+       ACTIVE;\r
+\r
+    /**\r
+     * Convert String to VehicleDataNotificationStatus\r
+     * @param value String\r
+     * @return VehicleDataNotificationStatus\r
+     */    \r
+    public static VehicleDataNotificationStatus valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/VehicleDataResultCode.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/VehicleDataResultCode.java
new file mode 100755 (executable)
index 0000000..ece04ea
--- /dev/null
@@ -0,0 +1,16 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+public enum VehicleDataResultCode {\r
+       SUCCESS,\r
+       DISALLOWED,\r
+       USER_DISALLOWED,\r
+       INVALID_ID,\r
+       VEHICLE_DATA_NOT_AVAILABLE,\r
+       DATA_ALREADY_SUBSCRIBED,\r
+       DATA_NOT_SUBSCRIBED,\r
+       IGNORED;\r
+\r
+    public static VehicleDataResultCode valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/VehicleDataStatus.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/VehicleDataStatus.java
new file mode 100755 (executable)
index 0000000..621b0ef
--- /dev/null
@@ -0,0 +1,24 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Reflects the status of a binary vehicle data item.\r
+ * @since SmartDeviceLink 2.0\r
+ *\r
+ */\r
+public enum VehicleDataStatus {\r
+       /**\r
+        * No data available\r
+        */\r
+       NO_DATA_EXISTS,\r
+    OFF,\r
+    ON;\r
+\r
+    /**\r
+     * Convert String to VehicleDataStatus\r
+     * @param value String\r
+     * @return VehicleDataStatus\r
+     */                \r
+    public static VehicleDataStatus valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/VehicleDataType.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/VehicleDataType.java
new file mode 100755 (executable)
index 0000000..d154807
--- /dev/null
@@ -0,0 +1,26 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Defines the vehicle data types that can be published and subscribed to\r
+ * \r
+ */\r
+public enum VehicleDataType {\r
+    VEHICLEDATA_SPEED,\r
+    VEHICLEDATA_RPM,\r
+    VEHICLEDATA_FUELLEVEL,\r
+    VEHICLEDATA_FUELLEVEL_STATE,\r
+    VEHICLEDATA_FUELCONSUMPTION,\r
+    VEHICLEDATA_EXTERNTEMP,\r
+    VEHICLEDATA_VIN,\r
+    VEHICLEDATA_PRNDL,\r
+    VEHICLEDATA_TIREPRESSURE,\r
+    VEHICLEDATA_ODOMETER,    \r
+    VEHICLEDATA_BELTSTATUS,\r
+    VEHICLEDATA_BODYINFO,\r
+    VEHICLEDATA_DEVICESTATUS,\r
+    VEHICLEDATA_BRAKING;\r
+\r
+    public static VehicleDataType valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
index 74fc25f..4db7bc3 100755 (executable)
@@ -1,12 +1,23 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.proxy.rpc.enums;
-
-public enum VrCapabilities {
-    Text;
-
-    public static VrCapabilities valueForString(String value) {
-        return valueOf(value);
-    }
-}
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * The VR capabilities of the connected SMARTDEVICELINK platform.\r
+ * \r
+ */\r
+public enum VrCapabilities {\r
+       /**\r
+        * The SMARTDEVICELINK platform is capable of recognizing spoken text in the current\r
+        * language.\r
+        * \r
+        * @since SmartDeviceLink 1.0\r
+        */   \r
+       Text;\r
+\r
+    public static VrCapabilities valueForString(String value) {\r
+        if (value.toUpperCase().equals(VrCapabilities.Text.toString().toUpperCase()))\r
+        {\r
+               return VrCapabilities.Text;\r
+        }\r
+        return null;\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/WarningLightStatus.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/WarningLightStatus.java
new file mode 100755 (executable)
index 0000000..f2170c0
--- /dev/null
@@ -0,0 +1,29 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+/**\r
+ * Reflects the status of a cluster instrument warning light.\r
+ * @since SmartDeviceLink 2.0\r
+ */\r
+public enum WarningLightStatus {\r
+       /**\r
+        * Warninglight Off\r
+        */\r
+       OFF,\r
+       /**\r
+        * Warninglight On\r
+        */\r
+       ON,\r
+       /**\r
+        * Warninglight is flashing\r
+        */\r
+       FLASH;\r
+\r
+    /**\r
+     * Convert String to WarningLightStatus\r
+     * @param value String\r
+     * @return WarningLightStatus\r
+     */    \r
+    public static WarningLightStatus valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/WiperStatus.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/enums/WiperStatus.java
new file mode 100755 (executable)
index 0000000..c3906b4
--- /dev/null
@@ -0,0 +1,23 @@
+package com.smartdevicelink.proxy.rpc.enums;\r
+\r
+public enum WiperStatus {\r
+       OFF,\r
+       AUTO_OFF,\r
+       OFF_MOVING,\r
+       MAN_INT_OFF,\r
+       MAN_INT_ON,\r
+       MAN_LOW,\r
+       MAN_HIGH,\r
+       MAN_FLICK,\r
+       WASH,\r
+       AUTO_LOW,\r
+       AUTO_HIGH,\r
+       COURTESYWIPE,\r
+       AUTO_ADJUST,\r
+       STALLED,\r
+       NO_DATA_EXISTS;\r
+\r
+    public static WiperStatus valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/smartdevicelinkMsgVersion.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/proxy/rpc/smartdevicelinkMsgVersion.java
new file mode 100755 (executable)
index 0000000..2a4a6d2
--- /dev/null
@@ -0,0 +1,104 @@
+package com.smartdevicelink.proxy.rpc;\r
+\r
+import java.util.Hashtable;\r
+\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+import com.smartdevicelink.proxy.constants.Names;\r
+\r
+/**\r
+ * Specifies the version number of the SMARTDEVICELINK V4 interface. This is used by both the application and SMARTDEVICELINK to declare what interface version each is using.\r
+ * <p><b> Parameter List\r
+ * <table border="1" rules="all">\r
+ *             <tr>\r
+ *                     <th>Name</th>\r
+ *                     <th>Type</th>\r
+ *                     <th>Description</th>\r
+ *                     <th>SmartDeviceLink Ver. Available</th>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>majorVersion</td>\r
+ *                     <td>Int16</td>\r
+ *                     <td>\r
+ *                                     <ul>\r
+ *                                     <li>minvalue="1"</li>\r
+ *                                 <li>maxvalue="10"</li>\r
+ *                                     </ul>\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ *             <tr>\r
+ *                     <td>minorVersion</td>\r
+ *                     <td>Int16</td>\r
+ *                     <td>\r
+ *                                     <ul>\r
+ *                                     <li>minvalue="0"</li>\r
+ *                                 <li>maxvalue="1000"</li>\r
+ *                                     </ul>\r
+ *                     </td>\r
+ *                     <td>SmartDeviceLink 1.0</td>\r
+ *             </tr>\r
+ * </table> \r
+ * @since SmartDeviceLink 1.0\r
+ */\r
+public class smartdevicelinkMsgVersion extends RPCStruct {\r
+\r
+       /**\r
+        * Constructs a newly allocated smartdevicelinkMsgVersion object\r
+        */\r
+       public smartdevicelinkMsgVersion() { }\r
+    /**\r
+     * Constructs a newly allocated smartdevicelinkMsgVersion object indicated by the Hashtable parameter\r
+     * @param hash The Hashtable to use\r
+     */    \r
+       public smartdevicelinkMsgVersion(Hashtable hash) {\r
+        super(hash);\r
+    }\r
+    /**\r
+     * Get major version\r
+     *                                         <ul>\r
+     *                                         <li>minvalue="1"</li>\r
+     *                                     <li>maxvalue="10"</li>\r
+     *                                 </ul>\r
+     * @return the major version\r
+     */        \r
+    public Integer getMajorVersion() {\r
+        return (Integer) store.get( Names.majorVersion );\r
+    }\r
+    /**\r
+     * Set major version\r
+     *                                         <ul>\r
+     *                                         <li>minvalue="1"</li>\r
+     *                                     <li>maxvalue="10"</li>\r
+     *                                 </ul>\r
+     * @param majorVersion minvalue="1" and maxvalue="10" \r
+     */    \r
+    public void setMajorVersion( Integer majorVersion ) {\r
+        if (majorVersion != null) {\r
+            store.put(Names.majorVersion, majorVersion );\r
+        }\r
+    }\r
+    /**\r
+     * Get minor version\r
+     *                                         <ul>\r
+     *                                         <li>minvalue="0"</li>\r
+     *                                     <li>maxvalue="1000"</li>\r
+     *                                 </ul>\r
+     * @return the minor version\r
+     */    \r
+    public Integer getMinorVersion() {\r
+        return (Integer) store.get( Names.minorVersion );\r
+    }\r
+    /**\r
+     * Set minor version\r
+     *                                         <ul>\r
+     *                                         <li>minvalue="0"</li>\r
+     *                                     <li>maxvalue="1000"</li>\r
+     *                                 </ul>\r
+     * @param minorVersion min: 0; max: 1000\r
+     */\r
+    public void setMinorVersion( Integer minorVersion ) {\r
+        if (minorVersion != null) {\r
+            store.put(Names.minorVersion, minorVersion );\r
+        }\r
+    }\r
+}
\ No newline at end of file
@@ -1,23 +1,20 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.syncConnection;
-
-import com.smartdevicelink.protocol.ProtocolMessage;
-import com.smartdevicelink.protocol.enums.SessionType;
-
-public interface ISmartDeviceLinkConnectionListener {
-       public void onTransportDisconnected(String info);
-       
-       public void onTransportError(String info, Exception e);
-       
-       public void onProtocolMessageReceived(ProtocolMessage msg);
-       
-       public void onProtocolSessionStarted(SessionType sessionType,
-                       byte sessionID, byte version, String correlationID);
-       
-       public void onProtocolSessionEnded(SessionType sessionType,
-                       byte sessionID, String correlationID);
-       
-       public void onProtocolError(String info, Exception e);
-}
+package com.smartdevicelink.smartDeviceLinkConnection;\r
+\r
+import com.smartdevicelink.protocol.ProtocolMessage;\r
+import com.smartdevicelink.protocol.enums.SessionType;\r
+\r
+public interface IsmartDeviceLinkConnectionListener {\r
+       public void onTransportDisconnected(String info);\r
+       \r
+       public void onTransportError(String info, Exception e);\r
+       \r
+       public void onProtocolMessageReceived(ProtocolMessage msg);\r
+       \r
+       public void onProtocolSessionStarted(SessionType sessionType,\r
+                       byte sessionID, byte version, String correlationID);\r
+       \r
+       public void onProtocolSessionEnded(SessionType sessionType,\r
+                       byte sessionID, String correlationID);\r
+       \r
+       public void onProtocolError(String info, Exception e);\r
+}\r
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.syncConnection;
-
-import com.smartdevicelink.exception.SmartDeviceLinkException;
-import com.smartdevicelink.protocol.AbstractProtocol;
-import com.smartdevicelink.protocol.IProtocolListener;
-import com.smartdevicelink.protocol.ProtocolMessage;
-import com.smartdevicelink.protocol.SmartDeviceLinkProtocol;
-import com.smartdevicelink.protocol.enums.SessionType;
-import com.smartdevicelink.transport.BTTransport;
-import com.smartdevicelink.transport.BaseTransportConfig;
-import com.smartdevicelink.transport.ITransportListener;
-import com.smartdevicelink.transport.SmartDeviceLinkTransport;
-import com.smartdevicelink.transport.TCPTransport;
-import com.smartdevicelink.transport.TCPTransportConfig;
-import com.smartdevicelink.transport.TransportType;
-
-public class SmartDeviceLinkConnection implements IProtocolListener, ITransportListener {
-
-       SmartDeviceLinkTransport _transport = null;
-       AbstractProtocol _protocol = null;
-       ISmartDeviceLinkConnectionListener _connectionListener = null;
-
-       // Thread safety locks
-       Object TRANSPORT_REFERENCE_LOCK = new Object();
-       Object PROTOCOL_REFERENCE_LOCK = new Object();
-       
-       public SmartDeviceLinkConnection(ISmartDeviceLinkConnectionListener listener, BaseTransportConfig transportConfig) {
-               _connectionListener = listener;
-               
-               // Initialize the transport
-               synchronized(TRANSPORT_REFERENCE_LOCK) {
-                       // Ensure transport is null
-                       if (_transport != null) {
-                               if (_transport.getIsConnected()) {
-                                       _transport.disconnect();
-                               }
-                               _transport = null;
-                       }
-                       
-                       if (transportConfig.getTransportType() == TransportType.BLUETOOTH)
-                       {
-                               _transport = new BTTransport(this);     
-                       }
-                       else if (transportConfig.getTransportType() == TransportType.TCP)
-                       {
-                _transport = new TCPTransport((TCPTransportConfig) transportConfig, this);
-            }
-               }
-               
-               // Initialize the protocol
-               synchronized(PROTOCOL_REFERENCE_LOCK) {
-                       // Ensure protocol is null
-                       if (_protocol != null) {
-                               _protocol = null;
-                       }
-                       
-                       _protocol = new SmartDeviceLinkProtocol(this);
-               }
-       }
-       
-       public void closeConnection(byte rpcSessionID) {
-               synchronized(PROTOCOL_REFERENCE_LOCK) {
-                       if (_protocol != null) {
-                               // If transport is still connected, sent EndProtocolSessionMessage
-                               if (_transport != null && _transport.getIsConnected()) {
-                                       _protocol.EndProtocolSession(SessionType.RPC, rpcSessionID);
-                               }
-                               _protocol = null;
-                       } // end-if
-               }
-               
-               synchronized (TRANSPORT_REFERENCE_LOCK) {
-                       if (_transport != null) {
-                               _transport.disconnect();
-                       }
-                       _transport = null;
-               }
-       }
-       
-       public void startTransport() throws SmartDeviceLinkException {
-               _transport.openConnection();
-       }
-       
-       public Boolean getIsConnected() {
-               
-               // If _transport is null, then it can't be connected
-               if (_transport == null) {
-                       return false;
-               }
-               
-               return _transport.getIsConnected();
-       }
-       
-       public void sendMessage(ProtocolMessage msg) {
-               _protocol.SendMessage(msg);
-       }
-       
-       @Override
-       public void onTransportBytesReceived(byte[] receivedBytes,
-                       int receivedBytesLength) {
-               // Send bytes to protocol to be interpreted 
-               synchronized(PROTOCOL_REFERENCE_LOCK) {
-                       if (_protocol != null) {
-                               _protocol.HandleReceivedBytes(receivedBytes, receivedBytesLength);
-                       }
-               }
-       }
-
-       @Override
-       public void onTransportConnected() {
-               synchronized(PROTOCOL_REFERENCE_LOCK){
-                       if(_protocol != null){
-                               _protocol.StartProtocolSession(SessionType.RPC);
-                       }
-               }
-       }
-
-       @Override
-       public void onTransportDisconnected(String info) {
-               // Pass directly to connection listener
-               _connectionListener.onTransportDisconnected(info);
-       }
-
-       @Override
-       public void onTransportError(String info, Exception e) {
-               // Pass directly to connection listener
-               _connectionListener.onTransportError(info, e);
-       }
-
-       @Override
-       public void onProtocolMessageBytesToSend(byte[] msgBytes, int offset,
-                       int length) {
-               // Protocol has packaged bytes to send, pass to transport for transmission 
-               synchronized(TRANSPORT_REFERENCE_LOCK) {
-                       if (_transport != null) {
-                               _transport.sendBytes(msgBytes, offset, length);
-                       }
-               }
-       }
-
-       @Override
-       public void onProtocolMessageReceived(ProtocolMessage msg) {
-               _connectionListener.onProtocolMessageReceived(msg);
-       }
-
-       @Override
-       public void onProtocolSessionStarted(SessionType sessionType,
-                       byte sessionID, byte version, String correlationID) {
-               _connectionListener.onProtocolSessionStarted(sessionType, sessionID, version, correlationID);
-       }
-
-       @Override
-       public void onProtocolSessionEnded(SessionType sessionType, byte sessionID,
-                       String correlationID) {
-               _connectionListener.onProtocolSessionEnded(sessionType, sessionID, correlationID);
-       }
-
-       @Override
-       public void onProtocolError(String info, Exception e) {
-               _connectionListener.onProtocolError(info, e);
-       }
-       
-       public TransportType getCurrentTransportType() {
-               return _transport.getTransportType();
-       }
-}
+package com.smartdevicelink.smartDeviceLinkConnection;\r
+\r
+\r
+import com.smartdevicelink.exception.SmartDeviceLinkException;\r
+import com.smartdevicelink.protocol.AbstractProtocol;\r
+import com.smartdevicelink.protocol.IProtocolListener;\r
+import com.smartdevicelink.protocol.ProtocolMessage;\r
+import com.smartdevicelink.protocol.SmartDeviceLinkProtocol;\r
+import com.smartdevicelink.protocol.enums.SessionType;\r
+import com.smartdevicelink.transport.*;\r
+\r
+public class smartDeviceLinkConnection implements IProtocolListener, ITransportListener {\r
+\r
+       SmartDeviceLinkTransport _transport = null;\r
+       AbstractProtocol _protocol = null;\r
+       IsmartDeviceLinkConnectionListener _connectionListener = null;\r
+\r
+       // Thread safety locks\r
+       Object TRANSPORT_REFERENCE_LOCK = new Object();\r
+       Object PROTOCOL_REFERENCE_LOCK = new Object();\r
+       \r
+       /**\r
+        * Constructor.\r
+        * \r
+        * @param listener SmartDeviceLink connection listener.\r
+        * @param transportConfig Transport configuration for this connection.\r
+        */\r
+       public smartDeviceLinkConnection(IsmartDeviceLinkConnectionListener listener, BaseTransportConfig transportConfig) {\r
+               _connectionListener = listener;\r
+               \r
+               // Initialize the transport\r
+               synchronized(TRANSPORT_REFERENCE_LOCK) {\r
+                       // Ensure transport is null\r
+                       if (_transport != null) {\r
+                               if (_transport.getIsConnected()) {\r
+                                       _transport.disconnect();\r
+                               }\r
+                               _transport = null;\r
+                       }\r
+                       \r
+                       if (transportConfig.getTransportType() == TransportType.BLUETOOTH)\r
+                       {\r
+                               _transport = new BTTransport(this);     \r
+                       }\r
+                       else if (transportConfig.getTransportType() == TransportType.TCP)\r
+                       {\r
+                _transport = new TCPTransport((TCPTransportConfig) transportConfig, this);\r
+            }\r
+               }\r
+               \r
+               // Initialize the protocol\r
+               synchronized(PROTOCOL_REFERENCE_LOCK) {\r
+                       // Ensure protocol is null\r
+                       if (_protocol != null) {\r
+                               _protocol = null;\r
+                       }\r
+                       \r
+                       _protocol = new SmartDeviceLinkProtocol(this);\r
+               }\r
+       }\r
+       \r
+       public AbstractProtocol getSmartDeviceLinkProtocolProtocol(){\r
+               return _protocol;\r
+       }\r
+       \r
+       public void closeConnection(byte rpcSessionID) {\r
+               synchronized(PROTOCOL_REFERENCE_LOCK) {\r
+                       if (_protocol != null) {\r
+                               // If transport is still connected, sent EndProtocolSessionMessage\r
+                               if (_transport != null && _transport.getIsConnected()) {\r
+                                       _protocol.EndProtocolSession(SessionType.RPC, rpcSessionID);\r
+                               }\r
+                               _protocol = null;\r
+                       } // end-if\r
+               }\r
+               \r
+               synchronized (TRANSPORT_REFERENCE_LOCK) {\r
+                       if (_transport != null) {\r
+                               _transport.disconnect();\r
+                       }\r
+                       _transport = null;\r
+               }\r
+       }\r
+       \r
+       public void startTransport() throws SmartDeviceLinkException {\r
+               _transport.openConnection();\r
+       }\r
+       \r
+       public Boolean getIsConnected() {\r
+               \r
+               // If _transport is null, then it can't be connected\r
+               if (_transport == null) {\r
+                       return false;\r
+               }\r
+               \r
+               return _transport.getIsConnected();\r
+       }\r
+       \r
+       public void sendMessage(ProtocolMessage msg) {\r
+               _protocol.SendMessage(msg);\r
+       }\r
+       \r
+       @Override\r
+       public void onTransportBytesReceived(byte[] receivedBytes,\r
+                       int receivedBytesLength) {\r
+               // Send bytes to protocol to be interpreted \r
+               synchronized(PROTOCOL_REFERENCE_LOCK) {\r
+                       if (_protocol != null) {\r
+                               _protocol.HandleReceivedBytes(receivedBytes, receivedBytesLength);\r
+                       }\r
+               }\r
+       }\r
+\r
+       @Override\r
+       public void onTransportConnected() {\r
+               synchronized(PROTOCOL_REFERENCE_LOCK){\r
+                       if(_protocol != null){\r
+                               _protocol.StartProtocolSession(SessionType.RPC);                                \r
+                               }\r
+                       }\r
+       }\r
+       \r
+       @Override\r
+       public void onTransportDisconnected(String info) {\r
+               // Pass directly to connection listener\r
+               _connectionListener.onTransportDisconnected(info);\r
+       }\r
+\r
+       @Override\r
+       public void onTransportError(String info, Exception e) {\r
+               // Pass directly to connection listener\r
+               _connectionListener.onTransportError(info, e);\r
+       }\r
+\r
+       @Override\r
+       public void onProtocolMessageBytesToSend(byte[] msgBytes, int offset,\r
+                       int length) {\r
+               // Protocol has packaged bytes to send, pass to transport for transmission \r
+               synchronized(TRANSPORT_REFERENCE_LOCK) {\r
+                       if (_transport != null) {\r
+                               _transport.sendBytes(msgBytes, offset, length);\r
+                       }\r
+               }\r
+       }\r
+\r
+       @Override\r
+       public void onProtocolMessageReceived(ProtocolMessage msg) {\r
+               _connectionListener.onProtocolMessageReceived(msg);\r
+       }\r
+\r
+       @Override\r
+       public void onProtocolSessionStarted(SessionType sessionType,\r
+                       byte sessionID, byte version, String correlationID) {\r
+               _connectionListener.onProtocolSessionStarted(sessionType, sessionID, version, correlationID);\r
+       }\r
+\r
+       @Override\r
+       public void onProtocolSessionEnded(SessionType sessionType, byte sessionID,\r
+                       String correlationID) {\r
+               _connectionListener.onProtocolSessionEnded(sessionType, sessionID, correlationID);\r
+       }\r
+\r
+       @Override\r
+       public void onProtocolError(String info, Exception e) {\r
+               _connectionListener.onProtocolError(info, e);\r
+       }\r
+       \r
+       /**\r
+        * Gets type of transport currently used by this connection.\r
+        * \r
+        * @return One of TransportType enumeration values.\r
+        * \r
+        * @see TransportType\r
+        */\r
+       public TransportType getCurrentTransportType() {\r
+               return _transport.getTransportType();\r
+       }\r
+}\r
index f4b326e..b77b344 100755 (executable)
@@ -1,54 +1,52 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.trace;
-
-import com.smartdevicelink.trace.enums.DetailLevel;
-import com.smartdevicelink.trace.enums.Mod;
-
-public class DiagLevel {
-
-       static private DetailLevel[] levels;
-       
-       static {   // this is a static c-tor!!
-               levels = new DetailLevel[Mod.values().length];
-               setAllLevels(DetailLevel.OFF);
-       }
-       
-       public static void setAllLevels(DetailLevel thisDetail) {
-               for (int i=0; i < levels.length; i++) {
-                       levels[i] = thisDetail; //  
-               }
-       }
-       
-    public static void setLevel(Mod thisMod, DetailLevel thisDetail) {
-       levels[thisMod.ordinal()] = thisDetail;
-    }
-       
-       public static DetailLevel getLevel(Mod thisMod) {
-               return levels[thisMod.ordinal()];
-       }
-       
-       public static boolean isValidDetailLevel(String dtString) {
-               // Assume false
-               Boolean isValid = false;
-               
-               if (dtString.equalsIgnoreCase("verbose"))
-                       isValid = true;
-               else if (dtString.equalsIgnoreCase("terse"))
-                       isValid = true;
-               else if (dtString.equalsIgnoreCase("off"))
-                       isValid = true;
-               
-               return isValid;
-       }
-       
-       public static DetailLevel toDetailLevel(String dtString) {
-               DetailLevel dt = DetailLevel.OFF;
-               if (dtString.equalsIgnoreCase("verbose"))
-                       dt = DetailLevel.VERBOSE;
-               else if (dtString.equalsIgnoreCase("terse"))
-                       dt = DetailLevel.TERSE;
-               return dt;
-       }
-}
+package com.smartdevicelink.trace;\r
+\r
+import com.smartdevicelink.trace.enums.DetailLevel;\r
+import com.smartdevicelink.trace.enums.Mod;\r
+\r
+\r
+public class DiagLevel {\r
+\r
+       static private DetailLevel[] levels;\r
+       \r
+       static {   // this is a static c-tor!!\r
+               levels = new DetailLevel[Mod.values().length];\r
+               setAllLevels(DetailLevel.OFF);\r
+       }\r
+       \r
+       public static void setAllLevels(DetailLevel thisDetail) {\r
+               for (int i=0; i < levels.length; i++) {\r
+                       levels[i] = thisDetail; //  \r
+               }\r
+       }\r
+       \r
+    public static void setLevel(Mod thisMod, DetailLevel thisDetail) {\r
+       levels[thisMod.ordinal()] = thisDetail;\r
+    }\r
+       \r
+       public static DetailLevel getLevel(Mod thisMod) {\r
+               return levels[thisMod.ordinal()];\r
+       }\r
+       \r
+       public static boolean isValidDetailLevel(String dtString) {\r
+               // Assume false\r
+               Boolean isValid = false;\r
+               \r
+               if (dtString.equalsIgnoreCase("verbose"))\r
+                       isValid = true;\r
+               else if (dtString.equalsIgnoreCase("terse"))\r
+                       isValid = true;\r
+               else if (dtString.equalsIgnoreCase("off"))\r
+                       isValid = true;\r
+               \r
+               return isValid;\r
+       }\r
+       \r
+       public static DetailLevel toDetailLevel(String dtString) {\r
+               DetailLevel dt = DetailLevel.OFF;\r
+               if (dtString.equalsIgnoreCase("verbose"))\r
+                       dt = DetailLevel.VERBOSE;\r
+               else if (dtString.equalsIgnoreCase("terse"))\r
+                       dt = DetailLevel.TERSE;\r
+               return dt;\r
+       }\r
+}\r
index b4050d1..3af7d50 100755 (executable)
@@ -1,8 +1,5 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.trace;
-
-public interface ISTListener {
-       void logXmlMsg(String msg, String token);
-} // end-interface
+package com.smartdevicelink.trace;\r
+\r
+public interface ISTListener {\r
+       void logXmlMsg(String msg, String token);\r
+} // end-interface
\ No newline at end of file
index d2b28df..059d642 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.trace;
-
-public class Mime {
-       
-       private static String m_base64Chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
-       
-       public static String base64Encode(String str) {
-               String b64String = "";
-               try {
-                       byte[] strBytes = str.getBytes("US-ASCII");
-                       b64String = base64Encode(strBytes);
-               } catch (Exception ex) {
-                       // Don't care?
-               } // end-catch
-               return b64String;
-       } // end-method
-
-       public static String base64Encode(byte bytesToEncode[]) {
-               return base64Encode(bytesToEncode, 0, bytesToEncode.length);
-       } // end-method
-
-       public static String base64Encode(byte bytesToEncode[], int offset, int length) {
-               StringBuilder sb = new StringBuilder();
-
-               int             idxin = 0;
-               int             b64idx = 0;
-
-               for (idxin=offset;idxin < offset + length;idxin++) {
-                       switch ((idxin-offset) % 3) {
-                               case 0:
-                                       b64idx = (bytesToEncode[idxin] >> 2) & 0x3f;
-                                       break;
-                               case 1:
-                                       b64idx = (bytesToEncode[idxin] >> 4) & 0x0f;
-                                       b64idx |= ((bytesToEncode[idxin-1] << 4)& 0x30);
-                                       break;
-                               case 2:
-                                       b64idx = (bytesToEncode[idxin] >> 6) & 0x03;
-                                       b64idx |= ((bytesToEncode[idxin-1] << 2)& 0x3c);
-                                       sb.append(m_base64Chars.charAt(b64idx));
-                                       b64idx = bytesToEncode[idxin] & 0x3f;
-                                       break;
-                       } // end-switch
-                       sb.append(m_base64Chars.charAt(b64idx));
-               } // end-for
-
-               switch ((idxin-offset) % 3) {
-                       case 0:
-                               break;
-                       case 1:
-                               b64idx = (bytesToEncode[idxin-1] << 4) & 0x30;
-                               sb.append(m_base64Chars.charAt(b64idx));
-                               sb.append("==");
-                               break;
-                       case 2:
-                               b64idx = ((bytesToEncode[idxin-1] << 2)& 0x3c);
-                               sb.append(m_base64Chars.charAt(b64idx));
-                               sb.append('=');
-                               break;
-               } // end-switch
-               
-               return sb.toString();
-
-       } // end-method
-
-       private byte[] base64Decode(String base64String) {
-               byte[] outBytes = null;
-               byte[] base64ASCIIString = null;
-               final String ASCII_Encoding = "US-ASCII";
-               
-               // Convert b64 string to raw bytes
-               try {
-                       base64ASCIIString = base64String.getBytes(ASCII_Encoding);
-               } catch (Exception ex) {
-                       return null;
-               }
-               
-               if (!m_decodeInitComplete) {
-                       m_decodeInitComplete = true;
-                       initForDecode();
-               } // end-if
-
-               int     numInChars = base64ASCIIString.length;
-
-               if ((numInChars % 4) > 0) {
-                       return null;
-               } // end-if
-
-               int numOutBytes = base64ASCIIString.length / 4;
-               numOutBytes *= 3;
-               int     eqpos = base64String.indexOf("=");
-               if (eqpos >= 0) {
-                       numOutBytes--;
-                       if (base64String.substring(eqpos).indexOf("==") >= 0) {
-                               numOutBytes--;
-                       } // end-if
-               } // end-if
-               outBytes = new byte[numOutBytes];
-
-               byte    b64idxbits = 0x00;
-               int             iidx = 0, oidx = 0;
-               byte    writeByte = 0x00;
-               byte    b64ASCIIChar = 0x00;
-               for (iidx=0, oidx=0;iidx < numInChars;iidx++) {
-                       b64ASCIIChar = base64ASCIIString[iidx];
-                       if (b64ASCIIChar == 0x3d /*'='*/) {
-                               return outBytes;
-                       } // end-if
-
-                       if (!isb64char(b64ASCIIChar)) {
-                               return null;
-                       } // end-if
-
-                       switch (iidx % 4) {
-                               case 0:
-                                       break;
-                               case 1:
-                                       b64idxbits = b64decode[base64ASCIIString[iidx-1]];
-                                       writeByte = (byte)((b64idxbits << 2) | ((b64decode[b64ASCIIChar] >> 4) & 0x03));
-                                       outBytes[oidx++] = writeByte;
-                                       break;
-                               case 2:
-                                       b64idxbits = b64decode[base64ASCIIString[iidx-1]];
-                                       writeByte = (byte)(((b64idxbits << 4) & 0xf0) | ((b64decode[b64ASCIIChar] >> 2) & 0x0f));
-                                       outBytes[oidx++] = writeByte;
-                                       break;
-                               case 3:
-                                       b64idxbits = b64decode[base64ASCIIString[iidx-1]];
-                                       writeByte = (byte)(((b64idxbits << 6) & 0xc0) | ((b64decode[b64ASCIIChar]) & 0x3f));
-                                       outBytes[oidx++] = writeByte;
-                                       break;
-                       } // end-switch
-               } // end-for
-
-               return outBytes;
-
-       } // end-method
-
-
-       private static  byte[]  b64decode = new byte[256];
-       // A-Z is 0x41-0x5a
-       // a-z is 0x61-0x7a
-       // 0-9 is 0x30-0x39
-       // + is 0x2b
-       // / is 0x2f
-
-       private static  boolean m_decodeInitComplete = false;
-
-       private void initForDecode() {
-               int aidx = 0;
-               int lidx = 0;
-               // Set A-Z
-               for (aidx=0x41, lidx=0;aidx <= 0x5a;aidx++, lidx++) {
-                       b64decode[aidx] = (byte)lidx;
-               } // end-for
-               // Set a-z
-               for (aidx=0x61;aidx <= 0x7a;aidx++, lidx++) {
-                       b64decode[aidx] = (byte)lidx;
-               } // end-for
-               // Set 0-9
-               for (aidx=0x30;aidx <= 0x39;aidx++, lidx++) {
-                       b64decode[aidx] = (byte)lidx;
-               } // end-for
-               // Set '+'
-               b64decode[0x2b] = (byte)lidx++;
-               // Set '/'
-               b64decode[0x2f] = (byte)lidx++;
-       } // end-method
-
-       private boolean isb64char(byte b) {
-               // A-Z is 0x41-0x5a
-               // a-z is 0x61-0x7a
-               // 0-9 is 0x30-0x39
-               // + is 0x2b
-               // / is 0x2f
-               return (   (b >= 0x41 && b <= 0x5a)
-                       || (b >= 0x61 && b <= 0x7a)
-                       || (b >= 0x30 && b <= 0x39)
-                       || (b == 0x2b)
-                       || (b == 0x2f)
-                       );
-       } // end-method
-} // end-class
+package com.smartdevicelink.trace;\r
+\r
+// Borrowed from Dave Boll's infamous SmartDeviceLinkLinkRelay.java\r
+\r
+public class Mime {\r
+       \r
+       private static String m_base64Chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";\r
+       \r
+       public static String base64Encode(String str) {\r
+               String b64String = "";\r
+               try {\r
+                       byte[] strBytes = str.getBytes("US-ASCII");\r
+                       b64String = base64Encode(strBytes);\r
+               } catch (Exception ex) {\r
+                       // Don't care?\r
+               } // end-catch\r
+               return b64String;\r
+       } // end-method\r
+\r
+       public static String base64Encode(byte bytesToEncode[]) {\r
+               return base64Encode(bytesToEncode, 0, bytesToEncode.length);\r
+       } // end-method\r
+\r
+       public static String base64Encode(byte bytesToEncode[], int offset, int length) {\r
+               StringBuilder sb = new StringBuilder();\r
+\r
+               int             idxin = 0;\r
+               int             b64idx = 0;\r
+\r
+               for (idxin=offset;idxin < offset + length;idxin++) {\r
+                       switch ((idxin-offset) % 3) {\r
+                               case 0:\r
+                                       b64idx = (bytesToEncode[idxin] >> 2) & 0x3f;\r
+                                       break;\r
+                               case 1:\r
+                                       b64idx = (bytesToEncode[idxin] >> 4) & 0x0f;\r
+                                       b64idx |= ((bytesToEncode[idxin-1] << 4)& 0x30);\r
+                                       break;\r
+                               case 2:\r
+                                       b64idx = (bytesToEncode[idxin] >> 6) & 0x03;\r
+                                       b64idx |= ((bytesToEncode[idxin-1] << 2)& 0x3c);\r
+                                       sb.append(m_base64Chars.charAt(b64idx));\r
+                                       b64idx = bytesToEncode[idxin] & 0x3f;\r
+                                       break;\r
+                       } // end-switch\r
+                       sb.append(m_base64Chars.charAt(b64idx));\r
+               } // end-for\r
+\r
+               switch ((idxin-offset) % 3) {\r
+                       case 0:\r
+                               break;\r
+                       case 1:\r
+                               b64idx = (bytesToEncode[idxin-1] << 4) & 0x30;\r
+                               sb.append(m_base64Chars.charAt(b64idx));\r
+                               sb.append("==");\r
+                               break;\r
+                       case 2:\r
+                               b64idx = ((bytesToEncode[idxin-1] << 2)& 0x3c);\r
+                               sb.append(m_base64Chars.charAt(b64idx));\r
+                               sb.append('=');\r
+                               break;\r
+               } // end-switch\r
+               \r
+               return sb.toString();\r
+\r
+       } // end-method\r
+\r
+       private byte[] base64Decode(String base64String) {\r
+               byte[] outBytes = null;\r
+               byte[] base64ASCIIString = null;\r
+               final String ASCII_Encoding = "US-ASCII";\r
+               \r
+               // Convert b64 string to raw bytes\r
+               try {\r
+                       base64ASCIIString = base64String.getBytes(ASCII_Encoding);\r
+               } catch (Exception ex) {\r
+                       return null;\r
+               }\r
+               \r
+               if (!m_decodeInitComplete) {\r
+                       m_decodeInitComplete = true;\r
+                       initForDecode();\r
+               } // end-if\r
+\r
+               int     numInChars = base64ASCIIString.length;\r
+\r
+               if ((numInChars % 4) > 0) {\r
+                       return null;\r
+               } // end-if\r
+\r
+               int numOutBytes = base64ASCIIString.length / 4;\r
+               numOutBytes *= 3;\r
+               int     eqpos = base64String.indexOf("=");\r
+               if (eqpos >= 0) {\r
+                       numOutBytes--;\r
+                       if (base64String.substring(eqpos).indexOf("==") >= 0) {\r
+                               numOutBytes--;\r
+                       } // end-if\r
+               } // end-if\r
+               outBytes = new byte[numOutBytes];\r
+\r
+               byte    b64idxbits = 0x00;\r
+               int             iidx = 0, oidx = 0;\r
+               byte    writeByte = 0x00;\r
+               byte    b64ASCIIChar = 0x00;\r
+               for (iidx=0, oidx=0;iidx < numInChars;iidx++) {\r
+                       b64ASCIIChar = base64ASCIIString[iidx];\r
+                       if (b64ASCIIChar == 0x3d /*'='*/) {\r
+                               return outBytes;\r
+                       } // end-if\r
+\r
+                       if (!isb64char(b64ASCIIChar)) {\r
+                               return null;\r
+                       } // end-if\r
+\r
+                       switch (iidx % 4) {\r
+                               case 0:\r
+                                       break;\r
+                               case 1:\r
+                                       b64idxbits = b64decode[base64ASCIIString[iidx-1]];\r
+                                       writeByte = (byte)((b64idxbits << 2) | ((b64decode[b64ASCIIChar] >> 4) & 0x03));\r
+                                       outBytes[oidx++] = writeByte;\r
+                                       break;\r
+                               case 2:\r
+                                       b64idxbits = b64decode[base64ASCIIString[iidx-1]];\r
+                                       writeByte = (byte)(((b64idxbits << 4) & 0xf0) | ((b64decode[b64ASCIIChar] >> 2) & 0x0f));\r
+                                       outBytes[oidx++] = writeByte;\r
+                                       break;\r
+                               case 3:\r
+                                       b64idxbits = b64decode[base64ASCIIString[iidx-1]];\r
+                                       writeByte = (byte)(((b64idxbits << 6) & 0xc0) | ((b64decode[b64ASCIIChar]) & 0x3f));\r
+                                       outBytes[oidx++] = writeByte;\r
+                                       break;\r
+                       } // end-switch\r
+               } // end-for\r
+\r
+               return outBytes;\r
+\r
+       } // end-method\r
+\r
+\r
+       private static  byte[]  b64decode = new byte[256];\r
+       // A-Z is 0x41-0x5a\r
+       // a-z is 0x61-0x7a\r
+       // 0-9 is 0x30-0x39\r
+       // + is 0x2b\r
+       // / is 0x2f\r
+\r
+       private static  boolean m_decodeInitComplete = false;\r
+\r
+       private void initForDecode() {\r
+               int aidx = 0;\r
+               int lidx = 0;\r
+               // Set A-Z\r
+               for (aidx=0x41, lidx=0;aidx <= 0x5a;aidx++, lidx++) {\r
+                       b64decode[aidx] = (byte)lidx;\r
+               } // end-for\r
+               // Set a-z\r
+               for (aidx=0x61;aidx <= 0x7a;aidx++, lidx++) {\r
+                       b64decode[aidx] = (byte)lidx;\r
+               } // end-for\r
+               // Set 0-9\r
+               for (aidx=0x30;aidx <= 0x39;aidx++, lidx++) {\r
+                       b64decode[aidx] = (byte)lidx;\r
+               } // end-for\r
+               // Set '+'\r
+               b64decode[0x2b] = (byte)lidx++;\r
+               // Set '/'\r
+               b64decode[0x2f] = (byte)lidx++;\r
+       } // end-method\r
+\r
+       private boolean isb64char(byte b) {\r
+               // A-Z is 0x41-0x5a\r
+               // a-z is 0x61-0x7a\r
+               // 0-9 is 0x30-0x39\r
+               // + is 0x2b\r
+               // / is 0x2f\r
+               return (   (b >= 0x41 && b <= 0x5a)\r
+                       || (b >= 0x61 && b <= 0x7a)\r
+                       || (b >= 0x30 && b <= 0x39)\r
+                       || (b == 0x2b)\r
+                       || (b == 0x2f)\r
+                       );\r
+       } // end-method\r
+} // end-class
\ No newline at end of file
index 47ea747..507a136 100755 (executable)
@@ -1,88 +1,85 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.trace;
-
-import java.util.Hashtable;
-import java.util.Iterator;
-import java.util.Vector;
-
-import com.smartdevicelink.proxy.RPCMessage;
-import com.smartdevicelink.proxy.RPCStruct;
-
-class OpenRPCMessage extends RPCMessage {
-       private OpenRPCMessage() {super("");}
-       public OpenRPCMessage(RPCMessage rpcm) {
-               super(rpcm);
-       } // end-method
-
-       public OpenRPCMessage(RPCStruct rpcs) {
-               super(rpcs);
-       } // end-method
-
-       public String msgDump() {
-               StringBuilder pd = new StringBuilder();
-               
-               pd.append(this.getFunctionName() + " " + this.getMessageType());
-               
-               msgDump(pd);
-
-               return pd.toString();
-       } // end-method
-
-       public void msgDump(StringBuilder pd) {
-               pd.append("[");
-
-               dumpParams(parameters, pd);
-               
-               pd.append("]");
-
-               return;
-       } // end-method
-
-       private void dumpParams(Hashtable ht, StringBuilder pd) {
-               Iterator keySet = ht.keySet().iterator();
-               Object obj = null;
-               String key = "";
-               boolean isFirstParam = true;
-
-               while (keySet.hasNext()) {
-                       key = (String)keySet.next();
-                       obj = ht.get(key);
-                       if (isFirstParam) {
-                               isFirstParam = false;
-                       } else {
-                               pd.append(", ");
-                       } // end-if
-
-                       dumpParamNode(key, obj, pd);
-
-               } // end-while
-       } // end-method
-       
-       private void dumpParamNode(String key, Object obj, StringBuilder pd) {
-
-               if (obj instanceof Hashtable) {
-                       pd.append("[");
-                       dumpParams((Hashtable)obj, pd);
-                       pd.append("]");
-               } else if (obj instanceof RPCStruct) {
-                       pd.append("[");
-                       OpenRPCMessage orpcm = new OpenRPCMessage((RPCStruct)obj);
-                       orpcm.msgDump(pd);
-                       pd.append("]");
-               } else if (obj instanceof Vector) {
-                       pd.append("[");
-                       Vector vec = (Vector)obj;
-                       for (int idx=0;idx < vec.size();idx++) {
-                               if (idx > 0) {
-                                       pd.append(", ");
-                               }
-                               dumpParamNode(key, vec.elementAt(idx), pd);
-                       } // end-for
-                       pd.append("]");
-               } else {
-                       pd.append("\"" + key + "\" = \"" + obj.toString() + "\"");
-               }
-       } // end-method
-} // end-class OpenRPCMessage
+package com.smartdevicelink.trace;\r
+\r
+import java.util.Hashtable;\r
+import java.util.Iterator;\r
+import java.util.Vector;\r
+\r
+import com.smartdevicelink.proxy.RPCMessage;\r
+import com.smartdevicelink.proxy.RPCStruct;\r
+\r
+class OpenRPCMessage extends RPCMessage {\r
+       private OpenRPCMessage() {super("");}\r
+       public OpenRPCMessage(RPCMessage rpcm) {\r
+               super(rpcm);\r
+       } // end-method\r
+\r
+       public OpenRPCMessage(RPCStruct rpcs) {\r
+               super(rpcs);\r
+       } // end-method\r
+\r
+       public String msgDump() {\r
+               StringBuilder pd = new StringBuilder();\r
+               \r
+               pd.append(this.getFunctionName() + " " + this.getMessageType());\r
+               \r
+               msgDump(pd);\r
+\r
+               return pd.toString();\r
+       } // end-method\r
+\r
+       public void msgDump(StringBuilder pd) {\r
+               pd.append("[");\r
+\r
+               dumpParams(parameters, pd);\r
+               \r
+               pd.append("]");\r
+\r
+               return;\r
+       } // end-method\r
+\r
+       private void dumpParams(Hashtable ht, StringBuilder pd) {\r
+               Iterator keySet = ht.keySet().iterator();\r
+               Object obj = null;\r
+               String key = "";\r
+               boolean isFirstParam = true;\r
+\r
+               while (keySet.hasNext()) {\r
+                       key = (String)keySet.next();\r
+                       obj = ht.get(key);\r
+                       if (isFirstParam) {\r
+                               isFirstParam = false;\r
+                       } else {\r
+                               pd.append(", ");\r
+                       } // end-if\r
+\r
+                       dumpParamNode(key, obj, pd);\r
+\r
+               } // end-while\r
+       } // end-method\r
+       \r
+       private void dumpParamNode(String key, Object obj, StringBuilder pd) {\r
+\r
+               if (obj instanceof Hashtable) {\r
+                       pd.append("[");\r
+                       dumpParams((Hashtable)obj, pd);\r
+                       pd.append("]");\r
+               } else if (obj instanceof RPCStruct) {\r
+                       pd.append("[");\r
+                       OpenRPCMessage orpcm = new OpenRPCMessage((RPCStruct)obj);\r
+                       orpcm.msgDump(pd);\r
+                       pd.append("]");\r
+               } else if (obj instanceof Vector) {\r
+                       pd.append("[");\r
+                       Vector vec = (Vector)obj;\r
+                       for (int idx=0;idx < vec.size();idx++) {\r
+                               if (idx > 0) {\r
+                                       pd.append(", ");\r
+                               }\r
+                               dumpParamNode(key, vec.elementAt(idx), pd);\r
+                       } // end-for\r
+                       pd.append("]");\r
+               } else {\r
+                       pd.append("\"" + key + "\" = \"" + obj.toString() + "\"");\r
+               }\r
+       } // end-method\r
+} // end-class OpenRPCMessage\r
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.trace;
-
-import java.sql.Timestamp;
-
-import android.bluetooth.BluetoothDevice;
-import android.os.Build;
-import android.os.Debug;
-import android.os.Process;
-
-import com.smartdevicelink.protocol.ProtocolFrameHeader;
-import com.smartdevicelink.protocol.enums.FrameDataControlFrameType;
-import com.smartdevicelink.protocol.enums.FrameType;
-import com.smartdevicelink.protocol.enums.SessionType;
-import com.smartdevicelink.proxy.RPCMessage;
-import com.smartdevicelink.proxy.RPCRequest;
-import com.smartdevicelink.proxy.RPCResponse;
-import com.smartdevicelink.trace.enums.DetailLevel;
-import com.smartdevicelink.trace.enums.InterfaceActivityDirection;
-import com.smartdevicelink.trace.enums.Mod;
-import com.smartdevicelink.transport.SiphonServer;
-import com.smartdevicelink.util.BitConverter;
-import com.smartdevicelink.util.DebugTool;
-import com.smartdevicelink.util.NativeLogTool;
-
-/* This class handles the global TraceSettings as requested by the users either through the combination of the following
-   1. System defaults
-   2. Application XML config
-   3. Programmatic requests from application itself
-
-   It is manifested in the <SmartDeviceLink>...</SmartDeviceLink> tags
- */
-
-public class SyncTrace {
-       private static final String SmartDeviceLink_LIB_TRACE_KEY = "42baba60-eb57-11df-98cf-0800200c9a66";
-       
-       static boolean canWriteLogs = false;
-               
-       public static final String SYSTEM_LOG_TAG = "SyncTrace";
-       
-       private static long baseTics  = java.lang.System.currentTimeMillis();
-       private final static String KeyStr = SmartDeviceLink_LIB_TRACE_KEY;
-       private static boolean acceptAPITraceAdjustments = true;
-
-       protected static ISTListener m_appTraceListener = null;
-
-       ///
-       ///  The PUBLIC interface to SyncTrace starts here
-       ///
-
-
-       public static void setAcceptAPITraceAdjustments(Boolean APITraceAdjustmentsAccepted) {
-               if (APITraceAdjustmentsAccepted != null) {
-                       acceptAPITraceAdjustments = APITraceAdjustmentsAccepted;
-               }
-       }
-       
-       public static boolean getAcceptAPITraceAdjustments() {
-               return acceptAPITraceAdjustments;
-       }
-       
-       public static void setAppTraceListener(ISTListener listener) {
-               m_appTraceListener = listener;
-       } // end-method
-
-       public static void setTracingEnable(Boolean enable) {
-               if (enable != null) {
-                       canWriteLogs = enable;
-               }
-       } // end-method
-
-       public static void setAppTraceLevel(DetailLevel dt) {
-               if ( dt != null && acceptAPITraceAdjustments)
-                       DiagLevel.setLevel(Mod.app, dt);
-       } // end-method
-
-       public static void setProxyTraceLevel(DetailLevel dt) {
-               if (dt != null && acceptAPITraceAdjustments)
-                       DiagLevel.setLevel(Mod.proxy, dt);
-       } // end-method
-
-       public static void setRpcTraceLevel(DetailLevel dt) {
-               if (dt != null && acceptAPITraceAdjustments)
-                       DiagLevel.setLevel(Mod.rpc, dt);
-       } // end-method
-
-       public static void setMarshallingTraceLevel(DetailLevel dt) {
-               if (dt != null && acceptAPITraceAdjustments)
-                       DiagLevel.setLevel(Mod.mar, dt);
-       } // end-method
-
-       public static void setProtocolTraceLevel(DetailLevel dt) {
-               if (dt != null && acceptAPITraceAdjustments)
-                       DiagLevel.setLevel(Mod.proto, dt);
-       } // end-method
-
-       public static void setTransportTraceLevel(DetailLevel dt) {
-               if (dt != null && acceptAPITraceAdjustments)
-                               DiagLevel.setLevel(Mod.tran, dt);
-       } // end-method
-
-       private static String encodeTraceMessage(long timestamp, Mod module, InterfaceActivityDirection msgDirection, String msgBodyXml) {
-               StringBuilder sb = new StringBuilder("<msg><dms>");
-               sb.append(timestamp);
-               sb.append("</dms><pid>");
-               sb.append(Process.myPid());
-               sb.append("</pid><tid>");
-               sb.append(Thread.currentThread().getId());
-               sb.append("</tid><mod>");
-               sb.append(module.toString());
-               sb.append("</mod>");
-               if (msgDirection != InterfaceActivityDirection.None) {
-                       sb.append("<dir>");
-                       sb.append(interfaceActivityDirectionToString(msgDirection));
-                       sb.append("</dir>");
-               } // end-if
-               sb.append(msgBodyXml);
-               sb.append("</msg>");
-
-               return sb.toString();
-       } // end-method
-
-       private static String interfaceActivityDirectionToString(InterfaceActivityDirection iaDirection) {
-               String str = "";
-               switch (iaDirection) {
-                       case Receive:
-                               str = "rx";
-                               break;
-                       case Transmit:
-                               str = "tx";
-                               break;
-               } // end-switch
-               return str;
-       } // end-method
-
-       static String B64EncodeForXML(String data) {
-               return Mime.base64Encode(data);
-       } // end-method
-       
-       public static void logProxyEvent(String eventText, String token) {
-               if (DiagLevel.getLevel(Mod.proxy) == DetailLevel.OFF || !token.equals(KeyStr)) {
-                       return;
-               } // end-if
-
-               String msg = SyncTrace.B64EncodeForXML(eventText);
-               String xml = SyncTrace.encodeTraceMessage(SyncTrace.getBaseTicsDelta(), Mod.proxy, InterfaceActivityDirection.None, "<d>" + msg + "</d>");
-               writeXmlTraceMessage(xml);
-       } // end-method
-
-       public static void logAppEvent(String eventText) {
-               if (DiagLevel.getLevel(Mod.app) == DetailLevel.OFF) {
-                       return;
-               } // end-if
-
-               long timestamp = SyncTrace.getBaseTicsDelta();
-               String msg = SyncTrace.B64EncodeForXML(eventText);
-               String xml = SyncTrace.encodeTraceMessage(timestamp, Mod.app, InterfaceActivityDirection.None, "<d>" + msg + "</d>");
-               writeXmlTraceMessage(xml);
-       } // end-method
-
-       public static void logRPCEvent(InterfaceActivityDirection msgDirection, RPCMessage rpcMsg, String token) {
-               DetailLevel dl = DiagLevel.getLevel(Mod.rpc);
-               if (dl == DetailLevel.OFF || !token.equals(KeyStr)) {
-                       return;
-               } // end-if
-
-               long timestamp = SyncTrace.getBaseTicsDelta();
-               String xml = SyncTrace.encodeTraceMessage(timestamp, Mod.rpc, msgDirection, rpc2Xml(dl, rpcMsg));
-               writeXmlTraceMessage(xml);
-       } // end-method
-
-       private static String rpc2Xml(DetailLevel dl, RPCMessage rpcMsg) {
-               StringBuilder rpcAsXml = new StringBuilder();
-               rpcAsXml.append("<op>");
-               rpcAsXml.append(rpcMsg.getFunctionName());
-               rpcAsXml.append("</op>");
-               boolean hasCorrelationID = false;
-               Integer correlationID = -1;
-               if (rpcMsg instanceof RPCRequest) {
-                       hasCorrelationID = true;
-                       correlationID = ((RPCRequest)rpcMsg).getCorrelationID();
-               } else if (rpcMsg instanceof RPCResponse) {
-                       hasCorrelationID = true;
-                       correlationID = ((RPCResponse)rpcMsg).getCorrelationID();
-               } // end-if
-               if (hasCorrelationID) {
-                       rpcAsXml.append("<cid>");
-                       rpcAsXml.append(correlationID);
-                       rpcAsXml.append("</cid>");
-               } // end-if
-               rpcAsXml.append("<type>");
-               rpcAsXml.append(rpcMsg.getMessageType());
-               rpcAsXml.append("</type>");
-
-               if (dl == DetailLevel.VERBOSE) {
-                       OpenRPCMessage orpcmsg = new OpenRPCMessage(rpcMsg);
-                       String rpcParamList = orpcmsg.msgDump();
-                       String msg = SyncTrace.B64EncodeForXML(rpcParamList);
-                       rpcAsXml.append("<d>");
-                       rpcAsXml.append(msg);
-                       rpcAsXml.append("</d>");
-               } // end-if
-               return rpcAsXml.toString();
-       } // end-method
-
-       public static void logMarshallingEvent(InterfaceActivityDirection msgDirection, byte[] marshalledMessage, String token) {
-               DetailLevel dl = DiagLevel.getLevel(Mod.mar);
-               if (dl == DetailLevel.OFF || !token.equals(KeyStr)) {
-                       return;
-               } // end-fif
-
-               long timestamp = SyncTrace.getBaseTicsDelta();
-               StringBuilder msg = new StringBuilder();
-               msg.append("<sz>");
-               msg.append(marshalledMessage.length);
-               msg.append("</sz>");
-               if (dl == DetailLevel.VERBOSE) {
-                       msg.append("<d>");
-                       msg.append(Mime.base64Encode(marshalledMessage));
-                       msg.append("</d>");
-               } // end-if
-               String xml = SyncTrace.encodeTraceMessage(timestamp, Mod.mar, msgDirection, msg.toString());
-               writeXmlTraceMessage(xml);
-       } // end-method
-
-       public static void logProtocolEvent(InterfaceActivityDirection frameDirection, ProtocolFrameHeader frameHeader, byte[] frameData, int frameDataOffset, int frameDataLength, String token) {
-               DetailLevel dl = DiagLevel.getLevel(Mod.proto);
-               if (dl == DetailLevel.OFF || !token.equals(KeyStr)) {
-                       return;
-               } // end-if
-
-               StringBuffer protoMsg = new StringBuffer();
-               protoMsg.append("<frame>");
-               protoMsg.append(SyncTrace.getProtocolFrameHeaderInfo(frameHeader, frameData));
-               if (dl == DetailLevel.VERBOSE) {
-                       if (frameData != null && frameDataLength > 0) {
-                               protoMsg.append("<d>");
-                               String bytesInfo = "";
-                               bytesInfo = Mime.base64Encode(frameData, frameDataOffset, frameDataLength);
-                               protoMsg.append(bytesInfo);
-                               protoMsg.append("</d>");
-                       } // end-if
-               } // end-if
-               protoMsg.append("</frame>");
-               String xml = SyncTrace.encodeTraceMessage(SyncTrace.getBaseTicsDelta(), Mod.proto, frameDirection, protoMsg.toString());
-               writeXmlTraceMessage(xml);
-       } // end-method
-
-       private static String getProtocolFrameType(FrameType f) {
-               if (f == FrameType.Control)
-                       return "Control";
-               else if (f == FrameType.Consecutive)
-                       return "Consecutive";
-               else if (f == FrameType.First)
-                       return "First";
-               else if (f == FrameType.Single)
-                       return "Single";
-
-               return "Unknown";
-       } // end-method
-
-       private static String getProtocolSessionType(SessionType serviceType) {
-               String s;
-               if (serviceType == SessionType.RPC )
-                       s = "rpc";
-               else if (serviceType == SessionType.Bulk_Data)
-                       s = "bulk";
-               else
-                       s = "Unknown";
-               return s;
-       } // end-method
-
-       private static String getProtocolFrameHeaderInfo(ProtocolFrameHeader hdr, byte[] buf) {
-               StringBuilder sb = new StringBuilder();
-               sb.append("<hdr>");
-               sb.append("<ver>");
-               sb.append(hdr.getVersion());
-               sb.append("</ver><cmp>");
-               sb.append(hdr.isCompressed());
-               sb.append("</cmp><ft>");
-               sb.append(getProtocolFrameType(hdr.getFrameType()));
-               sb.append("</ft><st>");
-               sb.append(getProtocolSessionType(hdr.getSessionType()));
-               sb.append("</st><sid>");
-               sb.append(hdr.getSessionID());
-               sb.append("</sid><sz>");
-               sb.append(hdr.getDataSize());
-               sb.append("</sz>");
-
-               int frameData = hdr.getFrameData();
-               if (hdr.getFrameType() == FrameType.Control) {
-                       sb.append("<ca>");
-                       if (frameData == FrameDataControlFrameType.StartSession.getValue()) 
-                               sb.append("StartSession");
-                       else if (frameData == FrameDataControlFrameType.StartSessionACK.getValue())
-                               sb.append("StartSessionACK");
-                       else if (frameData == FrameDataControlFrameType.StartSessionNACK.getValue())
-                               sb.append("StartSessionNACK");
-                       else if (frameData == FrameDataControlFrameType.EndSession.getValue())
-                               sb.append("EndSession");
-                       sb.append("</ca>");
-               } else if (hdr.getFrameType() == FrameType.Consecutive ) {
-                       sb.append("<fsn>");
-                       if (frameData == 0 )
-                               sb.append("lastFrame");
-                       else
-                               sb.append(String.format("%02X",frameData)); 
-                       sb.append("</fsn>");
-               } else if (hdr.getFrameType() == FrameType.First ) {
-                       int totalSize = BitConverter.intFromByteArray(buf, 0);                  
-                       int numFrames = BitConverter.intFromByteArray(buf, 4);
-                       sb.append("<total>" + totalSize + "</total><numframes>" + numFrames + "</numframes>");
-               } else if (hdr.getFrameType() == FrameType.Single ) {
-                       sb.append("<single/>");
-               }
-
-               sb.append("</hdr>");
-
-               return sb.toString();
-       } // end-method
-
-       public static String getBTDeviceInfo(BluetoothDevice btDevice) {
-               StringBuilder sb = new StringBuilder();
-               sb.append("<btp>");
-               String btdn = btDevice.getName();
-               sb.append("<btn>");
-               sb.append(SyncTrace.B64EncodeForXML(btdn));
-               sb.append("</btn>");
-               sb.append("<bta>" + btDevice.getAddress() + "</bta>");
-               sb.append("<bts>" + btDevice.getBondState() + "</bts>");
-               sb.append("</btp>");
-               return sb.toString();
-       } // end-method
-
-       public static void logTransportEvent(String preamble, String transportSpecificInfoXml, InterfaceActivityDirection msgDirection, byte buf[], int byteLength, String token) {
-               logTransportEvent(preamble, transportSpecificInfoXml, msgDirection, buf, 0, byteLength, token);
-       } // end-method
-
-       private static void checkB64(String x, byte[] buf, int offset, int byteLength) {
-               if ((x.length() % 4) != 0) {
-                       NativeLogTool.logWarning(SyncTrace.SYSTEM_LOG_TAG, "b64 string length (" + x.length() + ") isn't multiple of 4: buf.length=" + buf.length + ", offset=" + offset + ", len=" + byteLength);
-               } // end-if
-       } // end-method
-
-       public static void logTransportEvent(String preamble, String transportSpecificInfoXml, InterfaceActivityDirection msgDirection, byte buf[], int offset, int byteLength, String token) {
-               if (DiagLevel.getLevel(Mod.tran) == DetailLevel.OFF || !token.equals(KeyStr)) {
-                       return;
-               } // end-if
-
-               StringBuilder msg = new StringBuilder();
-               if (transportSpecificInfoXml != null && transportSpecificInfoXml.length() > 0) {
-                       msg.append(transportSpecificInfoXml);
-               } // end-if
-               if (preamble != null && preamble.length() > 0) {
-                       msg.append("<desc>");
-                       msg.append(preamble);
-                       msg.append("</desc>");
-               } // end-if
-               if (buf != null) {
-                       msg.append("<sz>");
-                       msg.append(byteLength);
-                       msg.append("</sz>");
-                       DetailLevel dl = DiagLevel.getLevel(Mod.tran);
-                       if (dl == DetailLevel.VERBOSE) {
-                               if (buf != null && byteLength > 0) {
-                                       msg.append("<d>");
-                                       String bytesInfo = Mime.base64Encode(buf, offset, byteLength);
-                                       checkB64(bytesInfo, buf, offset, byteLength);
-                                       msg.append(bytesInfo);
-                                       msg.append("</d>");
-                               } // end-if
-                       } // end-if
-               } // end-if
-               String xml = SyncTrace.encodeTraceMessage(SyncTrace.getBaseTicsDelta(), Mod.tran, msgDirection, msg.toString());
-               writeXmlTraceMessage(xml);
-       } // end-method
-
-       // Package-scoped
-       static long getBaseTicsDelta() {
-               return java.lang.System.currentTimeMillis() - getBaseTics();
-       }
-
-       // Package-scoped
-       static long getBaseTics() {
-               return baseTics;
-       } // end-method
-
-       public static Boolean writeMessageToSiphonServer(String info) {
-               return SiphonServer.sendFormattedTraceMessage(info);
-       }
-
-       private static void writeXmlTraceMessage(String msg) {
-               try {                   
-                       // Attempt to write formatted message to the Siphon
-                       if (false == writeMessageToSiphonServer(msg)) {
-                               // If writing to the Siphon fails, write to the native log
-                               NativeLogTool.logInfo(SyncTrace.SYSTEM_LOG_TAG, msg);
-                       }
-                       
-                       ISTListener localTraceListener = m_appTraceListener;
-
-                       if (localTraceListener != null) {
-                               try {
-                                       localTraceListener.logXmlMsg(msg, KeyStr);
-                               } catch (Exception ex) {
-                                       DebugTool.logError("Failure calling ISTListener: " + ex.toString(), ex);
-                               } // end-catch
-                       } // end-if
-               } catch (Exception ex) {
-                       NativeLogTool.logError(SyncTrace.SYSTEM_LOG_TAG, "Failure writing XML trace message: " + ex.toString());
-               }
-       } // end-method
-       
-       // Package-scoped
-       public static String getLogHeader(String dumpReason, int seqNo) {
-               final String Sep = "-";
-               StringBuilder write = new StringBuilder("<?xml version=\"1.0\"?>" + "<logs>");
-               write.append("<info>");
-               StringBuilder infoBlock = new StringBuilder();
-               String hostInfo = Build.BRAND + Sep + Build.MANUFACTURER + Sep + Build.MODEL + "(" + Build.HOST + ")";
-               infoBlock.append("<host>" + SyncTrace.B64EncodeForXML(hostInfo) + "</host>");
-               String osv = Build.VERSION.RELEASE + " (" + Build.VERSION.CODENAME + ")";
-               infoBlock.append("<osv>" + SyncTrace.B64EncodeForXML(osv) + "</osv>");
-               infoBlock.append(TraceDeviceInfo.getTelephonyHeader());
-
-               long heapSize = Debug.getNativeHeapFreeSize() / 1024;
-               long heapAllocated = Debug.getNativeHeapAllocatedSize() / 1024;
-               infoBlock.append("<mem><hf>" + heapSize + "KB</hf><ha>" + heapAllocated + "KB</ha></mem>");
-               infoBlock.append("<np>" + Runtime.getRuntime().availableProcessors() + "</np>");
-               infoBlock.append("<pid>" + Process.myPid() + "</pid>");
-               infoBlock.append("<tid>" + Thread.currentThread().getId() + "</tid>");
-
-               Timestamp stamp = new Timestamp(SyncTrace.getBaseTics());
-               String GMTtime = stamp.toGMTString().substring(0, 19);
-               long fracSec = stamp.getNanos() / 1000000; // divide by a million
-               String fracSecStr = String.format("%03d", fracSec);
-               infoBlock.append("<utc>" + GMTtime + "." + fracSecStr + "</utc>");
-
-               infoBlock.append(TraceDeviceInfo.getLogHeaderBluetoothPairs());
-               infoBlock.append(getSmartDeviceLinkTraceRoot(dumpReason, seqNo));
-
-               write.append(infoBlock);
-
-               write.append("</info>" + "<msgs>");
-               return write.toString();
-       } // end-method
-       
-       private static String getSmartDeviceLinkTraceRoot(String dumpReason, int seqNo) {
-               StringBuilder write = new StringBuilder("<SmartDeviceLinktraceroot>" + "<sequencenum>" + seqNo
-                               + "</sequencenum>" + "<dumpreason>" + dumpReason
-                               + "</dumpreason><tracelevel>");
-
-               write.append("<tran>" + DiagLevel.getLevel(Mod.tran) + "</tran>");
-               write.append("<proto>" + DiagLevel.getLevel(Mod.proto) + "</proto>");
-               write.append("<mar>" + DiagLevel.getLevel(Mod.mar) + "</mar>");
-               write.append("<rpc>" + DiagLevel.getLevel(Mod.rpc) + "</rpc>");
-               write.append("<proxy>" + DiagLevel.getLevel(Mod.proxy) + "</proxy>");
-               write.append("<app>" + DiagLevel.getLevel(Mod.app) + "</app>");
-
-               write.append("</tracelevel>");
-               write.append("</SmartDeviceLinktraceroot>");
-               return write.toString();
-       } // end-method
-} // end-class
+package com.smartdevicelink.trace;\r
+\r
+import java.sql.Timestamp;\r
+\r
+import android.bluetooth.BluetoothDevice;\r
+import android.os.Build;\r
+import android.os.Debug;\r
+import android.os.Process;\r
+\r
+import com.smartdevicelink.protocol.ProtocolFrameHeader;\r
+import com.smartdevicelink.protocol.enums.FrameDataControlFrameType;\r
+import com.smartdevicelink.protocol.enums.FrameType;\r
+import com.smartdevicelink.protocol.enums.SessionType;\r
+import com.smartdevicelink.proxy.RPCMessage;\r
+import com.smartdevicelink.proxy.RPCRequest;\r
+import com.smartdevicelink.proxy.RPCResponse;\r
+import com.smartdevicelink.trace.enums.DetailLevel;\r
+import com.smartdevicelink.trace.enums.InterfaceActivityDirection;\r
+import com.smartdevicelink.trace.enums.Mod;\r
+import com.smartdevicelink.transport.SiphonServer;\r
+import com.smartdevicelink.util.BitConverter;\r
+import com.smartdevicelink.util.DebugTool;\r
+import com.smartdevicelink.util.NativeLogTool;\r
+\r
+/* This class handles the global TraceSettings as requested by the users either through the combination of the following\r
+   1. System defaults\r
+   2. Application XML config\r
+   3. Programmatic requests from application itself\r
+\r
+   It is manifested in the <applink>...</applink> tags\r
+ */\r
+\r
+public class SmartDeviceLinkTrace {\r
+       private static final String SMARTDEVICELINK_LIB_TRACE_KEY = "42baba60-eb57-11df-98cf-0800200c9a66";\r
+       \r
+       static boolean canWriteLogs = false;\r
+               \r
+       public static final String SYSTEM_LOG_TAG = "SmartDeviceLinkTrace";\r
+       \r
+       private static long baseTics  = java.lang.System.currentTimeMillis();\r
+       private final static String KeyStr = SMARTDEVICELINK_LIB_TRACE_KEY;\r
+       private static boolean acceptAPITraceAdjustments = true;\r
+\r
+       protected static ISTListener m_appTraceListener = null;\r
+\r
+       ///\r
+       ///  The PUBLIC interface to SmartDeviceLinkTrace starts here\r
+       ///\r
+\r
+\r
+       public static void setAcceptAPITraceAdjustments(Boolean APITraceAdjustmentsAccepted) {\r
+               if (APITraceAdjustmentsAccepted != null) {\r
+                       acceptAPITraceAdjustments = APITraceAdjustmentsAccepted;\r
+               }\r
+       }\r
+       \r
+       public static boolean getAcceptAPITraceAdjustments() {\r
+               return acceptAPITraceAdjustments;\r
+       }\r
+       \r
+       public static void setAppTraceListener(ISTListener listener) {\r
+               m_appTraceListener = listener;\r
+       } // end-method\r
+\r
+       public static void setTracingEnable(Boolean enable) {\r
+               if (enable != null) {\r
+                       canWriteLogs = enable;\r
+               }\r
+       } // end-method\r
+\r
+       public static void setAppTraceLevel(DetailLevel dt) {\r
+               if ( dt != null && acceptAPITraceAdjustments)\r
+                       DiagLevel.setLevel(Mod.app, dt);\r
+       } // end-method\r
+\r
+       public static void setProxyTraceLevel(DetailLevel dt) {\r
+               if (dt != null && acceptAPITraceAdjustments)\r
+                       DiagLevel.setLevel(Mod.proxy, dt);\r
+       } // end-method\r
+\r
+       public static void setRpcTraceLevel(DetailLevel dt) {\r
+               if (dt != null && acceptAPITraceAdjustments)\r
+                       DiagLevel.setLevel(Mod.rpc, dt);\r
+       } // end-method\r
+\r
+       public static void setMarshallingTraceLevel(DetailLevel dt) {\r
+               if (dt != null && acceptAPITraceAdjustments)\r
+                       DiagLevel.setLevel(Mod.mar, dt);\r
+       } // end-method\r
+\r
+       public static void setProtocolTraceLevel(DetailLevel dt) {\r
+               if (dt != null && acceptAPITraceAdjustments)\r
+                       DiagLevel.setLevel(Mod.proto, dt);\r
+       } // end-method\r
+\r
+       public static void setTransportTraceLevel(DetailLevel dt) {\r
+               if (dt != null && acceptAPITraceAdjustments)\r
+                               DiagLevel.setLevel(Mod.tran, dt);\r
+       } // end-method\r
+\r
+       private static String encodeTraceMessage(long timestamp, Mod module, InterfaceActivityDirection msgDirection, String msgBodyXml) {\r
+               StringBuilder sb = new StringBuilder("<msg><dms>");\r
+               sb.append(timestamp);\r
+               sb.append("</dms><pid>");\r
+               sb.append(Process.myPid());\r
+               sb.append("</pid><tid>");\r
+               sb.append(Thread.currentThread().getId());\r
+               sb.append("</tid><mod>");\r
+               sb.append(module.toString());\r
+               sb.append("</mod>");\r
+               if (msgDirection != InterfaceActivityDirection.None) {\r
+                       sb.append("<dir>");\r
+                       sb.append(interfaceActivityDirectionToString(msgDirection));\r
+                       sb.append("</dir>");\r
+               } // end-if\r
+               sb.append(msgBodyXml);\r
+               sb.append("</msg>");\r
+\r
+               return sb.toString();\r
+       } // end-method\r
+\r
+       private static String interfaceActivityDirectionToString(InterfaceActivityDirection iaDirection) {\r
+               String str = "";\r
+               switch (iaDirection) {\r
+                       case Receive:\r
+                               str = "rx";\r
+                               break;\r
+                       case Transmit:\r
+                               str = "tx";\r
+                               break;\r
+               } // end-switch\r
+               return str;\r
+       } // end-method\r
+\r
+       static String B64EncodeForXML(String data) {\r
+               return Mime.base64Encode(data);\r
+               // Base64 only available in 2.2, when SmartDeviceLink base is 2.2 use: return Base64.encodeToString(data.getBytes(), Base64.DEFAULT);\r
+       } // end-method\r
+       \r
+       public static void logProxyEvent(String eventText, String token) {\r
+               if (DiagLevel.getLevel(Mod.proxy) == DetailLevel.OFF || !token.equals(KeyStr)) {\r
+                       return;\r
+               } // end-if\r
+\r
+               String msg = SmartDeviceLinkTrace.B64EncodeForXML(eventText);\r
+               String xml = SmartDeviceLinkTrace.encodeTraceMessage(SmartDeviceLinkTrace.getBaseTicsDelta(), Mod.proxy, InterfaceActivityDirection.None, "<d>" + msg + "</d>");\r
+               writeXmlTraceMessage(xml);\r
+       } // end-method\r
+\r
+       public static void logAppEvent(String eventText) {\r
+               if (DiagLevel.getLevel(Mod.app) == DetailLevel.OFF) {\r
+                       return;\r
+               } // end-if\r
+\r
+               long timestamp = SmartDeviceLinkTrace.getBaseTicsDelta();\r
+               String msg = SmartDeviceLinkTrace.B64EncodeForXML(eventText);\r
+               String xml = SmartDeviceLinkTrace.encodeTraceMessage(timestamp, Mod.app, InterfaceActivityDirection.None, "<d>" + msg + "</d>");\r
+               writeXmlTraceMessage(xml);\r
+       } // end-method\r
+\r
+       public static void logRPCEvent(InterfaceActivityDirection msgDirection, RPCMessage rpcMsg, String token) {\r
+               DetailLevel dl = DiagLevel.getLevel(Mod.rpc);\r
+               if (dl == DetailLevel.OFF || !token.equals(KeyStr)) {\r
+                       return;\r
+               } // end-if\r
+\r
+               long timestamp = SmartDeviceLinkTrace.getBaseTicsDelta();\r
+               String xml = SmartDeviceLinkTrace.encodeTraceMessage(timestamp, Mod.rpc, msgDirection, rpc2Xml(dl, rpcMsg));\r
+               writeXmlTraceMessage(xml);\r
+       } // end-method\r
+\r
+       private static String rpc2Xml(DetailLevel dl, RPCMessage rpcMsg) {\r
+               StringBuilder rpcAsXml = new StringBuilder();\r
+               rpcAsXml.append("<op>");\r
+               rpcAsXml.append(rpcMsg.getFunctionName());\r
+               rpcAsXml.append("</op>");\r
+               boolean hasCorrelationID = false;\r
+               Integer correlationID = -1;\r
+               if (rpcMsg instanceof RPCRequest) {\r
+                       hasCorrelationID = true;\r
+                       correlationID = ((RPCRequest)rpcMsg).getCorrelationID();\r
+               } else if (rpcMsg instanceof RPCResponse) {\r
+                       hasCorrelationID = true;\r
+                       correlationID = ((RPCResponse)rpcMsg).getCorrelationID();\r
+               } // end-if\r
+               if (hasCorrelationID) {\r
+                       rpcAsXml.append("<cid>");\r
+                       rpcAsXml.append(correlationID);\r
+                       rpcAsXml.append("</cid>");\r
+               } // end-if\r
+               rpcAsXml.append("<type>");\r
+               rpcAsXml.append(rpcMsg.getMessageType());\r
+               rpcAsXml.append("</type>");\r
+               //rpcAsXml.append(newline);\r
+\r
+               if (dl == DetailLevel.VERBOSE) {\r
+                       OpenRPCMessage orpcmsg = new OpenRPCMessage(rpcMsg);\r
+                       String rpcParamList = orpcmsg.msgDump();\r
+                       String msg = SmartDeviceLinkTrace.B64EncodeForXML(rpcParamList);\r
+                       rpcAsXml.append("<d>");\r
+                       rpcAsXml.append(msg);\r
+                       rpcAsXml.append("</d>");\r
+               } // end-if\r
+               return rpcAsXml.toString();\r
+       } // end-method\r
+\r
+       public static void logMarshallingEvent(InterfaceActivityDirection msgDirection, byte[] marshalledMessage, String token) {\r
+               DetailLevel dl = DiagLevel.getLevel(Mod.mar);\r
+               if (dl == DetailLevel.OFF || !token.equals(KeyStr)) {\r
+                       return;\r
+               } // end-fif\r
+\r
+               long timestamp = SmartDeviceLinkTrace.getBaseTicsDelta();\r
+               StringBuilder msg = new StringBuilder();\r
+               msg.append("<sz>");\r
+               msg.append(marshalledMessage.length);\r
+               msg.append("</sz>");\r
+               if (dl == DetailLevel.VERBOSE) {\r
+                       msg.append("<d>");\r
+                       msg.append(Mime.base64Encode(marshalledMessage));\r
+                       // Base64 only available in 2.2, when SmartDeviceLink base is 2.2 use: msg.append(Base64.encodeToString(marshalledMessage, Base64.DEFAULT));\r
+                       msg.append("</d>");\r
+               } // end-if\r
+               String xml = SmartDeviceLinkTrace.encodeTraceMessage(timestamp, Mod.mar, msgDirection, msg.toString());\r
+               writeXmlTraceMessage(xml);\r
+       } // end-method\r
+\r
+       public static void logProtocolEvent(InterfaceActivityDirection frameDirection, ProtocolFrameHeader frameHeader, byte[] frameData, int frameDataOffset, int frameDataLength, String token) {\r
+               DetailLevel dl = DiagLevel.getLevel(Mod.proto);\r
+               if (dl == DetailLevel.OFF || !token.equals(KeyStr)) {\r
+                       return;\r
+               } // end-if\r
+\r
+               StringBuffer protoMsg = new StringBuffer();\r
+               protoMsg.append("<frame>");\r
+               protoMsg.append(SmartDeviceLinkTrace.getProtocolFrameHeaderInfo(frameHeader, frameData));\r
+               if (dl == DetailLevel.VERBOSE) {\r
+                       if (frameData != null && frameDataLength > 0) {\r
+                               protoMsg.append("<d>");\r
+                               String bytesInfo = "";\r
+                               bytesInfo = Mime.base64Encode(frameData, frameDataOffset, frameDataLength);\r
+                               // Base64 only available in 2.2, when SmartDeviceLink base is 2.2 use: bytesInfo = Base64.encodeToString(frameData, frameDataOffset, frameDataLength, Base64.DEFAULT);\r
+                               protoMsg.append(bytesInfo);\r
+                               protoMsg.append("</d>");\r
+                       } // end-if\r
+               } // end-if\r
+               protoMsg.append("</frame>");\r
+               String xml = SmartDeviceLinkTrace.encodeTraceMessage(SmartDeviceLinkTrace.getBaseTicsDelta(), Mod.proto, frameDirection, protoMsg.toString());\r
+               writeXmlTraceMessage(xml);\r
+       } // end-method\r
+\r
+       private static String getProtocolFrameType(FrameType f) {\r
+               if (f == FrameType.Control)\r
+                       return "Control";\r
+               else if (f == FrameType.Consecutive)\r
+                       return "Consecutive";\r
+               else if (f == FrameType.First)\r
+                       return "First";\r
+               else if (f == FrameType.Single)\r
+                       return "Single";\r
+\r
+               return "Unknown";\r
+       } // end-method\r
+\r
+       private static String getProtocolSessionType(SessionType serviceType) {\r
+               String s;\r
+               if (serviceType == SessionType.RPC )\r
+                       s = "rpc";\r
+               else if (serviceType == SessionType.Bulk_Data)\r
+                       s = "bulk";\r
+               else\r
+                       s = "Unknown";\r
+               return s;\r
+       } // end-method\r
+\r
+       private static String getProtocolFrameHeaderInfo(ProtocolFrameHeader hdr, byte[] buf) {\r
+               StringBuilder sb = new StringBuilder();\r
+               sb.append("<hdr>");\r
+               sb.append("<ver>");\r
+               sb.append(hdr.getVersion());\r
+               sb.append("</ver><cmp>");\r
+               sb.append(hdr.isCompressed());\r
+               sb.append("</cmp><ft>");\r
+               sb.append(getProtocolFrameType(hdr.getFrameType()));\r
+               sb.append("</ft><st>");\r
+               sb.append(getProtocolSessionType(hdr.getSessionType()));\r
+               sb.append("</st><sid>");\r
+               sb.append(hdr.getSessionID());\r
+               sb.append("</sid><sz>");\r
+               sb.append(hdr.getDataSize());\r
+               sb.append("</sz>");\r
+\r
+               int frameData = hdr.getFrameData();\r
+               if (hdr.getFrameType() == FrameType.Control) {\r
+                       sb.append("<ca>");\r
+                       if (frameData == FrameDataControlFrameType.StartSession.getValue()) \r
+                               sb.append("StartSession");\r
+                       else if (frameData == FrameDataControlFrameType.StartSessionACK.getValue())\r
+                               sb.append("StartSessionACK");\r
+                       else if (frameData == FrameDataControlFrameType.StartSessionNACK.getValue())\r
+                               sb.append("StartSessionNACK");\r
+                       else if (frameData == FrameDataControlFrameType.EndSession.getValue())\r
+                               sb.append("EndSession");\r
+                       sb.append("</ca>");\r
+               } else if (hdr.getFrameType() == FrameType.Consecutive ) {\r
+                       sb.append("<fsn>");\r
+                       if (frameData == 0 )\r
+                               sb.append("lastFrame");\r
+                       else\r
+                               sb.append(String.format("%02X",frameData)); \r
+                       sb.append("</fsn>");\r
+               } else if (hdr.getFrameType() == FrameType.First ) {\r
+                       int totalSize = BitConverter.intFromByteArray(buf, 0);                  \r
+                       int numFrames = BitConverter.intFromByteArray(buf, 4);\r
+                       sb.append("<total>" + totalSize + "</total><numframes>" + numFrames + "</numframes>");\r
+               } else if (hdr.getFrameType() == FrameType.Single ) {\r
+                       sb.append("<single/>");\r
+               }\r
+\r
+               sb.append("</hdr>");\r
+\r
+               return sb.toString();\r
+       } // end-method\r
+\r
+       public static String getBTDeviceInfo(BluetoothDevice btDevice) {\r
+               StringBuilder sb = new StringBuilder();\r
+               sb.append("<btp>");\r
+               String btdn = btDevice.getName();\r
+               sb.append("<btn>");\r
+               sb.append(SmartDeviceLinkTrace.B64EncodeForXML(btdn));\r
+               sb.append("</btn>");\r
+               sb.append("<bta>" + btDevice.getAddress() + "</bta>");\r
+               sb.append("<bts>" + btDevice.getBondState() + "</bts>");\r
+               sb.append("</btp>");\r
+               return sb.toString();\r
+       } // end-method\r
+\r
+       public static void logTransportEvent(String preamble, String transportSpecificInfoXml, InterfaceActivityDirection msgDirection, byte buf[], int byteLength, String token) {\r
+               logTransportEvent(preamble, transportSpecificInfoXml, msgDirection, buf, 0, byteLength, token);\r
+       } // end-method\r
+\r
+       private static void checkB64(String x, byte[] buf, int offset, int byteLength) {\r
+               if ((x.length() % 4) != 0) {\r
+                       NativeLogTool.logWarning(SmartDeviceLinkTrace.SYSTEM_LOG_TAG, "b64 string length (" + x.length() + ") isn't multiple of 4: buf.length=" + buf.length + ", offset=" + offset + ", len=" + byteLength);\r
+               } // end-if\r
+       } // end-method\r
+\r
+       public static void logTransportEvent(String preamble, String transportSpecificInfoXml, InterfaceActivityDirection msgDirection, byte buf[], int offset, int byteLength, String token) {\r
+               if (DiagLevel.getLevel(Mod.tran) == DetailLevel.OFF || !token.equals(KeyStr)) {\r
+                       return;\r
+               } // end-if\r
+\r
+               StringBuilder msg = new StringBuilder();\r
+               if (transportSpecificInfoXml != null && transportSpecificInfoXml.length() > 0) {\r
+                       msg.append(transportSpecificInfoXml);\r
+               } // end-if\r
+               if (preamble != null && preamble.length() > 0) {\r
+                       msg.append("<desc>");\r
+                       msg.append(preamble);\r
+                       msg.append("</desc>");\r
+               } // end-if\r
+               if (buf != null) {\r
+                       msg.append("<sz>");\r
+                       msg.append(byteLength);\r
+                       msg.append("</sz>");\r
+                       DetailLevel dl = DiagLevel.getLevel(Mod.tran);\r
+                       if (dl == DetailLevel.VERBOSE) {\r
+                               if (buf != null && byteLength > 0) {\r
+                                       msg.append("<d>");\r
+                                       String bytesInfo = Mime.base64Encode(buf, offset, byteLength);\r
+                                       checkB64(bytesInfo, buf, offset, byteLength);\r
+                                       msg.append(bytesInfo);\r
+                                       msg.append("</d>");\r
+                               } // end-if\r
+                       } // end-if\r
+               } // end-if\r
+               String xml = SmartDeviceLinkTrace.encodeTraceMessage(SmartDeviceLinkTrace.getBaseTicsDelta(), Mod.tran, msgDirection, msg.toString());\r
+               writeXmlTraceMessage(xml);\r
+       } // end-method\r
+\r
+       // Package-scoped\r
+       static long getBaseTicsDelta() {\r
+               return java.lang.System.currentTimeMillis() - getBaseTics();\r
+       }\r
+\r
+       // Package-scoped\r
+       static long getBaseTics() {\r
+               return baseTics;\r
+       } // end-method\r
+\r
+       public static Boolean writeMessageToSiphonServer(String info) {\r
+               return SiphonServer.sendFormattedTraceMessage(info);\r
+       }\r
+\r
+       private static void writeXmlTraceMessage(String msg) {\r
+               try {                   \r
+                       // Attempt to write formatted message to the Siphon\r
+                       if (false == writeMessageToSiphonServer(msg)) {\r
+                               // If writing to the Siphon fails, write to the native log\r
+                               NativeLogTool.logInfo(SmartDeviceLinkTrace.SYSTEM_LOG_TAG, msg);\r
+                       }\r
+                       \r
+                       ISTListener localTraceListener = m_appTraceListener;\r
+\r
+                       if (localTraceListener != null) {\r
+                               try {\r
+                                       localTraceListener.logXmlMsg(msg, KeyStr);\r
+                               } catch (Exception ex) {\r
+                                       DebugTool.logError("Failure calling ISTListener: " + ex.toString(), ex);\r
+                               } // end-catch\r
+                       } // end-if\r
+               } catch (Exception ex) {\r
+                       NativeLogTool.logError(SmartDeviceLinkTrace.SYSTEM_LOG_TAG, "Failure writing XML trace message: " + ex.toString());\r
+               }\r
+       } // end-method\r
+       \r
+       // Package-scoped\r
+       public static String getLogHeader(String dumpReason, int seqNo) {\r
+               final String Sep = "-";\r
+               StringBuilder write = new StringBuilder("<?xml version=\"1.0\"?>" + "<logs>");\r
+               write.append("<info>");\r
+               StringBuilder infoBlock = new StringBuilder();\r
+               String hostInfo = Build.BRAND + Sep + Build.MANUFACTURER + Sep + Build.MODEL + "(" + Build.HOST + ")";\r
+               infoBlock.append("<host>" + SmartDeviceLinkTrace.B64EncodeForXML(hostInfo) + "</host>");\r
+               String osv = Build.VERSION.RELEASE + " (" + Build.VERSION.CODENAME + ")";\r
+               infoBlock.append("<osv>" + SmartDeviceLinkTrace.B64EncodeForXML(osv) + "</osv>");\r
+               infoBlock.append(TraceDeviceInfo.getTelephonyHeader());\r
+\r
+               long heapSize = Debug.getNativeHeapFreeSize() / 1024;\r
+               long heapAllocated = Debug.getNativeHeapAllocatedSize() / 1024;\r
+               infoBlock.append("<mem><hf>" + heapSize + "KB</hf><ha>" + heapAllocated + "KB</ha></mem>");\r
+               infoBlock.append("<np>" + Runtime.getRuntime().availableProcessors() + "</np>");\r
+               infoBlock.append("<pid>" + Process.myPid() + "</pid>");\r
+               infoBlock.append("<tid>" + Thread.currentThread().getId() + "</tid>");\r
+\r
+               // String dateStamp = (String)\r
+               // DateFormat.format("yy-MM-dd hh:mm:ss SSS", new Timestamp(baseTics));\r
+               Timestamp stamp = new Timestamp(SmartDeviceLinkTrace.getBaseTics());\r
+               String GMTtime = stamp.toGMTString().substring(0, 19);\r
+               long fracSec = stamp.getNanos() / 1000000; // divide by a million\r
+               String fracSecStr = String.format("%03d", fracSec);\r
+               infoBlock.append("<utc>" + GMTtime + "." + fracSecStr + "</utc>");\r
+\r
+               infoBlock.append(TraceDeviceInfo.getLogHeaderBluetoothPairs());\r
+               infoBlock.append(getApplinkTraceRoot(dumpReason, seqNo));\r
+\r
+               write.append(infoBlock);\r
+\r
+               write.append("</info>" + "<msgs>");\r
+               return write.toString();\r
+       } // end-method\r
+       \r
+       private static String getApplinkTraceRoot(String dumpReason, int seqNo) {\r
+               StringBuilder write = new StringBuilder("<applinktraceroot>" + "<sequencenum>" + seqNo\r
+                               + "</sequencenum>" + "<dumpreason>" + dumpReason\r
+                               + "</dumpreason><tracelevel>");\r
+\r
+               write.append("<tran>" + DiagLevel.getLevel(Mod.tran) + "</tran>");\r
+               write.append("<proto>" + DiagLevel.getLevel(Mod.proto) + "</proto>");\r
+               write.append("<mar>" + DiagLevel.getLevel(Mod.mar) + "</mar>");\r
+               write.append("<rpc>" + DiagLevel.getLevel(Mod.rpc) + "</rpc>");\r
+               write.append("<proxy>" + DiagLevel.getLevel(Mod.proxy) + "</proxy>");\r
+               write.append("<app>" + DiagLevel.getLevel(Mod.app) + "</app>");\r
+\r
+               write.append("</tracelevel>");\r
+               write.append("</applinktraceroot>");\r
+               return write.toString();\r
+       } // end-method\r
+} // end-class
\ No newline at end of file
index 6d67aea..b29a7a7 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.trace;
-
-import java.util.Iterator;
-import java.util.Set;
-
-import com.smartdevicelink.util.DebugTool;
-
-import android.bluetooth.BluetoothAdapter;
-import android.bluetooth.BluetoothDevice;
-import android.telephony.TelephonyManager;
-
-public class TraceDeviceInfo {
-       // http://developer.android.com/guide/topics/data/data-storage.html
-
-       private static TelephonyManager m_telephonyManager;
-       
-       // Constructor
-       public TraceDeviceInfo(TelephonyManager telephonyManager) {
-               m_telephonyManager = telephonyManager;
-       }
-
-       public static void setTelephonyManager(TelephonyManager telephonyManager) {
-               m_telephonyManager = telephonyManager;
-       }
-
-       public static TelephonyManager getTelephonyManager() {
-               return m_telephonyManager;
-       }
-
-       // package scoped
-       static String getTelephonyHeader() {
-               // Telephony manager can tell us a few things...
-               String info = "";
-
-               if (m_telephonyManager != null) {
-                       try { // getDeviceId() requires android.permission.READ_PHONE_STATE
-                               info = "<deviceid>" + m_telephonyManager.getDeviceId() + "</deviceid>";
-                       } catch (Exception e1) {
-                               DebugTool.logError("Failure getting telephony device ID: " + e1.toString(), e1);
-                       }
-       
-                       info = "<pt>";
-                       switch (m_telephonyManager.getPhoneType()) {
-                               case TelephonyManager.PHONE_TYPE_NONE:
-                                       info += "NONE";
-                                       break;
-                               case TelephonyManager.PHONE_TYPE_GSM:
-                                       info += "GSM";
-                                       break;
-                               case TelephonyManager.PHONE_TYPE_CDMA:
-                                       info += "CDMA";
-                                       break;
-                               default:
-                                       info += "UNKNOWN";
-                       } // end-switch
-       
-                       info += "</pt>" + "<nt>";
-       
-                       switch (m_telephonyManager.getNetworkType()) {
-                               case TelephonyManager.NETWORK_TYPE_UNKNOWN:
-                                       info += "UKNOWN";
-                                       break;
-                               case TelephonyManager.NETWORK_TYPE_GPRS:
-                                       info += "GPRS";
-                                       break;
-                               case TelephonyManager.NETWORK_TYPE_EDGE:
-                                       info += "EDGE";
-                                       break;
-                               case TelephonyManager.NETWORK_TYPE_UMTS:
-                                       info += "UMTS";
-                                       break;
-                               case TelephonyManager.NETWORK_TYPE_HSDPA:
-                                       info += "HSDPA";
-                                       break;
-                               case TelephonyManager.NETWORK_TYPE_HSUPA:
-                                       info += "HSUPA";
-                                       break;
-                               case TelephonyManager.NETWORK_TYPE_HSPA:
-                                       info += "HSPA";
-                                       break;
-                               case TelephonyManager.NETWORK_TYPE_CDMA:
-                                       info += "CDMA";
-                                       break;
-                               case TelephonyManager.NETWORK_TYPE_EVDO_0:
-                                       info += "EVDO_O";
-                                       break;
-                               case TelephonyManager.NETWORK_TYPE_EVDO_A:
-                                       info += "EVDO_A";
-                                       break;
-                               case TelephonyManager.NETWORK_TYPE_1xRTT:
-                                       info += "1xRTT";
-                                       break;
-                               default:
-                                       info += "UNKNOWN";
-                                       break;
-                       } // end-switch
-       
-                       info += "</nt>";
-               } // end-if
-               return info;
-       } // end-method
-
-       // Package scoped
-       static String getLogHeaderBluetoothPairs() {
-               Set<BluetoothDevice> btDevices = BluetoothAdapter.getDefaultAdapter()
-                               .getBondedDevices();
-
-               StringBuilder write = new StringBuilder("<btpairs>");
-               Iterator<BluetoothDevice> iter = btDevices.iterator();
-               while (iter.hasNext()) {
-                       write.append(SyncTrace.getBTDeviceInfo(iter.next()));
-               }
-               write.append("</btpairs>");
-
-               return write.toString();
-       } // end-method
-} // end-class
+/**\r
+ * \r
+ */\r
+package com.smartdevicelink.trace;\r
+\r
+import java.util.Iterator;\r
+import java.util.Set;\r
+\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+import android.bluetooth.BluetoothAdapter;\r
+import android.bluetooth.BluetoothDevice;\r
+import android.telephony.TelephonyManager;\r
+\r
+/**\r
+ * @author vvolkman\r
+ * \r
+ */\r
+public class TraceDeviceInfo {\r
+       // http://developer.android.com/guide/topics/data/data-storage.html\r
+\r
+       private static TelephonyManager m_telephonyManager;\r
+       \r
+       // Constructor\r
+       public TraceDeviceInfo(TelephonyManager telephonyManager) {\r
+               m_telephonyManager = telephonyManager;\r
+       }\r
+\r
+       public static void setTelephonyManager(TelephonyManager telephonyManager) {\r
+               m_telephonyManager = telephonyManager;\r
+       }\r
+\r
+       public static TelephonyManager getTelephonyManager() {\r
+               return m_telephonyManager;\r
+       }\r
+\r
+       // package scoped\r
+       static String getTelephonyHeader() {\r
+               // Telephony manager can tell us a few things...\r
+               String info = "";\r
+\r
+               if (m_telephonyManager != null) {\r
+                       try { // getDeviceId() requires android.permission.READ_PHONE_STATE\r
+                               info = "<deviceid>" + m_telephonyManager.getDeviceId() + "</deviceid>";\r
+                       } catch (Exception e1) {\r
+                               DebugTool.logError("Failure getting telephony device ID: " + e1.toString(), e1);\r
+                       }\r
+       \r
+                       info = "<pt>";\r
+                       switch (m_telephonyManager.getPhoneType()) {\r
+                               case TelephonyManager.PHONE_TYPE_NONE:\r
+                                       info += "NONE";\r
+                                       break;\r
+                               case TelephonyManager.PHONE_TYPE_GSM:\r
+                                       info += "GSM";\r
+                                       break;\r
+                               case TelephonyManager.PHONE_TYPE_CDMA:\r
+                                       info += "CDMA";\r
+                                       break;\r
+                               default:\r
+                                       info += "UNKNOWN";\r
+                       } // end-switch\r
+       \r
+                       info += "</pt>" + "<nt>";\r
+       \r
+                       switch (m_telephonyManager.getNetworkType()) {\r
+                               case TelephonyManager.NETWORK_TYPE_UNKNOWN:\r
+                                       info += "UKNOWN";\r
+                                       break;\r
+                               case TelephonyManager.NETWORK_TYPE_GPRS:\r
+                                       info += "GPRS";\r
+                                       break;\r
+                               case TelephonyManager.NETWORK_TYPE_EDGE:\r
+                                       info += "EDGE";\r
+                                       break;\r
+                               case TelephonyManager.NETWORK_TYPE_UMTS:\r
+                                       info += "UMTS";\r
+                                       break;\r
+                               case TelephonyManager.NETWORK_TYPE_HSDPA:\r
+                                       info += "HSDPA";\r
+                                       break;\r
+                               case TelephonyManager.NETWORK_TYPE_HSUPA:\r
+                                       info += "HSUPA";\r
+                                       break;\r
+                               case TelephonyManager.NETWORK_TYPE_HSPA:\r
+                                       info += "HSPA";\r
+                                       break;\r
+                               case TelephonyManager.NETWORK_TYPE_CDMA:\r
+                                       info += "CDMA";\r
+                                       break;\r
+                               case TelephonyManager.NETWORK_TYPE_EVDO_0:\r
+                                       info += "EVDO_O";\r
+                                       break;\r
+                               case TelephonyManager.NETWORK_TYPE_EVDO_A:\r
+                                       info += "EVDO_A";\r
+                                       break;\r
+                               case TelephonyManager.NETWORK_TYPE_1xRTT:\r
+                                       info += "1xRTT";\r
+                                       break;\r
+                               default:\r
+                                       info += "UNKNOWN";\r
+                                       break;\r
+                       } // end-switch\r
+       \r
+                       info += "</nt>";\r
+               } // end-if\r
+               return info;\r
+       } // end-method\r
+\r
+       // Package scoped\r
+       static String getLogHeaderBluetoothPairs() {\r
+               Set<BluetoothDevice> btDevices = BluetoothAdapter.getDefaultAdapter()\r
+                               .getBondedDevices();\r
+\r
+               StringBuilder write = new StringBuilder("<btpairs>");\r
+               Iterator<BluetoothDevice> iter = btDevices.iterator();\r
+               while (iter.hasNext()) {\r
+                       write.append(SmartDeviceLinkTrace.getBTDeviceInfo(iter.next()));\r
+               }\r
+               write.append("</btpairs>");\r
+\r
+               return write.toString();\r
+       } // end-method\r
+} // end-class
\ No newline at end of file
index b0f3ad8..87bad55 100755 (executable)
@@ -1,14 +1,12 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.trace.enums;
-
-public enum DetailLevel {
-       OFF, 
-       TERSE, 
-       VERBOSE;
-
-    public static DetailLevel valueForString(String value) {
-        return valueOf(value);
-    }
-}
+package com.smartdevicelink.trace.enums;\r
+\r
+    \r
+public enum DetailLevel {\r
+       OFF, \r
+       TERSE, \r
+       VERBOSE;\r
+\r
+    public static DetailLevel valueForString(String value) {\r
+        return valueOf(value);\r
+    }\r
+}\r
index ce430cb..c348d82 100755 (executable)
@@ -1,10 +1,7 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.trace.enums;
-
-public enum InterfaceActivityDirection {
-       Transmit,
-       Receive,
-       None;
-}
+package com.smartdevicelink.trace.enums;\r
+\r
+public enum InterfaceActivityDirection {\r
+       Transmit,\r
+       Receive,\r
+       None;\r
+}\r
index dc16112..9c34e2f 100755 (executable)
@@ -1,17 +1,14 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.trace.enums;
-
-public enum Mod {
-         tran,
-         proto,
-         mar,
-         rpc,
-         app,
-         proxy;
-
-       public static Mod valueForString(String value) {
-               return valueOf(value);
-       }
-};
+package com.smartdevicelink.trace.enums;\r
+\r
+public enum Mod {\r
+         tran,\r
+         proto,\r
+         mar,\r
+         rpc,\r
+         app,\r
+         proxy;\r
+\r
+       public static Mod valueForString(String value) {\r
+               return valueOf(value);\r
+       }\r
+};
\ No newline at end of file
index c2a60b8..c8818ce 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.transport;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.OutputStream;
-import java.util.UUID;
-
-import android.bluetooth.BluetoothAdapter;
-import android.bluetooth.BluetoothDevice;
-import android.bluetooth.BluetoothServerSocket;
-import android.bluetooth.BluetoothSocket;
-
-import com.smartdevicelink.exception.SmartDeviceLinkException;
-import com.smartdevicelink.exception.SmartDeviceLinkExceptionCause;
-import com.smartdevicelink.trace.SyncTrace;
-import com.smartdevicelink.trace.enums.InterfaceActivityDirection;
-import com.smartdevicelink.util.DebugTool;
-
-/**
- * Bluetooth Transport Implementation. This transport advertises its existence to SmartDeviceLink by publishing an SDP record and waiting for an incoming connection from SmartDeviceLink. Connection is verified by checking for the SmartDeviceLink UUID. For more detailed information please refer to the <a href="#bluetoothTransport">Bluetooth Transport Guide</a>.
- *
- */
-public class BTTransport extends SmartDeviceLinkTransport {    
-       //936DA01F9ABD4D9D80C702AF85C822A8
-       private final static UUID SMARTDEVICELINK_V4_MOBILE_APPLICATION_SVC_CLASS = new UUID(0x936DA01F9ABD4D9DL, 0x80C702AF85C822A8L);
-
-       private static final String SMARTDEVICELINK_LIB_TRACE_KEY = "42baba60-eb57-11df-98cf-0800200c9a66";
-       
-       private BluetoothAdapter _adapter = null;
-       private BluetoothSocket _activeSocket = null;
-       private InputStream _input = null;
-       private UUID _listeningServiceUUID = SMARTDEVICELINK_V4_MOBILE_APPLICATION_SVC_CLASS;
-       private BluetoothAdapterMonitor _bluetoothAdapterMonitor = null;
-       private TransportReaderThread _transportReader = null;
-       private OutputStream _output = null;
-       private BluetoothServerSocket _serverSocket = null;
-       
-       // Boolean to monitor if the transport is in a disconnecting state
-    private boolean _disconnecting = false;
-       
-       public BTTransport(ITransportListener transportListener) {
-               super(transportListener);
-       } // end-ctor
-       
-       public void openConnection () throws SmartDeviceLinkException {         
-               // Get the device's default Bluetooth Adapter
-               _adapter = BluetoothAdapter.getDefaultAdapter();
-               
-               // Test if Adapter exists
-               if (_adapter == null) {
-                       throw new SmartDeviceLinkException("No Bluetooth adapter found. Bluetooth adapter must exist to communicate with SmartDeviceLink.", SmartDeviceLinkExceptionCause.BLUETOOTH_ADAPTER_NULL);
-               }
-               
-               // Test if Bluetooth is enabled
-               try {
-                       if (!_adapter.isEnabled()) {
-                               throw new SmartDeviceLinkException("Bluetooth adapter must be enabled to instantiate a SmartDeviceLinkProxy object.", SmartDeviceLinkExceptionCause.BLUETOOTH_DISABLED);
-                       }
-               } catch (SecurityException e) {
-                       throw new SmartDeviceLinkException("Insufficient permissions to interact with the Bluetooth Adapter.", SmartDeviceLinkExceptionCause.PERMISSION_DENIED);
-               }
-               
-               // Start BluetoothAdapterMonitor to ensure the Bluetooth Adapter continues to be enabled
-               _bluetoothAdapterMonitor = new BluetoothAdapterMonitor(_adapter);
-               
-               try {
-                       _serverSocket = _adapter.listenUsingRfcommWithServiceRecord("SmartDeviceLinkProxy", _listeningServiceUUID);
-               } catch (IOException ex) {
-                       
-                       // Test to determine if the bluetooth has been disabled since last check                        
-                       if (!_adapter.isEnabled()) {
-                               throw new SmartDeviceLinkException("Bluetooth adapter must be on to instantiate a SmartDeviceLinkProxy object.", SmartDeviceLinkExceptionCause.BLUETOOTH_DISABLED);
-                       }
-                       
-                       throw new SmartDeviceLinkException("Could not open connection to SmartDeviceLink.", ex, SmartDeviceLinkExceptionCause.SMARTDEVICELINK_CONNECTION_FAILED);
-               } 
-               
-               // Test to ensure serverSocket is not null
-               if (_serverSocket == null) {
-                       throw new SmartDeviceLinkException("Could not open connection to SmartDeviceLink.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_CONNECTION_FAILED);
-               }
-               
-               SyncTrace.logTransportEvent("BTTransport: listening for incoming connect to service ID " + _listeningServiceUUID, null, InterfaceActivityDirection.Receive, null, 0, SMARTDEVICELINK_LIB_TRACE_KEY);
-               
-               // Setup transportReader thread
-               _transportReader = new TransportReaderThread();
-               _transportReader.setName("TransportReader");
-               _transportReader.setDaemon(true);
-               _transportReader.start();
-               
-               // Initialize the SiphonServer
-               SiphonServer.init();
-       } // end-method
-
-       public void disconnect() {
-               disconnect(null, null);
-       }
-
-       /**
-        * Destroys the transport between SmartDeviceLink and the mobile app
-        * 
-        * @param msg
-        * @param ex
-        */
-       private synchronized void disconnect(String msg, Exception ex) {                
-               // If already disconnecting, return
-               if (_disconnecting) {
-                       // No need to recursively call
-                       return;
-               }               
-               _disconnecting = true;
-               
-               String disconnectMsg = (msg == null ? "" : msg);
-               if (ex != null) {
-                       disconnectMsg += ", " + ex.toString();
-               } // end-if
-
-               SyncTrace.logTransportEvent("BTTransport.disconnect: " + disconnectMsg, null, InterfaceActivityDirection.Transmit, null, 0, SMARTDEVICELINK_LIB_TRACE_KEY);
-
-               try {                   
-                       if (_transportReader != null) {
-                               _transportReader.halt();
-                               _transportReader = null;
-                       }
-               } catch (Exception e) {
-                       DebugTool.logError("Failed to stop transport reader thread.", e);
-               } // end-catch  
-               
-               try {
-                       if (_bluetoothAdapterMonitor != null) {
-                               _bluetoothAdapterMonitor.halt();
-                               _bluetoothAdapterMonitor = null;
-                       }
-               } catch (Exception e) {
-                       DebugTool.logError("Failed to stop adapter monitor thread.", e);
-               }
-               
-               try {
-                       if (_serverSocket != null) {
-                               _serverSocket.close();
-                               _serverSocket = null;
-                       } 
-               } catch (Exception e) {
-                       DebugTool.logError("Failed to close serverSocket", e);
-               } // end-catch
-               
-               try {
-                       if (_activeSocket != null) {
-                               _activeSocket.close();
-                               _activeSocket = null;
-                       }
-               } catch (Exception e) {
-                       DebugTool.logError("Failed to close activeSocket", e);
-               } // end-catch
-               
-               try {
-                       if (_input != null) {
-                               _input.close();
-                               _input = null;
-                       }
-               } catch (Exception e) {
-                       DebugTool.logError("Failed to close input stream", e);
-               } // end-catch
-               
-               try {
-                       if (_output != null) {
-                               _output.close();
-                               _output = null;
-                       }
-               } catch (Exception e) {
-                       DebugTool.logError("Failed to close output stream", e);
-               } // end-catch
-               
-               if (ex == null) {
-                       // This disconnect was not caused by an error, notify the proxy that 
-                       // the trasport has been disconnected.
-                       handleTransportDisconnected(msg);
-               } else {
-                       // This disconnect was caused by an error, notify the proxy
-                       // that there was a transport error.
-                       handleTransportError(msg, ex);
-               }
-       } // end-method
-
-       
-       /**
-        * Sends data over the transport.  Takes a byte array and transmits data provided starting at the
-        * offset and of the provided length to fragment transmission.
-        */
-       public boolean sendBytesOverTransport(byte[] msgBytes, int offset, int length) {
-               boolean sendResult = false;
-               try {
-                       _output.write(msgBytes, offset, length);
-                       sendResult = true;
-               } catch (Exception ex) {
-                       DebugTool.logError("Error writing to Bluetooth socket: " + ex.toString(), ex);
-                       handleTransportError("Error writing to Bluetooth socket:", ex);
-                       sendResult = false;
-               } // end-catch
-               return sendResult;
-       } // end-method
-       
-       
-       
-       private class TransportReaderThread extends Thread {
-               
-               byte[] buf = new byte[4096];
-               private Boolean isHalted = false;
-               
-               public void halt() {
-                       isHalted = true;
-               }
-               
-               private void acceptConnection() {
-                       SyncTrace.logTransportEvent("BTTransport: Waiting for incoming RFCOMM connect", "", InterfaceActivityDirection.Receive, null, 0, SMARTDEVICELINK_LIB_TRACE_KEY);
-                       
-                       try {
-                               // Blocks thread until connection established.
-                               _activeSocket = _serverSocket.accept();
-                               
-                               // If halted after serverSocket.accept(), then return immediately
-                               if (isHalted) {
-                                       return;
-                               }
-                               
-                               // Log info of the connected device
-                               BluetoothDevice btDevice = _activeSocket.getRemoteDevice();
-                               String btDeviceInfoXml = SyncTrace.getBTDeviceInfo(btDevice);
-                               SyncTrace.logTransportEvent("BTTransport: RFCOMM Connection Accepted", btDeviceInfoXml, InterfaceActivityDirection.Receive, null, 0, SMARTDEVICELINK_LIB_TRACE_KEY);
-                               
-                               _output = _activeSocket.getOutputStream();
-                               _input = _activeSocket.getInputStream();
-
-                               handleTransportConnected();
-                               
-                       } catch (Exception e) {
-                               
-                               if (!isHalted) {                                        
-                                       // Only call disconnect if the thread has not been halted
-                                       
-                                       // Check to see if Bluetooth was disabled
-                                       if (_adapter != null && !_adapter.isEnabled()) {
-                                               disconnect("Bluetooth Adapater has been disabled.", new SmartDeviceLinkException("Bluetooth adapter must be enabled to instantiate a SmartDeviceLinkProxy object.", e, SmartDeviceLinkExceptionCause.BLUETOOTH_DISABLED));
-                                       } else {
-                                               disconnect("Failed to accept connection", e);
-                                       }
-                               } 
-                       } finally {
-                               if (_serverSocket != null && !isHalted) {
-                                       try {
-                                               _serverSocket.close();
-                                       } catch (IOException e) {
-                                               //do nothing
-                                       }
-                                       _serverSocket = null;
-                               }
-                       }
-               }
-               
-               private void readFromTransport() {
-                       try {
-                               int bytesRead = -1;
-                               try {
-                                       bytesRead = _input.read(buf);
-                               } catch (Exception e) {
-                                       if (!isHalted) {
-                                               // Only call disconnect if the thread has not been halted
-                                               
-                                               // Check to see if Bluetooth was disabled
-                                               if (_adapter != null && !_adapter.isEnabled()) {
-                                                       disconnect("Bluetooth Adapater has been disabled.", new SmartDeviceLinkException("Bluetooth adapter must be enabled to instantiate a SmartDeviceLinkProxy object.", e, SmartDeviceLinkExceptionCause.BLUETOOTH_DISABLED));
-                                               } else {
-                                                       disconnect("Failed to read from Bluetooth transport.", e);
-                                               }
-                                       }
-                                       return;
-                               } // end-catch
-                               
-                               if (bytesRead != -1) {
-                                       handleReceivedBytes(buf, bytesRead);
-                               } else {
-                                       // When bytesRead == -1, it indicates end of stream
-                                       if (!isHalted) {
-                                               // Only call disconnect if the thread has not been halted
-                                               DebugTool.logError("End of stream reached!");
-                                               disconnect("End of stream reached.", null);
-                                       }
-                               }
-                       } catch (Exception excp) {
-                               if (!isHalted) {
-                                       // Only call disconnect if the thread has not been halted
-                                       String errString = "Failure in BTTransport reader thread: " + excp.toString();
-                                       DebugTool.logError(errString, excp);
-                                       disconnect(errString, excp);
-                               }
-                               return;
-                       } // end-catch
-               } // end-method
-               
-               public void run() {
-                       // acceptConnection blocks until the connection has been accepted
-                       acceptConnection();
-                       
-                       while (!isHalted) {
-                               readFromTransport();
-                       }
-               }
-       }
-       
-       private class BluetoothAdapterMonitor {
-               private boolean _isHalted = false;
-               private BluetoothAdapter _bluetoothAdapter = null;
-               private final String THREAD_NAME = "BluetoothAdapterMonitor";
-               private Thread _bluetoothAdapterMonitorThread = null;
-               
-               public BluetoothAdapterMonitor(BluetoothAdapter bluetoothAdapter) {
-                       if (bluetoothAdapter == null) {
-                               throw new IllegalArgumentException("BluetoothAdapter cannot be null.");
-                       }
-                       
-                       // Set the bluetooth adapter
-                       _bluetoothAdapter = bluetoothAdapter;
-                       
-                       _bluetoothAdapterMonitorThread = new Thread(new Runnable() {
-                               @Override
-                               public void run() {
-                                       while (!_isHalted) {
-                                               checkIfBluetoothAdapterDisabled();
-                                               try {
-                                                       Thread.sleep(15000);
-                                               } catch (InterruptedException e) {
-                                                       // Break if interrupted
-                                                       break;
-                                               }
-                                       }
-                               }
-                       });
-                       _bluetoothAdapterMonitorThread.setName(THREAD_NAME);
-                       _bluetoothAdapterMonitorThread.setDaemon(true);
-                       _bluetoothAdapterMonitorThread.start();
-               }
-               
-               private void checkIfBluetoothAdapterDisabled() {
-                       if (_bluetoothAdapter != null && !_bluetoothAdapter.isEnabled()) {
-                               // Bluetooth adapter has been disabled, disconnect the transport
-                               disconnect("Bluetooth adapter has been disabled.", 
-                                                  new SmartDeviceLinkException("Bluetooth adapter must be enabled to instantiate a SmartDeviceLinkProxy object.", SmartDeviceLinkExceptionCause.BLUETOOTH_DISABLED));
-                       }
-               }
-               
-               public void halt() {
-                       _isHalted = true;
-                       _bluetoothAdapterMonitorThread.interrupt();
-               }
-       }
-
-       /**
-        * Overridden abstract method which returns specific type of this transport.
-        * 
-        * @return Constant value - TransportType.BLUETOOTH.
-        * 
-        * @see TransportType
-        */
-       public TransportType getTransportType() {
-               return TransportType.BLUETOOTH;
-       }
-} // end-class
+package com.smartdevicelink.transport;\r
+\r
+import java.io.IOException;\r
+import java.io.InputStream;\r
+import java.io.OutputStream;\r
+import java.util.UUID;\r
+\r
+import android.bluetooth.BluetoothAdapter;\r
+import android.bluetooth.BluetoothDevice;\r
+import android.bluetooth.BluetoothServerSocket;\r
+import android.bluetooth.BluetoothSocket;\r
+\r
+import com.smartdevicelink.exception.SmartDeviceLinkException;\r
+import com.smartdevicelink.exception.SmartDeviceLinkExceptionCause;\r
+import com.smartdevicelink.trace.SmartDeviceLinkTrace;\r
+import com.smartdevicelink.trace.enums.InterfaceActivityDirection;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+/**\r
+ * Bluetooth Transport Implementation. This transport advertises its existence to SMARTDEVICELINK by publishing an SDP record and waiting for an incoming connection from SMARTDEVICELINK. Connection is verified by checking for the SMARTDEVICELINK UUID. For more detailed information please refer to the <a href="#bluetoothTransport">Bluetooth Transport Guide</a>.\r
+ *\r
+ */\r
+public class BTTransport extends SmartDeviceLinkTransport {    \r
+       //936DA01F9ABD4D9D80C702AF85C822A8\r
+       private final static UUID SMARTDEVICELINK_V4_MOBILE_APPLICATION_SVC_CLASS = new UUID(0x936DA01F9ABD4D9DL, 0x80C702AF85C822A8L);\r
+\r
+       private static final String SMARTDEVICELINK_LIB_TRACE_KEY = "42baba60-eb57-11df-98cf-0800200c9a66";\r
+       \r
+       private BluetoothAdapter _adapter = null;\r
+       private BluetoothSocket _activeSocket = null;\r
+       private InputStream _input = null;\r
+       private UUID _listeningServiceUUID = SMARTDEVICELINK_V4_MOBILE_APPLICATION_SVC_CLASS;\r
+       private BluetoothAdapterMonitor _bluetoothAdapterMonitor = null;\r
+       private TransportReaderThread _transportReader = null;\r
+       private OutputStream _output = null;\r
+       private BluetoothServerSocket _serverSocket = null;\r
+       \r
+       // Boolean to monitor if the transport is in a disconnecting state\r
+    private boolean _disconnecting = false;\r
+       \r
+       public BTTransport(ITransportListener transportListener) {\r
+               super(transportListener);\r
+       } // end-ctor\r
+       \r
+       public void openConnection () throws SmartDeviceLinkException {         \r
+               \r
+               // Get the device's default Bluetooth Adapter\r
+               _adapter = BluetoothAdapter.getDefaultAdapter();\r
+               \r
+               // Test if Adapter exists\r
+               if (_adapter == null) {\r
+                       throw new SmartDeviceLinkException("No Bluetooth adapter found. Bluetooth adapter must exist to communicate with SMARTDEVICELINK.", SmartDeviceLinkExceptionCause.BLUETOOTH_ADAPTER_NULL);\r
+               }\r
+               \r
+               // Test if Bluetooth is enabled\r
+               try {\r
+                       if (!_adapter.isEnabled()) {\r
+                               throw new SmartDeviceLinkException("Bluetooth adapter must be enabled to instantiate a SMARTDEVICELINKProxy object.", SmartDeviceLinkExceptionCause.BLUETOOTH_DISABLED);\r
+                       }\r
+               } catch (SecurityException e) {\r
+                       throw new SmartDeviceLinkException("Insufficient permissions to interact with the Bluetooth Adapter.", SmartDeviceLinkExceptionCause.PERMISSION_DENIED);\r
+               }\r
+               \r
+               // Start BluetoothAdapterMonitor to ensure the Bluetooth Adapter continues to be enabled\r
+               _bluetoothAdapterMonitor = new BluetoothAdapterMonitor(_adapter);\r
+               \r
+               try {\r
+                       _serverSocket = _adapter.listenUsingRfcommWithServiceRecord("SMARTDEVICELINKProxy", _listeningServiceUUID);\r
+               } catch (IOException ex) {\r
+                       \r
+                       // Test to determine if the bluetooth has been disabled since last check                        \r
+                       if (!_adapter.isEnabled()) {\r
+                               throw new SmartDeviceLinkException("Bluetooth adapter must be on to instantiate a SMARTDEVICELINKProxy object.", SmartDeviceLinkExceptionCause.BLUETOOTH_DISABLED);\r
+                       }\r
+                       \r
+                       throw new SmartDeviceLinkException("Could not open connection to SMARTDEVICELINK.", ex, SmartDeviceLinkExceptionCause.SMARTDEVICELINK_CONNECTION_FAILED);\r
+               } \r
+               \r
+               // Test to ensure serverSocket is not null\r
+               if (_serverSocket == null) {\r
+                       throw new SmartDeviceLinkException("Could not open connection to SMARTDEVICELINK.", SmartDeviceLinkExceptionCause.SMARTDEVICELINK_CONNECTION_FAILED);\r
+               }\r
+               \r
+               SmartDeviceLinkTrace.logTransportEvent("BTTransport: listening for incoming connect to service ID " + _listeningServiceUUID, null, InterfaceActivityDirection.Receive, null, 0, SMARTDEVICELINK_LIB_TRACE_KEY);\r
+               \r
+               // Setup transportReader thread\r
+               _transportReader = new TransportReaderThread();\r
+               _transportReader.setName("TransportReader");\r
+               _transportReader.setDaemon(true);\r
+               _transportReader.start();\r
+               \r
+               // Initialize the SiphonServer\r
+               SiphonServer.init();\r
+       } // end-method\r
+\r
+       public void disconnect() {\r
+               disconnect(null, null);\r
+       }\r
+\r
+       /**\r
+        * Destroys the transport between SMARTDEVICELINK and the mobile app\r
+        * \r
+        * @param msg\r
+        * @param ex\r
+        */\r
+       private synchronized void disconnect(String msg, Exception ex) {                \r
+               // If already disconnecting, return\r
+               if (_disconnecting) {\r
+                       // No need to recursively call\r
+                       return;\r
+               }               \r
+               _disconnecting = true;\r
+               \r
+               String disconnectMsg = (msg == null ? "" : msg);\r
+               if (ex != null) {\r
+                       disconnectMsg += ", " + ex.toString();\r
+               } // end-if\r
+\r
+               SmartDeviceLinkTrace.logTransportEvent("BTTransport.disconnect: " + disconnectMsg, null, InterfaceActivityDirection.Transmit, null, 0, SMARTDEVICELINK_LIB_TRACE_KEY);\r
+\r
+               try {                   \r
+                       if (_transportReader != null) {\r
+                               _transportReader.halt();\r
+                               _transportReader = null;\r
+                       }\r
+               } catch (Exception e) {\r
+                       DebugTool.logError("Failed to stop transport reader thread.", e);\r
+               } // end-catch  \r
+               \r
+               try {\r
+                       if (_bluetoothAdapterMonitor != null) {\r
+                               _bluetoothAdapterMonitor.halt();\r
+                               _bluetoothAdapterMonitor = null;\r
+                       }\r
+               } catch (Exception e) {\r
+                       DebugTool.logError("Failed to stop adapter monitor thread.", e);\r
+               }\r
+               \r
+               try {\r
+                       if (_serverSocket != null) {\r
+                               _serverSocket.close();\r
+                               _serverSocket = null;\r
+                       } \r
+               } catch (Exception e) {\r
+                       DebugTool.logError("Failed to close serverSocket", e);\r
+               } // end-catch\r
+               \r
+               try {\r
+                       if (_activeSocket != null) {\r
+                               _activeSocket.close();\r
+                               _activeSocket = null;\r
+                       }\r
+               } catch (Exception e) {\r
+                       DebugTool.logError("Failed to close activeSocket", e);\r
+               } // end-catch\r
+               \r
+               try {\r
+                       if (_input != null) {\r
+                               _input.close();\r
+                               _input = null;\r
+                       }\r
+               } catch (Exception e) {\r
+                       DebugTool.logError("Failed to close input stream", e);\r
+               } // end-catch\r
+               \r
+               try {\r
+                       if (_output != null) {\r
+                               _output.close();\r
+                               _output = null;\r
+                       }\r
+               } catch (Exception e) {\r
+                       DebugTool.logError("Failed to close output stream", e);\r
+               } // end-catch\r
+               \r
+               if (ex == null) {\r
+                       // This disconnect was not caused by an error, notify the proxy that \r
+                       // the trasport has been disconnected.\r
+                       handleTransportDisconnected(msg);\r
+               } else {\r
+                       // This disconnect was caused by an error, notify the proxy\r
+                       // that there was a transport error.\r
+                       handleTransportError(msg, ex);\r
+               }\r
+       } // end-method\r
+\r
+       \r
+       /**\r
+        * Sends data over the transport.  Takes a byte array and transmits data provided starting at the\r
+        * offset and of the provided length to fragment transmission.\r
+        */\r
+       public boolean sendBytesOverTransport(byte[] msgBytes, int offset, int length) {\r
+               boolean sendResult = false;\r
+               try {\r
+                       _output.write(msgBytes, offset, length);\r
+                       sendResult = true;\r
+               } catch (Exception ex) {\r
+                       DebugTool.logError("Error writing to Bluetooth socket: " + ex.toString(), ex);\r
+                       handleTransportError("Error writing to Bluetooth socket:", ex);\r
+                       sendResult = false;\r
+               } // end-catch\r
+               return sendResult;\r
+       } // end-method\r
+       \r
+       \r
+       \r
+       private class TransportReaderThread extends Thread {\r
+               \r
+               byte[] buf = new byte[4096];\r
+               private Boolean isHalted = false;\r
+               \r
+               public void halt() {\r
+                       isHalted = true;\r
+               }\r
+               \r
+               private void acceptConnection() {\r
+                       SmartDeviceLinkTrace.logTransportEvent("BTTransport: Waiting for incoming RFCOMM connect", "", InterfaceActivityDirection.Receive, null, 0, SMARTDEVICELINK_LIB_TRACE_KEY);\r
+                       \r
+                       try {\r
+                               // Blocks thread until connection established.\r
+                               _activeSocket = _serverSocket.accept();\r
+                               \r
+                               // If halted after serverSocket.accept(), then return immediately\r
+                               if (isHalted) {\r
+                                       return;\r
+                               }\r
+                               \r
+                               // Log info of the connected device\r
+                               BluetoothDevice btDevice = _activeSocket.getRemoteDevice();\r
+                               String btDeviceInfoXml = SmartDeviceLinkTrace.getBTDeviceInfo(btDevice);\r
+                               SmartDeviceLinkTrace.logTransportEvent("BTTransport: RFCOMM Connection Accepted", btDeviceInfoXml, InterfaceActivityDirection.Receive, null, 0, SMARTDEVICELINK_LIB_TRACE_KEY);\r
+                               \r
+                               _output = _activeSocket.getOutputStream();\r
+                               _input = _activeSocket.getInputStream();\r
+\r
+                               handleTransportConnected();\r
+                               \r
+                       } catch (Exception e) {\r
+                               \r
+                               if (!isHalted) {                                        \r
+                                       // Only call disconnect if the thread has not been halted\r
+                                       \r
+                                       // Check to see if Bluetooth was disabled\r
+                                       if (_adapter != null && !_adapter.isEnabled()) {\r
+                                               disconnect("Bluetooth Adapater has been disabled.", new SmartDeviceLinkException("Bluetooth adapter must be enabled to instantiate a SMARTDEVICELINKProxy object.", e, SmartDeviceLinkExceptionCause.BLUETOOTH_DISABLED));\r
+                                       } else {\r
+                                               disconnect("Failed to accept connection", e);\r
+                                       }\r
+                               } \r
+                       } finally {\r
+                               if (_serverSocket != null && !isHalted) {\r
+                                       try {\r
+                                               _serverSocket.close();\r
+                                       } catch (IOException e) {\r
+                                               //do nothing\r
+                                       }\r
+                                       _serverSocket = null;\r
+                               }\r
+                       }\r
+               }\r
+               \r
+               private void readFromTransport() {\r
+                       try {\r
+                               int bytesRead = -1;\r
+                               try {\r
+                                       bytesRead = _input.read(buf);\r
+                               } catch (Exception e) {\r
+                                       if (!isHalted) {\r
+                                               // Only call disconnect if the thread has not been halted\r
+                                               \r
+                                               // Check to see if Bluetooth was disabled\r
+                                               if (_adapter != null && !_adapter.isEnabled()) {\r
+                                                       disconnect("Bluetooth Adapater has been disabled.", new SmartDeviceLinkException("Bluetooth adapter must be enabled to instantiate a SMARTDEVICELINKProxy object.", e, SmartDeviceLinkExceptionCause.BLUETOOTH_DISABLED));\r
+                                               } else {\r
+                                                       disconnect("Failed to read from Bluetooth transport.", e);\r
+                                               }\r
+                                       }\r
+                                       return;\r
+                               } // end-catch\r
+                               \r
+                               if (bytesRead != -1) {\r
+                                       handleReceivedBytes(buf, bytesRead);\r
+                               } else {\r
+                                       // When bytesRead == -1, it indicates end of stream\r
+                                       if (!isHalted) {\r
+                                               // Only call disconnect if the thread has not been halted\r
+                                               DebugTool.logError("End of stream reached!");\r
+                                               disconnect("End of stream reached.", null);\r
+                                       }\r
+                               }\r
+                       } catch (Exception excp) {\r
+                               if (!isHalted) {\r
+                                       // Only call disconnect if the thread has not been halted\r
+                                       String errString = "Failure in BTTransport reader thread: " + excp.toString();\r
+                                       DebugTool.logError(errString, excp);\r
+                                       disconnect(errString, excp);\r
+                               }\r
+                               return;\r
+                       } // end-catch\r
+               } // end-method\r
+               \r
+               public void run() {\r
+                       // acceptConnection blocks until the connection has been accepted\r
+                       acceptConnection();\r
+                       \r
+                       while (!isHalted) {\r
+                               readFromTransport();\r
+                       }\r
+               }\r
+       }\r
+       \r
+       private class BluetoothAdapterMonitor {\r
+               private boolean _isHalted = false;\r
+               private BluetoothAdapter _bluetoothAdapter = null;\r
+               private final String THREAD_NAME = "BluetoothAdapterMonitor";\r
+               private Thread _bluetoothAdapterMonitorThread = null;\r
+               \r
+               public BluetoothAdapterMonitor(BluetoothAdapter bluetoothAdapter) {\r
+                       if (bluetoothAdapter == null) {\r
+                               throw new IllegalArgumentException("BluetoothAdapter cannot be null.");\r
+                       }\r
+                       \r
+                       // Set the bluetooth adapter\r
+                       _bluetoothAdapter = bluetoothAdapter;\r
+                       \r
+                       _bluetoothAdapterMonitorThread = new Thread(new Runnable() {\r
+                               @Override\r
+                               public void run() {\r
+                                       while (!_isHalted) {\r
+                                               checkIfBluetoothAdapterDisabled();\r
+                                               try {\r
+                                                       Thread.sleep(15000);\r
+                                               } catch (InterruptedException e) {\r
+                                                       // Break if interrupted\r
+                                                       break;\r
+                                               }\r
+                                       }\r
+                               }\r
+                       });\r
+                       _bluetoothAdapterMonitorThread.setName(THREAD_NAME);\r
+                       _bluetoothAdapterMonitorThread.setDaemon(true);\r
+                       _bluetoothAdapterMonitorThread.start();\r
+               }\r
+               \r
+               private void checkIfBluetoothAdapterDisabled() {\r
+                       if (_bluetoothAdapter != null && !_bluetoothAdapter.isEnabled()) {\r
+                               // Bluetooth adapter has been disabled, disconnect the transport\r
+                               disconnect("Bluetooth adapter has been disabled.", \r
+                                                  new SmartDeviceLinkException("Bluetooth adapter must be enabled to instantiate a SMARTDEVICELINKProxy object.", SmartDeviceLinkExceptionCause.BLUETOOTH_DISABLED));\r
+                       }\r
+               }\r
+               \r
+               public void halt() {\r
+                       _isHalted = true;\r
+                       _bluetoothAdapterMonitorThread.interrupt();\r
+               }\r
+       }\r
+\r
+       /**\r
+        * Overridden abstract method which returns specific type of this transport.\r
+        * \r
+        * @return Constant value - TransportType.BLUETOOTH.\r
+        * \r
+        * @see TransportType\r
+        */\r
+       public TransportType getTransportType() {\r
+               return TransportType.BLUETOOTH;\r
+       }\r
+} // end-class\r
old mode 100644 (file)
new mode 100755 (executable)
index 88efc1e..a2e7176
@@ -1,22 +1,18 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.transport;
-
-/**
- * Container of Bluetooth transport specific configuration.
- */
-public final class BTTransportConfig extends BaseTransportConfig {
-
-       /**
-        * Overridden abstract method which returns specific type of this transport configuration.
-        * 
-        * @return Constant value TransportType.BLUETOOTH. 
-        * 
-        * @see TransportType
-        */
-       public TransportType getTransportType() {
-               return TransportType.BLUETOOTH;
-       }
-
-}
+package com.smartdevicelink.transport;\r
+\r
+/**\r
+ * Container of Bluetooth transport specific configuration.\r
+ */\r
+public final class BTTransportConfig extends BaseTransportConfig {\r
+\r
+       /**\r
+        * Overridden abstract method which returns specific type of this transport configuration.\r
+        * \r
+        * @return Constant value TransportType.BLUETOOTH. \r
+        * \r
+        * @see TransportType\r
+        */\r
+       public TransportType getTransportType() {\r
+               return TransportType.BLUETOOTH;\r
+       }       \r
+}\r
old mode 100644 (file)
new mode 100755 (executable)
index 1a14aff..e34e5d9
@@ -1,17 +1,15 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.transport;
-
-/**
- * Defines base abstract class for transport configurations.
- */
-public abstract class BaseTransportConfig {
-       
-       /**
-        * Gets transport type for this transport configuration.
-        * 
-        * @return One of {@link TransportType} enumeration values that represents type of this transport configuration.
-        */
-       public abstract TransportType getTransportType();
-}
+package com.smartdevicelink.transport;\r
+\r
+/**\r
+ * Defines base abstract class for transport configurations.\r
+ */\r
+public abstract class BaseTransportConfig {\r
+       \r
+       /**\r
+        * Gets transport type for this transport configuration.\r
+        * \r
+        * @return One of {@link TransportType} enumeration values that represents type of this transport configuration.\r
+        */\r
+       public abstract TransportType getTransportType();       \r
+       \r
+}\r
diff --git a/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/transport/ISmartDeviceLinkTransport.java b/SDL_Android/SmartDeviceLinkProxyAndroid/src/com/smartdevicelink/transport/ISmartDeviceLinkTransport.java
deleted file mode 100755 (executable)
index cff557a..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.transport;
-
-import com.smartdevicelink.exception.SmartDeviceLinkException;
-
-public interface ISmartDeviceLinkTransport {
-       
-       void connect() throws SmartDeviceLinkException;
-
-       void disconnect();
-
-       boolean sendBytes(byte[] message);
-       boolean sendBytes(byte[] message, int offset, int length);
-
-       void addTransportListener(ITransportListener transListener);
-       
-       String getGuid();       
-       String getAppName();    
-       void setAppName(String appName);
-}
index ac8c638..7f4f0b7 100755 (executable)
@@ -1,18 +1,15 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.transport;
-
-public interface ITransportListener {
-       // Called to indicate and deliver bytes received from transport
-       void onTransportBytesReceived(byte[] receivedBytes, int receivedBytesLength);
-
-       // Called to indicate that transport connection was established
-       void onTransportConnected();
-
-       // Called to indicate that transport was disconnected (by either side)
-       void onTransportDisconnected(String info);
-
-       // Called to indicate that some error occurred on the transport
-       void onTransportError(String info, Exception e);
-} // end-interface
+package com.smartdevicelink.transport;\r
+\r
+public interface ITransportListener {\r
+       // Called to indicate and deliver bytes received from transport\r
+       void onTransportBytesReceived(byte[] receivedBytes, int receivedBytesLength);\r
+\r
+       // Called to indicate that transport connection was established\r
+       void onTransportConnected();\r
+\r
+       // Called to indicate that transport was disconnected (by either side)\r
+       void onTransportDisconnected(String info);\r
+\r
+       // Called to indicate that some error occurred on the transport\r
+       void onTransportError(String info, Exception e);\r
+} // end-interface
\ No newline at end of file
index d479d6d..df35026 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.transport;
-
-import java.io.IOException;
-import java.io.OutputStream;
-import java.io.UnsupportedEncodingException;
-import java.net.BindException;
-import java.net.ServerSocket;
-import java.net.Socket;
-
-import com.smartdevicelink.util.*;
-
-public class SiphonServer {
-       // Prohibit use of no-arg ctor
-       private SiphonServer() {}
-       
-       enum SiphonDataType {
-               fromSmartDeviceLink,                            
-               fromApp,                                
-               appLog,
-               formattedTrace,
-               baselineTimeStamp,              
-               traceSettings                   
-       }
-       
-       // Boolean to enable/disable the siphon
-       private static Boolean m_siphonEnabled = false;
-       
-       // Boolean to determine if the siphon has been initialized
-       private static Boolean m_siphonInitialized = false;
-       
-       private static Socket m_siphonSocket = null;
-       private static Object m_siphonLock = new Object();
-       private static ServerSocket m_listeningSocket = null;
-       private static OutputStream m_siphonSocketOutputStream = null;
-       private static SiphonServerThread m_siphonClientThread = null;
-       
-       // Initial timestamp in MS
-       private static long m_startTimeStamp = 0;
-       
-       // SmartDeviceLink Trace Message Version
-       private static byte m_SyncTraceMsgVersionNumber = 1;
-       
-       // Max number of ports to attempt a connection on
-       private final static Integer MAX_NUMBER_OF_PORT_ATTEMPTS = 1000;
-       
-       // Starting port for future port attempts
-       private final static short FIRST_PORT_TO_ATTEMPT_CONNECTION = 7474;
-
-       // Boolean to determine if formatted trace is being sent
-       private static Boolean m_sendingFormattedTrace = false;
-       
-       public static void enableSiphonServer() {
-               m_siphonEnabled = true;
-       }
-       
-       public static void disableSiphonServer() {
-               m_siphonEnabled = false;
-       }
-
-       public static boolean init() {          
-               // Only initialize if the siphon has not been initialized previously
-
-               // Check here to be lean. If true, no need to SmartDeviceLinkhronize
-               if (m_siphonInitialized) {
-                       return true;
-               }
-               
-               synchronized (m_siphonLock) {
-                       // To prevent a race condition, re-check m_siphonInitialized inside of SmartDeviceLinkhronize block
-                       if (!m_siphonInitialized) {
-                               if (m_siphonClientThread == null) {
-                                       // Set current time stamp 
-                                       m_startTimeStamp = System.currentTimeMillis();
-                                       
-                                       // Start Siphon Thread
-                           m_siphonClientThread = new SiphonServerThread();
-                               m_siphonClientThread.setName("Siphon");
-                               m_siphonClientThread.setDaemon(true);
-                               m_siphonClientThread.start();
-                               
-                               m_siphonInitialized = true;
-                               } // end-if
-                       } // end-lock
-               }
-               
-               return m_siphonInitialized;
-       } // end-method
-
-       public static void closeServer() throws IOException {
-               
-               if (m_siphonClientThread != null) {
-                       m_siphonClientThread.halt();
-                       m_siphonClientThread = null;
-               }
-               
-               if (m_listeningSocket != null) {
-                       m_listeningSocket.close();
-                       m_listeningSocket = null;
-               }
-               
-               if (m_siphonSocket != null) {
-                       m_siphonSocket.close();
-                       m_siphonSocket = null;
-               }
-               
-               if (m_siphonSocketOutputStream != null) {
-                       m_siphonSocketOutputStream.close();
-                       m_siphonSocketOutputStream = null;
-               }
-       }
-    
-       public static Boolean sendBytesFromAPP(byte[] msgBytes, int offset, int length) {
-               
-               if (m_sendingFormattedTrace) {
-                       return false;
-               }
-               
-               return sendSiphonData(SiphonDataType.fromApp, msgBytes, offset, length);
-       } // end-method
-
-       public static Boolean sendBytesFromSmartDeviceLink(byte[] msgBytes, int offset, int length) {           
-
-               if (m_sendingFormattedTrace) {
-                       return false;
-               }
-               
-               return sendSiphonData(SiphonDataType.fromSmartDeviceLink, msgBytes, offset, length);
-       } // end-method
-       
-       public static Boolean sendSiphonLogData(String message) {
-               
-               if (m_sendingFormattedTrace) {
-                       return false;
-               }
-               
-               if (message == null || message.length() == 0) {
-                       return false;
-               }
-                               
-               byte messageBytes[] = null;
-               int messageLength = 0;
-               
-               try {
-                       messageBytes = message.getBytes("UTF-8");
-               } catch (UnsupportedEncodingException e) {
-                       return false;
-               }
-               
-               messageLength = messageBytes.length;
-               return sendSiphonData(SiphonDataType.appLog, messageBytes, 0, messageLength);
-               
-       }
-       
-       public static Boolean sendFormattedTraceMessage(String message) {
-                               
-               if (message == null || message.length() == 0) {
-                       return false;
-               }
-               
-               byte messageBytes[] = null;
-               int messageLength = 0;
-                               
-               try {
-                       messageBytes = message.getBytes("UTF-8");
-               } catch (UnsupportedEncodingException e) {
-                       return false;
-               }
-               
-               messageLength = messageBytes.length;
-               if (sendSiphonData(SiphonDataType.formattedTrace, messageBytes, 0, messageLength)) {
-                       m_sendingFormattedTrace = true;
-                       return true;
-               } else {
-                       return false;
-               }
-       }
-       
-       private static Boolean sendSiphonData(SiphonDataType direction, byte[] msgBytes, int offset, int length) {
-               byte siphonDataTypeIndicator = 0x00;
-               
-               long currentDateTime = System.currentTimeMillis();
-               Integer deltaTimeMills = null;
-                       
-               deltaTimeMills = (int)(currentDateTime - m_startTimeStamp);
-               
-               switch(direction) {
-                       case fromSmartDeviceLink:
-                               siphonDataTypeIndicator = 0x00;
-                               break;
-                       case fromApp:
-                               siphonDataTypeIndicator = 0x01;
-                               break;
-                       case appLog:
-                               siphonDataTypeIndicator = 0x02;
-                               break;
-                       case formattedTrace:
-                               siphonDataTypeIndicator = 0x03;
-                               break;
-                       case baselineTimeStamp:
-                               siphonDataTypeIndicator = 0x04;
-                               break;
-                       case traceSettings:
-                               siphonDataTypeIndicator = 0x05;
-                               break;
-                       default:
-                               siphonDataTypeIndicator = 0x00;
-                               break;
-               }
-               
-               // Set high bit to indicate new format
-               siphonDataTypeIndicator = (byte)((byte)0x80 | siphonDataTypeIndicator);
-               
-               return sendDataToSiphonSocket(siphonDataTypeIndicator, deltaTimeMills, msgBytes, offset, length);
-       }
-       
-       private synchronized static Boolean sendDataToSiphonSocket(byte directionIndicator, Integer timeStamp, 
-                       byte[] msgBytes, int offset, int length) {
-               if (!m_siphonEnabled) {
-                       return false;
-               }
-               
-               if (msgBytes == null || length == 0) {
-                       return false;
-               }
-               
-               OutputStream siphonOutputStream = null;
-
-               synchronized (m_siphonLock) {
-                       siphonOutputStream = m_siphonSocketOutputStream;
-               } // end-lock
-
-               if (siphonOutputStream == null) {
-                       return false;
-               }               
-               
-               try     {               
-                       // blobSize = length(of message) + 1(size of direction indicator)
-                       //                              + 1 (size of msgVersionNumber) + 4 (size of timeStamp)
-                       int blobSize = length + 1 + 1 + 4;
-                       
-                       siphonOutputStream.write(BitConverter.intToByteArray(blobSize));
-                       siphonOutputStream.write(new byte[] {directionIndicator});
-                       siphonOutputStream.write(new byte[] {m_SyncTraceMsgVersionNumber});
-                       siphonOutputStream.write(intToByteArray(timeStamp));
-                       siphonOutputStream.write(msgBytes, offset, length);
-               } catch (Exception ex) {
-                       return false;
-               } // end-catch
-               
-               return true;
-       } // end-method
-    
-    private static class SiphonServerThread extends Thread {
-       
-       private Boolean isHalted = false;
-       short listenPort;
-               
-               public void halt() {
-                       isHalted = true;
-               }
-       
-       private boolean findOpenSocket(short port) {
-               // Accept incoming sihpon connection from trace utility.
-               Boolean foundOpenPort = false;
-               listenPort = port;
-               
-               // Listen to accept incoming connection from SmartDeviceLink
-               while (!foundOpenPort) {
-                       try {
-                               m_listeningSocket = new ServerSocket(listenPort);
-                               foundOpenPort = true;
-                       } catch (BindException ex) {
-                               listenPort++;
-                               if(listenPort > port + MAX_NUMBER_OF_PORT_ATTEMPTS) {
-                                       return false;
-                               }
-                       } catch (IOException e) {
-                               return false;
-                               }
-               }
-               
-               return foundOpenPort;
-       }
-       
-       private void startServerOnPort() throws IOException {
-               Socket newSocket = null;
-               
-               // Wait for a connection
-               newSocket = m_listeningSocket.accept(); 
-            
-            // If isHalted after accept() delay, return
-               if (isHalted) {
-                       return;
-               }
-
-               synchronized (m_siphonLock) {
-                       // Reset siphonSocketOutputStream
-                       if (m_siphonSocketOutputStream != null) {
-                               try {
-                                       m_siphonSocketOutputStream.close();
-                               } catch (IOException e) {
-                                       // Do nothing
-                               }
-                               m_siphonSocketOutputStream = null;
-                       }
-
-                       // Reset siphonSocket
-                       if (m_siphonSocket != null) {
-                               try {
-                                       m_siphonSocket.close();
-                               } catch (IOException e) {
-                                       // Do nothing
-                               }
-                               m_siphonSocket = null;
-                       }
-
-                       // Store the new socket
-                       m_siphonSocket = newSocket;
-                       
-                       // Set Socket Options
-                               m_siphonSocket.setKeepAlive(true);
-                               
-                               // Get the output stream of the connection
-                               m_siphonSocketOutputStream = m_siphonSocket.getOutputStream();
-                               
-                       // Output version number to the Siphon upon connection (version number prepending to logInfo)
-                               DebugTool.logInfo("Siphon connected.");
-               } // end-lock
-        } // end-method
-       
-       @Override
-       public void run() {
-               try     {
-                       if (findOpenSocket(FIRST_PORT_TO_ATTEMPT_CONNECTION)) {
-                               while (!isHalted) {
-                                       startServerOnPort();
-                               }
-                       } 
-               } catch (Exception ex) {
-                       // Do nothing
-               } finally {
-                               if (m_listeningSocket != null) {
-                                       try {
-                                               m_listeningSocket.close();
-                                       } catch (IOException e) {
-                                               // Do nothing
-                                       }
-                                       m_listeningSocket = null;
-                               }
-                       }
-       }
-    }
-    
-    private static final byte[] intToByteArray(int value) {
-        return new byte[] {
-                (byte)(value >>> 24),
-                (byte)(value >>> 16),
-                (byte)(value >>> 8),
-                (byte)value};
-    }
-} // end-class
+package com.smartdevicelink.transport;\r
+\r
+import java.io.IOException;\r
+import java.io.OutputStream;\r
+import java.io.UnsupportedEncodingException;\r
+import java.net.BindException;\r
+import java.net.ServerSocket;\r
+import java.net.Socket;\r
+\r
+import com.smartdevicelink.util.*;\r
+\r
+public class SiphonServer {\r
+       // Prohibit use of no-arg ctor\r
+       private SiphonServer() {}\r
+       \r
+       enum SiphonDataType {\r
+               fromSmartDeviceLink,                            \r
+               fromApp,                                \r
+               appLog,\r
+               formattedTrace,\r
+               baselineTimeStamp,              \r
+               traceSettings                   \r
+       }\r
+       \r
+       // Boolean to enable/disable the siphon\r
+       private static Boolean m_siphonEnabled = false;\r
+       \r
+       // Boolean to determine if the siphon has been initialized\r
+       private static Boolean m_siphonInitialized = false;\r
+       \r
+       private static Socket m_siphonSocket = null;\r
+       private static Object m_siphonLock = new Object();\r
+       private static ServerSocket m_listeningSocket = null;\r
+       private static OutputStream m_siphonSocketOutputStream = null;\r
+       private static SiphonServerThread m_siphonClientThread = null;\r
+       \r
+       // Initial timestamp in MS\r
+       private static long m_startTimeStamp = 0;\r
+       \r
+       // SMARTDEVICELINK Trace Message Version\r
+       private static byte m_smartDeviceLinkTraceMsgVersionNumber = 1;\r
+       \r
+       // Max number of ports to attempt a connection on\r
+       private final static Integer MAX_NUMBER_OF_PORT_ATTEMPTS = 1000;\r
+       \r
+       // Starting port for future port attempts\r
+       private final static short FIRST_PORT_TO_ATTEMPT_CONNECTION = 7474;\r
+\r
+       // Boolean to determine if formatted trace is being sent\r
+       private static Boolean m_sendingFormattedTrace = false;\r
+       \r
+       public static void enableSiphonServer() {\r
+               m_siphonEnabled = true;\r
+       }\r
+       \r
+       public static void disableSiphonServer() {\r
+               m_siphonEnabled = false;\r
+       }\r
+\r
+       public static boolean init() {          \r
+               // Only initialize if the siphon has not been initialized previously\r
+\r
+               // Check here to be lean. If true, no need to smartDeviceLinkhronize\r
+               if (m_siphonInitialized) {\r
+                       return true;\r
+               }\r
+               \r
+               synchronized (m_siphonLock) {\r
+                       // To prevent a race condition, re-check m_siphonInitialized inside of smartDeviceLinkhronize block\r
+                       if (!m_siphonInitialized) {\r
+                               if (m_siphonClientThread == null) {\r
+                                       // Set current time stamp \r
+                                       m_startTimeStamp = System.currentTimeMillis();\r
+                                       \r
+                                       // Start Siphon Thread\r
+                           m_siphonClientThread = new SiphonServerThread();\r
+                               m_siphonClientThread.setName("Siphon");\r
+                               m_siphonClientThread.setDaemon(true);\r
+                               m_siphonClientThread.start();\r
+                               \r
+                               m_siphonInitialized = true;\r
+                               } // end-if\r
+                       } // end-lock\r
+               }\r
+               \r
+               return m_siphonInitialized;\r
+       } // end-method\r
+\r
+       public static void closeServer() throws IOException {\r
+               \r
+               if (m_siphonClientThread != null) {\r
+                       m_siphonClientThread.halt();\r
+                       m_siphonClientThread = null;\r
+               }\r
+               \r
+               if (m_listeningSocket != null) {\r
+                       m_listeningSocket.close();\r
+                       m_listeningSocket = null;\r
+               }\r
+               \r
+               if (m_siphonSocket != null) {\r
+                       m_siphonSocket.close();\r
+                       m_siphonSocket = null;\r
+               }\r
+               \r
+               if (m_siphonSocketOutputStream != null) {\r
+                       m_siphonSocketOutputStream.close();\r
+                       m_siphonSocketOutputStream = null;\r
+               }\r
+       }\r
+    \r
+       public static Boolean sendBytesFromAPP(byte[] msgBytes, int offset, int length) {\r
+               \r
+               if (m_sendingFormattedTrace) {\r
+                       return false;\r
+               }\r
+               \r
+               return sendSiphonData(SiphonDataType.fromApp, msgBytes, offset, length);\r
+       } // end-method\r
+\r
+       public static Boolean sendBytesFromSMARTDEVICELINK(byte[] msgBytes, int offset, int length) {           \r
+\r
+               if (m_sendingFormattedTrace) {\r
+                       return false;\r
+               }\r
+               \r
+               return sendSiphonData(SiphonDataType.fromSmartDeviceLink, msgBytes, offset, length);\r
+       } // end-method\r
+       \r
+       public static Boolean sendSiphonLogData(String message) {\r
+               \r
+               if (m_sendingFormattedTrace) {\r
+                       return false;\r
+               }\r
+               \r
+               if (message == null || message.length() == 0) {\r
+                       return false;\r
+               }\r
+                               \r
+               byte messageBytes[] = null;\r
+               int messageLength = 0;\r
+               \r
+               try {\r
+                       messageBytes = message.getBytes("UTF-8");\r
+               } catch (UnsupportedEncodingException e) {\r
+                       return false;\r
+               }\r
+               \r
+               messageLength = messageBytes.length;\r
+               return sendSiphonData(SiphonDataType.appLog, messageBytes, 0, messageLength);\r
+               \r
+       }\r
+       \r
+       public static Boolean sendFormattedTraceMessage(String message) {\r
+                               \r
+               if (message == null || message.length() == 0) {\r
+                       return false;\r
+               }\r
+               \r
+               byte messageBytes[] = null;\r
+               int messageLength = 0;\r
+                               \r
+               try {\r
+                       messageBytes = message.getBytes("UTF-8");\r
+               } catch (UnsupportedEncodingException e) {\r
+                       return false;\r
+               }\r
+               \r
+               messageLength = messageBytes.length;\r
+               if (sendSiphonData(SiphonDataType.formattedTrace, messageBytes, 0, messageLength)) {\r
+                       m_sendingFormattedTrace = true;\r
+                       return true;\r
+               } else {\r
+                       return false;\r
+               }\r
+       }\r
+       \r
+       private static Boolean sendSiphonData(SiphonDataType direction, byte[] msgBytes, int offset, int length) {\r
+               byte siphonDataTypeIndicator = 0x00;\r
+               \r
+               long currentDateTime = System.currentTimeMillis();\r
+               Integer deltaTimeMills = null;\r
+                       \r
+               deltaTimeMills = (int)(currentDateTime - m_startTimeStamp);\r
+               \r
+               switch(direction) {\r
+                       case fromSmartDeviceLink:\r
+                               siphonDataTypeIndicator = 0x00;\r
+                               break;\r
+                       case fromApp:\r
+                               siphonDataTypeIndicator = 0x01;\r
+                               break;\r
+                       case appLog:\r
+                               siphonDataTypeIndicator = 0x02;\r
+                               break;\r
+                       case formattedTrace:\r
+                               siphonDataTypeIndicator = 0x03;\r
+                               break;\r
+                       case baselineTimeStamp:\r
+                               siphonDataTypeIndicator = 0x04;\r
+                               break;\r
+                       case traceSettings:\r
+                               siphonDataTypeIndicator = 0x05;\r
+                               break;\r
+                       default:\r
+                               siphonDataTypeIndicator = 0x00;\r
+                               break;\r
+               }\r
+               \r
+               // Set high bit to indicate new format\r
+               siphonDataTypeIndicator = (byte)((byte)0x80 | siphonDataTypeIndicator);\r
+               \r
+               return sendDataToSiphonSocket(siphonDataTypeIndicator, deltaTimeMills, msgBytes, offset, length);\r
+       }\r
+       \r
+       private synchronized static Boolean sendDataToSiphonSocket(byte directionIndicator, Integer timeStamp, \r
+                       byte[] msgBytes, int offset, int length) {\r
+               if (!m_siphonEnabled) {\r
+                       return false;\r
+               }\r
+               \r
+               if (msgBytes == null || length == 0) {\r
+                       return false;\r
+               }\r
+               \r
+               OutputStream siphonOutputStream = null;\r
+\r
+               synchronized (m_siphonLock) {\r
+                       siphonOutputStream = m_siphonSocketOutputStream;\r
+               } // end-lock\r
+\r
+               if (siphonOutputStream == null) {\r
+                       return false;\r
+               }               \r
+               \r
+               try     {               \r
+                       // blobSize = length(of message) + 1(size of direction indicator)\r
+                       //                              + 1 (size of msgVersionNumber) + 4 (size of timeStamp)\r
+                       int blobSize = length + 1 + 1 + 4;\r
+                       \r
+                       siphonOutputStream.write(BitConverter.intToByteArray(blobSize));\r
+                       siphonOutputStream.write(new byte[] {directionIndicator});\r
+                       siphonOutputStream.write(new byte[] {m_smartDeviceLinkTraceMsgVersionNumber});\r
+                       siphonOutputStream.write(intToByteArray(timeStamp));\r
+                       siphonOutputStream.write(msgBytes, offset, length);\r
+               } catch (Exception ex) {\r
+                       return false;\r
+               } // end-catch\r
+               \r
+               return true;\r
+       } // end-method\r
+    \r
+    private static class SiphonServerThread extends Thread {\r
+       \r
+       private Boolean isHalted = false;\r
+       short listenPort;\r
+               \r
+               public void halt() {\r
+                       isHalted = true;\r
+               }\r
+       \r
+       private boolean findOpenSocket(short port) {\r
+               // Accept incoming sihpon connection from trace utility.\r
+               Boolean foundOpenPort = false;\r
+               listenPort = port;\r
+               \r
+               // Listen to accept incoming connection from SMARTDEVICELINK\r
+               while (!foundOpenPort) {\r
+                       try {\r
+                               m_listeningSocket = new ServerSocket(listenPort);\r
+                               foundOpenPort = true;\r
+                       } catch (BindException ex) {\r
+                               listenPort++;\r
+                               if(listenPort > port + MAX_NUMBER_OF_PORT_ATTEMPTS) {\r
+                                       return false;\r
+                               }\r
+                       } catch (IOException e) {\r
+                               return false;\r
+                               }\r
+               }\r
+               \r
+               return foundOpenPort;\r
+       }\r
+       \r
+       private void startServerOnPort() throws IOException {\r
+               Socket newSocket = null;\r
+               \r
+               // Wait for a connection\r
+               newSocket = m_listeningSocket.accept(); \r
+            \r
+            // If isHalted after accept() delay, return\r
+               if (isHalted) {\r
+                       return;\r
+               }\r
+\r
+               synchronized (m_siphonLock) {\r
+                       // Reset siphonSocketOutputStream\r
+                       if (m_siphonSocketOutputStream != null) {\r
+                               try {\r
+                                       m_siphonSocketOutputStream.close();\r
+                               } catch (IOException e) {\r
+                                       // Do nothing\r
+                               }\r
+                               m_siphonSocketOutputStream = null;\r
+                       }\r
+\r
+                       // Reset siphonSocket\r
+                       if (m_siphonSocket != null) {\r
+                               try {\r
+                                       m_siphonSocket.close();\r
+                               } catch (IOException e) {\r
+                                       // Do nothing\r
+                               }\r
+                               m_siphonSocket = null;\r
+                       }\r
+\r
+                       // Store the new socket\r
+                       m_siphonSocket = newSocket;\r
+                       \r
+                       // Set Socket Options\r
+                               m_siphonSocket.setKeepAlive(true);\r
+                               \r
+                               // Get the output stream of the connection\r
+                               m_siphonSocketOutputStream = m_siphonSocket.getOutputStream();\r
+                               \r
+                       // Output version number to the Siphon upon connection (version number prepending to logInfo)\r
+                               DebugTool.logInfo("Siphon connected.");\r
+               } // end-lock\r
+        } // end-method\r
+       \r
+       @Override\r
+       public void run() {\r
+               try     {\r
+                       if (findOpenSocket(FIRST_PORT_TO_ATTEMPT_CONNECTION)) {\r
+                               while (!isHalted) {\r
+                                       startServerOnPort();\r
+                               }\r
+                       } \r
+               } catch (Exception ex) {\r
+                       // Do nothing\r
+               } finally {\r
+                               if (m_listeningSocket != null) {\r
+                                       try {\r
+                                               m_listeningSocket.close();\r
+                                       } catch (IOException e) {\r
+                                               // Do nothing\r
+                                       }\r
+                                       m_listeningSocket = null;\r
+                               }\r
+                       }\r
+       }\r
+    }\r
+    \r
+    private static final byte[] intToByteArray(int value) {\r
+        return new byte[] {\r
+                (byte)(value >>> 24),\r
+                (byte)(value >>> 16),\r
+                (byte)(value >>> 8),\r
+                (byte)value};\r
+    }\r
+} // end-class
\ No newline at end of file
index 7f3e8d4..04ab6a6 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.transport;
-
-import com.smartdevicelink.exception.SmartDeviceLinkException;
-import com.smartdevicelink.trace.SyncTrace;
-import com.smartdevicelink.trace.enums.InterfaceActivityDirection;
-import com.smartdevicelink.util.DebugTool;
-
-public abstract class SmartDeviceLinkTransport {
-       private static final String SMARTDEVICELINK_LIB_TRACE_KEY = "42baba60-eb57-11df-98cf-0800200c9a66";
-       
-       private final static String FailurePropagating_Msg = "Failure propagating ";
-       private Boolean isConnected = false;
-       
-       private String _sendLockObj = "lock";
-       
-       // Get status of transport connection
-       public Boolean getIsConnected() {
-               return isConnected;
-       }
-
-    //protected SmartDeviceLinkTransport(String endpointName, String param2, ITransportListener transportListener)
-    protected SmartDeviceLinkTransport(ITransportListener transportListener) {
-       if (transportListener == null) {
-               throw new IllegalArgumentException("Provided transport listener interface reference is null");
-       } // end-if
-       _transportListener = transportListener;
-    } // end-method
-    
-    // This method is called by the subclass to indicate that data has arrived from
-    // the transport.
-    protected void handleReceivedBytes(byte[] receivedBytes, int receivedBytesLength) {
-               try {
-                       // Trace received data
-                       if (receivedBytesLength > 0) {
-                               // Send transport data to the siphon server
-                               SiphonServer.sendBytesFromSmartDeviceLink(receivedBytes, 0, receivedBytesLength);
-                               SyncTrace.logTransportEvent("", null, InterfaceActivityDirection.Receive, receivedBytes, receivedBytesLength, SMARTDEVICELINK_LIB_TRACE_KEY);
-                               
-                               _transportListener.onTransportBytesReceived(receivedBytes, receivedBytesLength);
-                       } // end-if
-               } catch (Exception excp) {
-                       DebugTool.logError(FailurePropagating_Msg + "handleBytesFromTransport: " + excp.toString(), excp);
-                       handleTransportError(FailurePropagating_Msg, excp);
-               } // end-catch
-    } // end-method
-
-    // This method must be implemented by transport subclass, and is called by this
-    // base class to actually send an array of bytes out over the transport.  This
-    // method is meant to only be callable within the class hierarchy.
-    protected abstract boolean sendBytesOverTransport(byte[] msgBytes, int offset, int length);
-
-    // This method is called by whomever has reference to transport to have bytes
-    // sent out over transport.
-    public boolean sendBytes(byte[] message) {
-        return sendBytes(message, 0, message.length);
-    } // end-method
-    
-    // This method is called by whomever has reference to transport to have bytes
-    // sent out over transport.
-    public boolean sendBytes(byte[] message, int offset, int length) {
-        boolean bytesWereSent = false;
-        synchronized (_sendLockObj) {
-               bytesWereSent = sendBytesOverTransport(message, offset, length);
-        } // end-lock
-        // Send transport data to the siphon server
-               SiphonServer.sendBytesFromAPP(message, offset, length);
-        
-               SyncTrace.logTransportEvent("", null, InterfaceActivityDirection.Transmit, message, offset, length, SMARTDEVICELINK_LIB_TRACE_KEY);
-        return bytesWereSent;
-    } // end-method
-
-    private ITransportListener _transportListener = null;
-
-    // This method is called by the subclass to indicate that transport connection
-    // has been established.
-       protected void handleTransportConnected() {
-               isConnected = true;
-               try {
-               SyncTrace.logTransportEvent("Transport.connected", null, InterfaceActivityDirection.Receive, null, 0, SMARTDEVICELINK_LIB_TRACE_KEY);
-                       _transportListener.onTransportConnected();
-               } catch (Exception excp) {
-                       DebugTool.logError(FailurePropagating_Msg + "onTransportConnected: " + excp.toString(), excp);
-                       handleTransportError(FailurePropagating_Msg + "onTransportConnected", excp);
-               } // end-catch
-       } // end-method
-       
-    // This method is called by the subclass to indicate that transport disconnection
-    // has occurred.
-       protected void handleTransportDisconnected(final String info) {
-               isConnected = false;
-
-               try {
-               SyncTrace.logTransportEvent("Transport.disconnect: " + info, null, InterfaceActivityDirection.Transmit, null, 0, SMARTDEVICELINK_LIB_TRACE_KEY);
-                       _transportListener.onTransportDisconnected(info);
-               } catch (Exception excp) {
-                       DebugTool.logError(FailurePropagating_Msg + "onTransportDisconnected: " + excp.toString(), excp);
-               } // end-catch
-       } // end-method
-       
-       // This method is called by the subclass to indicate a transport error has occurred.
-       protected void handleTransportError(final String message, final Exception ex) {
-               isConnected = false;
-               _transportListener.onTransportError(message, ex);
-       }
-
-       public abstract void openConnection() throws SmartDeviceLinkException;
-       public abstract void disconnect();
-       
-       /**
-        * Abstract method which should be implemented by subclasses in order to return actual type of the transport. 
-        * 
-        * @return One of {@link TransportType} enumeration values.
-        * 
-        * @see TransportType
-        */
-       public abstract TransportType getTransportType();
-} // end-class
+package com.smartdevicelink.transport;\r
+\r
+import com.smartdevicelink.exception.SmartDeviceLinkException;\r
+import com.smartdevicelink.trace.SmartDeviceLinkTrace;\r
+import com.smartdevicelink.trace.enums.InterfaceActivityDirection;\r
+import com.smartdevicelink.util.DebugTool;\r
+\r
+public abstract class SmartDeviceLinkTransport {\r
+       private static final String SMARTDEVICELINK_LIB_TRACE_KEY = "42baba60-eb57-11df-98cf-0800200c9a66";\r
+       \r
+       private final static String FailurePropagating_Msg = "Failure propagating ";\r
+       private Boolean isConnected = false;\r
+       \r
+       private String _sendLockObj = "lock";\r
+       \r
+       // Get status of transport connection\r
+       public Boolean getIsConnected() {\r
+               return isConnected;\r
+       }\r
+\r
+    //protected SmartDeviceLinkTransport(String endpointName, String param2, ITransportListener transportListener)\r
+    protected SmartDeviceLinkTransport(ITransportListener transportListener) {\r
+       if (transportListener == null) {\r
+               throw new IllegalArgumentException("Provided transport listener interface reference is null");\r
+       } // end-if\r
+       _transportListener = transportListener;\r
+    } // end-method\r
+    \r
+    // This method is called by the subclass to indicate that data has arrived from\r
+    // the transport.\r
+    protected void handleReceivedBytes(byte[] receivedBytes, int receivedBytesLength) {\r
+               try {\r
+                       // Trace received data\r
+                       if (receivedBytesLength > 0) {\r
+                               // Send transport data to the siphon server\r
+                               SiphonServer.sendBytesFromSMARTDEVICELINK(receivedBytes, 0, receivedBytesLength);\r
+                               SmartDeviceLinkTrace.logTransportEvent("", null, InterfaceActivityDirection.Receive, receivedBytes, receivedBytesLength, SMARTDEVICELINK_LIB_TRACE_KEY);\r
+                               \r
+                               _transportListener.onTransportBytesReceived(receivedBytes, receivedBytesLength);\r
+                       } // end-if\r
+               } catch (Exception excp) {\r
+                       DebugTool.logError(FailurePropagating_Msg + "handleBytesFromTransport: " + excp.toString(), excp);\r
+                       handleTransportError(FailurePropagating_Msg, excp);\r
+               } // end-catch\r
+    } // end-method\r
+\r
+    // This method must be implemented by transport subclass, and is called by this\r
+    // base class to actually send an array of bytes out over the transport.  This\r
+    // method is meant to only be callable within the class hierarchy.\r
+    protected abstract boolean sendBytesOverTransport(byte[] msgBytes, int offset, int length);\r
+\r
+    // This method is called by whomever has reference to transport to have bytes\r
+    // sent out over transport.\r
+    public boolean sendBytes(byte[] message) {\r
+        return sendBytes(message, 0, message.length);\r
+    } // end-method\r
+    \r
+    // This method is called by whomever has reference to transport to have bytes\r
+    // sent out over transport.\r
+    public boolean sendBytes(byte[] message, int offset, int length) {\r
+        boolean bytesWereSent = false;\r
+        synchronized (_sendLockObj) {\r
+               bytesWereSent = sendBytesOverTransport(message, offset, length);\r
+        } // end-lock\r
+        // Send transport data to the siphon server\r
+               SiphonServer.sendBytesFromAPP(message, offset, length);\r
+        \r
+               SmartDeviceLinkTrace.logTransportEvent("", null, InterfaceActivityDirection.Transmit, message, offset, length, SMARTDEVICELINK_LIB_TRACE_KEY);\r
+        return bytesWereSent;\r
+    } // end-method\r
+\r
+    private ITransportListener _transportListener = null;\r
+\r
+    // This method is called by the subclass to indicate that transport connection\r
+    // has been established.\r
+       protected void handleTransportConnected() {\r
+               isConnected = true;\r
+               try {\r
+               SmartDeviceLinkTrace.logTransportEvent("Transport.connected", null, InterfaceActivityDirection.Receive, null, 0, SMARTDEVICELINK_LIB_TRACE_KEY);\r
+                       _transportListener.onTransportConnected();\r
+               } catch (Exception excp) {\r
+                       DebugTool.logError(FailurePropagating_Msg + "onTransportConnected: " + excp.toString(), excp);\r
+                       handleTransportError(FailurePropagating_Msg + "onTransportConnected", excp);\r
+               } // end-catch\r
+       } // end-method\r
+       \r
+    // This method is called by the subclass to indicate that transport disconnection\r
+    // has occurred.\r
+       protected void handleTransportDisconnected(final String info) {\r
+               isConnected = false;\r
+\r
+               try {\r
+               SmartDeviceLinkTrace.logTransportEvent("Transport.disconnect: " + info, null, InterfaceActivityDirection.Transmit, null, 0, SMARTDEVICELINK_LIB_TRACE_KEY);\r
+                       _transportListener.onTransportDisconnected(info);\r
+               } catch (Exception excp) {\r
+                       DebugTool.logError(FailurePropagating_Msg + "onTransportDisconnected: " + excp.toString(), excp);\r
+               } // end-catch\r
+       } // end-method\r
+       \r
+       // This method is called by the subclass to indicate a transport error has occurred.\r
+       protected void handleTransportError(final String message, final Exception ex) {\r
+               isConnected = false;\r
+               _transportListener.onTransportError(message, ex);\r
+       }\r
+\r
+       public abstract void openConnection() throws SmartDeviceLinkException;\r
+       public abstract void disconnect();\r
+       \r
+       /**\r
+        * Abstract method which should be implemented by subclasses in order to return actual type of the transport. \r
+        * \r
+        * @return One of {@link TransportType} enumeration values.\r
+        * \r
+        * @see TransportType\r
+        */\r
+       public abstract TransportType getTransportType();\r
+} // end-class\r
index 465f3d8..beee9d7 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.transport;
-
-import android.util.Log;
-import com.smartdevicelink.exception.SmartDeviceLinkException;
-import com.smartdevicelink.exception.SmartDeviceLinkExceptionCause;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.OutputStream;
-import java.net.InetSocketAddress;
-import java.net.Socket;
-
-/**
- * General comments:
- *
- * 1) Transport layer can be reorganized to properly incapsulate thread-related code according to Android OS guidelines
- * 2) Currently there are different cases when transport error information sent to listener components
- *      a) when there are some errors during writing data to transport
- *      b) when there are errors during connection establishing/reading data
- *    But information about transport disconnection is sent only if disconnection was successful. So we have following
- *    sequences:
- *    a) handleTransportConnected -> read without errors -> handleTransportDisconnected
- *    b) handleTransportConnected -> handleTransportError(write with errors) -> handleTransportDisconnected
- *    c) handleTransportConnected -> handleTransportError(read with errors) -> handleTransportError(socket closed)
- *
- *    They can be changed to be more natural and easy to use.
- *
- * 3) Public api is inconsistent. During single call of some api method (for example "openConnection") some of the
- *    following result can appears:
- *      a) SmartDeviceLinkException thrown
- *      b) onTransportError callback called on listeners
- *
- * 4) Handling of connection must be more stable
- * 5) General solution in case of reconnecting must be implemented
- * 6) It must be common and same solution for handling information about physical device adapters (BT, WiFi etc.)
- */
-
-/**
- * Class that implements TCP transport
- */
-public class TCPTransport extends SmartDeviceLinkTransport {
-
-    /**
-     * Size of the read buffer.
-     */
-    private static final int READ_BUFFER_SIZE = 4096;
-
-    /**
-     * Delay between reconnect attempts
-     */
-    private static final int RECONNECT_DELAY = 5000;
-
-    /**
-     * Count of the reconnect retries
-     */
-    private static final int RECONNECT_RETRY_COUNT = 30;
-
-    /**
-     * Instance of TCP transport configuration
-     */
-    private TCPTransportConfig mConfig = null;
-
-    /**
-     * Instance of the client socket
-     */
-    private Socket mSocket = null;
-
-    /**
-     * Instance of the input stream. Used to read data from SmartDeviceLinkCore
-     */
-    private InputStream mInputStream = null;
-
-    /**
-     * Instance of the output stream. Used to send data to SmartDeviceLinkCore
-     */
-    private OutputStream mOutputStream = null;
-
-    /**
-     * Instance of the separate thread, that does actual work, related to connecting/reading/writing data
-     */
-    private TCPTransportThread mThread = null;
-
-    /**
-     * Initial internal state of the component. Used like a simple lightweight FSM replacement while component
-     * must behave differently in response to it's public function calls depending of it's current state
-     */
-    private TCPTransportState mCurrentState = TCPTransportState.IDLE;
-
-    /**
-     * Constructs TCP transport component instance
-     *
-     * @param tcpTransportConfig Instance of the TCP transport configuration
-     * @param transportListener Listener that will be notified on different TCP transport activities
-     */
-    public TCPTransport(TCPTransportConfig tcpTransportConfig, ITransportListener transportListener) {
-        super(transportListener);
-        this.mConfig = tcpTransportConfig;
-    }
-
-    /**
-     * Performs actual work of sending array of bytes over the transport
-     * @param msgBytes Bytes to send
-     * @param offset Offset in the bytes array to send data from
-     * @param length Number of bytes to send
-     * @return True if data was sent successfully, False otherwise
-     */
-    @Override
-    protected boolean sendBytesOverTransport(byte[] msgBytes, int offset, int length) {
-        TCPTransportState currentState = getCurrentState();
-        logInfo(String.format("TCPTransport: sendBytesOverTransport requested. Size: %d, Offset: %d, Length: %d, Current state is: %s"
-                , msgBytes.length, offset, length, currentState.name()));
-
-        boolean bResult = false;
-
-        if(currentState == TCPTransportState.CONNECTED) {
-            synchronized (this) {
-                if (mOutputStream != null) {
-                    logInfo("TCPTransport: sendBytesOverTransport request accepted. Trying to send data");
-                    try {
-                        mOutputStream.write(msgBytes, offset, length);
-                        bResult = true;
-                        logInfo("TCPTransport.sendBytesOverTransport: successfully send data");
-                    } catch (IOException e) {
-                        logWarning("TCPTransport.sendBytesOverTransport: error during sending data: " + e.getMessage());
-                        bResult = false;
-                    }
-                } else {
-                    logError("TCPTransport: sendBytesOverTransport request accepted, but output stream is null");
-                }
-            }
-        } else {
-            logInfo("TCPTransport: sendBytesOverTransport request rejected. Transport is not connected");
-            bResult = false;
-        }
-
-        return bResult;
-    }
-
-    /**
-     * Tries to open connection to SmartDeviceLinkCore.
-     * Actual try will be performed only if no actual connection is available
-     * @throws SmartDeviceLinkException
-     */
-    @Override
-    public void openConnection() throws SmartDeviceLinkException {
-        TCPTransportState currentState = getCurrentState();
-        logInfo(String.format("TCPTransport: openConnection requested. Current state is: %s", currentState.name()));
-
-        if(currentState == TCPTransportState.IDLE) {
-            synchronized (this) {
-                setCurrentState(TCPTransportState.CONNECTING);
-                logInfo("TCPTransport: openConnection request accepted. Starting transport thread");
-                try {
-                    mThread = new TCPTransportThread();
-                    mThread.setDaemon(true);
-                    mThread.start();
-
-                    // Initialize the SiphonServer
-                    SiphonServer.init();
-                } catch (Exception e) {
-                    logError("TCPTransport: Exception during transport thread starting", e);
-                    throw new SmartDeviceLinkException(e);
-                }
-            }
-        } else {
-            logInfo("TCPTransport: openConnection request rejected. Another connection is not finished");
-        }
-    }
-
-
-    /**
-     * Tries to disconnect from SmartDeviceLinkCore.
-     * Actual try will be performed only if connection is available
-     */
-    @Override
-    public void disconnect() {
-        TCPTransportState currentState = getCurrentState();
-        logInfo(String.format("TCPTransport: disconnect requested from client. Current state is: %s", currentState.name()));
-
-        if(currentState == TCPTransportState.CONNECTED) {
-            logInfo("TCPTransport: disconnect request accepted.");
-            synchronized (this) {
-                disconnect(null, null, true);
-            }
-        } else {
-            logInfo("TCPTransport: disconnect request rejected. Transport is not connected");
-        }
-    }
-
-    /**
-     * Performs actual work related to disconnecting from SmartDeviceLinkCore.
-     *
-     * @param message Message that describes disconnect reason
-     * @param exception Some of the possible exceptions that was the reason of disconnecting
-     * @param stopThread True if not only disconnection must be done but also thread that handles connection must be
-     *                   also stopped so no reconnect attempts will be made
-     */
-    private synchronized void disconnect(String message, Exception exception, boolean stopThread) {
-
-        if(getCurrentState() == TCPTransportState.DISCONNECTING) {
-            logInfo("TCPTransport: disconnecting already in progress");
-            return;
-        }
-
-        setCurrentState(TCPTransportState.DISCONNECTING);
-
-        String disconnectMsg = (message == null ? "" : message);
-        if (exception != null) {
-            disconnectMsg += ", " + exception.toString();
-        }
-
-        try {
-            if(mThread != null && stopThread) {
-                mThread.halt();
-                mThread.interrupt();
-            }
-
-            if(mSocket != null){
-                mSocket.close();
-            }
-            mSocket = null;
-        } catch (IOException e) {
-            logInfo("TCPTransport.disconnect: Exception during disconnect: " + e.getMessage());
-        }
-
-        if (exception == null) {
-            // This disconnect was not caused by an error, notify the proxy that
-            // the transport has been disconnected.
-            logInfo("Disconnect is correct. Handling it");
-            handleTransportDisconnected(disconnectMsg);
-        } else {
-            // This disconnect was caused by an error, notify the proxy
-            // that there was a transport error.
-            logInfo("Disconnect is incorrect. Handling it as error");
-            handleTransportError(disconnectMsg, exception);
-        }
-    }
-
-    /**
-     * Overridden abstract method which returns specific type of this transport.
-     *
-     * @return Constant value - TransportType.TCP.
-     * @see TransportType
-     */
-    public TransportType getTransportType() {
-        return TransportType.TCP;
-    }
-
-    /**
-     * Internal method for logging information messages
-     * @param message Message to log
-     */
-    protected void logInfo(String message) {
-        Log.i(getClass().getName(), message);
-    }
-
-    /**
-     * Internal method for logging error messages
-     * @param message Message to log
-     */
-    protected void logError(String message) {
-        Log.e(getClass().getName(), message);
-    }
-
-    /**
-     * Internal method for logging warning messages
-     * @param message Message to log
-     */
-    protected void logWarning(String message) {
-        Log.w(getClass().getName(), message);
-    }
-
-    /**
-     * Internal method for logging error message together with information about exception that was the reason of it
-     * @param message Message to log
-     * @param throwable Exception, that was the main reason for logged error message
-     */
-    protected void logError(String message, Throwable throwable) {
-        Log.e(getClass().getName(), message, throwable);
-    }
-
-    /**
-     * Internal class that represents separate thread, that does actual work, related to connecting/reading/writing data
-     */
-    private class TCPTransportThread extends Thread {
-
-        /**
-         * Represents current thread state - halted or not. This flag is used to change internal behavior depending
-         * on current state.
-         */
-        private Boolean isHalted = false;
-
-        /**
-         * Method that marks thread as halted.
-         */
-        public void halt() {
-            isHalted = true;
-        }
-
-        /**
-         * Tries to connect to the SmartDeviceLink core. Behavior depends autoReconnect configuration param:
-         *      a) If autoReconnect is false, then only one connect try will be performed.
-         *      b) If autoReconnect is true, then in case of connection error continuous reconnect will be performed
-         *          after short delay until connection will be established or retry count will be reached
-         *
-         * @return true if connection established and false otherwise
-         */
-        private boolean connect() {
-            boolean bConnected;
-            int remainingRetry = RECONNECT_RETRY_COUNT;
-
-            synchronized (TCPTransport.this) {
-                do {
-                    try {
-
-                        if ((null != mSocket) && (!mSocket.isClosed())) {
-                            logInfo("TCPTransport.connect: Socket is not closed. Trying to close it");
-                            mSocket.close();
-                        }
-
-                        logInfo(String.format("TCPTransport.connect: Socket is closed. Trying to connect to %s", mConfig));
-                        mSocket = new Socket();
-                        mSocket.connect(new InetSocketAddress(mConfig.getIPAddress(), mConfig.getPort()));
-                        mOutputStream = mSocket.getOutputStream();
-                        mInputStream = mSocket.getInputStream();
-
-                    } catch (IOException e) {
-                        logInfo("TCPTransport.connect: Exception during connect stage: " + e.getMessage());
-                    }
-
-                    bConnected = (null != mSocket) && mSocket.isConnected();
-
-                    if(bConnected){
-                        logInfo("TCPTransport.connect: Socket connected");
-                    }else{
-                        if(mConfig.getAutoReconnect()){
-                            remainingRetry--;
-                            logInfo(String.format("TCPTransport.connect: Socket not connected. AutoReconnect is ON. retryCount is: %d. Waiting for reconnect delay: %d"
-                                    , remainingRetry, RECONNECT_DELAY));
-                            waitFor(RECONNECT_DELAY);
-                        } else {
-                            logInfo("TCPTransport.connect: Socket not connected. AutoReconnect is OFF");
-                        }
-                    }
-                } while ((!bConnected) && (mConfig.getAutoReconnect()) && (remainingRetry > 0) && (!isHalted));
-
-                return bConnected;
-            }
-        }
-
-        /**
-         * Performs actual thread work
-         */
-        @Override
-        public void run() {
-            logInfo("TCPTransport.run: transport thread created. Starting connect stage");
-
-            while(!isHalted) {
-                setCurrentState(TCPTransportState.CONNECTING);
-                if(!connect()){
-                    if (isHalted) {
-                        logInfo("TCPTransport.run: Connection failed, but thread already halted");
-                    } else {
-                        disconnect("Failed to connect to SmartDeviceLink", new SmartDeviceLinkException("Failed to connect to SmartDeviceLink"
-                                , SmartDeviceLinkExceptionCause.SMARTDEVICELINK_CONNECTION_FAILED), true);
-                    }
-                    break;
-                }
-
-                synchronized (TCPTransport.this) {
-                    setCurrentState(TCPTransportState.CONNECTED);
-                    handleTransportConnected();
-                }
-
-                byte[] buffer = new byte[READ_BUFFER_SIZE];
-
-                while (!isHalted) {
-                    logInfo("TCPTransport.run: Waiting for data...");
-                    int bytesRead;
-                    try {
-                        bytesRead = mInputStream.read(buffer);
-                    } catch (IOException e) {
-                        internalHandleStreamReadError();
-                        break;
-                    }
-
-                    synchronized (TCPTransport.this) {
-                        if (mThread.isInterrupted()) {
-                            logInfo("TCPTransport.run: Got new data but thread is interrupted");
-                            break;
-                        }
-                    }
-
-                    logInfo("TCPTransport.run: Got new data");
-                    if (-1 == bytesRead) {
-                        internalHandleTCPDisconnect();
-                        break;
-                    } else if (0 == bytesRead) {
-                        logInfo("TCPTransport.run: Received zero bytes");
-                    } else {
-                        logInfo(String.format("TCPTransport.run: Received %d bytes", bytesRead));
-                        synchronized (TCPTransport.this) {
-                            handleReceivedBytes(buffer, bytesRead);
-                        }
-                    }
-                }
-            }
-
-            logInfo("TCPTransport.run: Thread terminated");
-            setCurrentState(TCPTransportState.IDLE);
-        }
-
-        /**
-         * Internal handling of Tcp disconnection
-         */
-        private void internalHandleTCPDisconnect() {
-            if(isHalted){
-                logInfo("TCPTransport.run: TCP disconnect received, but thread already halted");
-            } else {
-                logInfo("TCPTransport.run: TCP disconnect received");
-                disconnect("TCPTransport.run: End of stream reached", null, false);
-            }
-        }
-
-        /**
-         * Internal handling of reading data from input stream
-         */
-        private void internalHandleStreamReadError() {
-            if(isHalted){
-                logInfo("TCPTransport.run: Exception during reading data, but thread already halted");
-            } else {
-                logInfo("TCPTransport.run: Exception during reading data");
-                disconnect("Failed to read data from SmartDeviceLink", new SmartDeviceLinkException("Failed to read data from SmartDeviceLink"
-                        , SmartDeviceLinkExceptionCause.SMARTDEVICELINK_CONNECTION_FAILED), false);
-            }
-        }
-    }
-
-    /**
-     * Returns current TCP transport state
-     *
-     * @return current state
-     */
-    private synchronized TCPTransportState getCurrentState() {
-        return mCurrentState;
-    }
-
-    /**
-     * Sets current TCP transport state
-     * @param currentState New state
-     */
-    private synchronized void setCurrentState(TCPTransportState currentState) {
-        logInfo(String.format("Current state changed to: %s", currentState));
-        this.mCurrentState = currentState;
-    }
-
-    /**
-     * Implementation of waiting required delay that cannot be interrupted
-     * @param timeMs Time in milliseconds of required delay
-     */
-    private void waitFor(long timeMs) {
-        long endTime = System.currentTimeMillis() +timeMs;
-        while (System.currentTimeMillis() < endTime) {
-            synchronized (this) {
-                try {
-                    wait(endTime - System.currentTimeMillis());
-                } catch (Exception e) {
-                    // Nothing To Do, simple wait
-                }
-            }
-        }
-    }
-
-    /**
-     * Defines available states of the TCP transport
-     */
-    private enum TCPTransportState {
-        /**
-         * TCP transport is created. No connection opened
-         */
-        IDLE,
-
-        /**
-         * TCP transport is in progress of establishing connection.
-         */
-        CONNECTING,
-
-        /**
-         * TCP transport is connected to SmartDeviceLink core
-         */
-        CONNECTED,
-
-        /**
-         * TCP transport is in progress of disconnecting
-         */
-        DISCONNECTING
-    }
-} // end-class
+package com.smartdevicelink.transport;\r
+\r
+import android.util.Log;\r
+\r
+import com.smartdevicelink.exception.SmartDeviceLinkException;\r
+import com.smartdevicelink.exception.SmartDeviceLinkExceptionCause;\r
+\r
+import java.io.IOException;\r
+import java.io.InputStream;\r
+import java.io.OutputStream;\r
+import java.net.InetSocketAddress;\r
+import java.net.Socket;\r
+\r
+/**\r
+ * General comments:\r
+ *\r
+ * 1) Transport layer can be reorganized to properly incapsulate thread-related code according to Android OS guidelines\r
+ * 2) Currently there are different cases when transport error information sent to listener components\r
+ *      a) when there are some errors during writing data to transport\r
+ *      b) when there are errors during connection establishing/reading data\r
+ *    But information about transport disconnection is sent only if disconnection was successful. So we have following\r
+ *    sequences:\r
+ *    a) handleTransportConnected -> read without errors -> handleTransportDisconnected\r
+ *    b) handleTransportConnected -> handleTransportError(write with errors) -> handleTransportDisconnected\r
+ *    c) handleTransportConnected -> handleTransportError(read with errors) -> handleTransportError(socket closed)\r
+ *\r
+ *    They can be changed to be more natural and easy to use.\r
+ *\r
+ * 3) Public api is inconsistent. During single call of some api method (for example "openConnection") some of the\r
+ *    following result can appears:\r
+ *      a) SmartDeviceLinkException thrown\r
+ *      b) onTransportError callback called on listeners\r
+ *\r
+ * 4) Handling of connection must be more stable\r
+ * 5) General solution in case of reconnecting must be implemented\r
+ * 6) It must be common and same solution for handling information about physical device adapters (BT, WiFi etc.)\r
+ */\r
+\r
+/**\r
+ * Class that implements TCP transport\r
+ */\r
+public class TCPTransport extends SmartDeviceLinkTransport {\r
+\r
+    /**\r
+     * Size of the read buffer.\r
+     */\r
+    private static final int READ_BUFFER_SIZE = 4096;\r
+\r
+    /**\r
+     * Delay between reconnect attempts\r
+     */\r
+    private static final int RECONNECT_DELAY = 5000;\r
+\r
+    /**\r
+     * Count of the reconnect retries\r
+     */\r
+    private static final int RECONNECT_RETRY_COUNT = 30;\r
+\r
+    /**\r
+     * Instance of TCP transport configuration\r
+     */\r
+    private TCPTransportConfig mConfig = null;\r
+\r
+    /**\r
+     * Instance of the client socket\r
+     */\r
+    private Socket mSocket = null;\r
+\r
+    /**\r
+     * Instance of the input stream. Used to read data from ApplinkCore\r
+     */\r
+    private InputStream mInputStream = null;\r
+\r
+    /**\r
+     * Instance of the output stream. Used to send data to ApplinkCore\r
+     */\r
+    private OutputStream mOutputStream = null;\r
+\r
+    /**\r
+     * Instance of the separate thread, that does actual work, related to connecting/reading/writing data\r
+     */\r
+    private TCPTransportThread mThread = null;\r
+\r
+    /**\r
+     * Initial internal state of the component. Used like a simple lightweight FSM replacement while component\r
+     * must behave differently in response to it's public function calls depending of it's current state\r
+     */\r
+    private TCPTransportState mCurrentState = TCPTransportState.IDLE;\r
+\r
+    /**\r
+     * Constructs TCP transport component instance\r
+     *\r
+     * @param tcpTransportConfig Instance of the TCP transport configuration\r
+     * @param transportListener Listener that will be notified on different TCP transport activities\r
+     */\r
+    public TCPTransport(TCPTransportConfig tcpTransportConfig, ITransportListener transportListener) {\r
+        super(transportListener);\r
+        this.mConfig = tcpTransportConfig;\r
+    }\r
+\r
+    /**\r
+     * Performs actual work of sending array of bytes over the transport\r
+     * @param msgBytes Bytes to send\r
+     * @param offset Offset in the bytes array to send data from\r
+     * @param length Number of bytes to send\r
+     * @return True if data was sent successfully, False otherwise\r
+     */\r
+    @Override\r
+    protected boolean sendBytesOverTransport(byte[] msgBytes, int offset, int length) {\r
+        TCPTransportState currentState = getCurrentState();\r
+        logInfo(String.format("TCPTransport: sendBytesOverTransport requested. Size: %d, Offset: %d, Length: %d, Current state is: %s"\r
+                , msgBytes.length, offset, length, currentState.name()));\r
+\r
+        boolean bResult = false;\r
+\r
+        if(currentState == TCPTransportState.CONNECTED) {\r
+            synchronized (this) {\r
+                if (mOutputStream != null) {\r
+                    logInfo("TCPTransport: sendBytesOverTransport request accepted. Trying to send data");\r
+                    try {\r
+                        mOutputStream.write(msgBytes, offset, length);\r
+                        bResult = true;\r
+                        logInfo("TCPTransport.sendBytesOverTransport: successfully send data");\r
+                    } catch (IOException e) {\r
+                        logError("TCPTransport.sendBytesOverTransport: error during sending data: " + e.getMessage());\r
+                        bResult = false;\r
+                    }\r
+                } else {\r
+                    logError("TCPTransport: sendBytesOverTransport request accepted, but output stream is null");\r
+                }\r
+            }\r
+        } else {\r
+            logInfo("TCPTransport: sendBytesOverTransport request rejected. Transport is not connected");\r
+            bResult = false;\r
+        }\r
+\r
+        return bResult;\r
+    }\r
+\r
+    /**\r
+     * Tries to open connection to ApplinkCore.\r
+     * Actual try will be performed only if no actual connection is available\r
+     * @throws SmartDeviceLinkException\r
+     */\r
+    @Override\r
+    public void openConnection() throws SmartDeviceLinkException {\r
+        TCPTransportState currentState = getCurrentState();\r
+        logInfo(String.format("TCPTransport: openConnection requested. Current state is: %s", currentState.name()));\r
+\r
+        if(currentState == TCPTransportState.IDLE) {\r
+            synchronized (this) {\r
+                setCurrentState(TCPTransportState.CONNECTING);\r
+                logInfo("TCPTransport: openConnection request accepted. Starting transport thread");\r
+                try {\r
+                    mThread = new TCPTransportThread();\r
+                    mThread.setDaemon(true);\r
+                    mThread.start();\r
+\r
+                    // Initialize the SiphonServer\r
+                    SiphonServer.init();\r
+                } catch (Exception e) {\r
+                    logError("TCPTransport: Exception during transport thread starting", e);\r
+                    throw new SmartDeviceLinkException(e);\r
+                }\r
+            }\r
+        } else {\r
+            logInfo("TCPTransport: openConnection request rejected. Another connection is not finished");\r
+        }\r
+    }\r
+\r
+\r
+    /**\r
+     * Tries to disconnect from ApplinkCore.\r
+     * Actual try will be performed only if connection is available\r
+     */\r
+    @Override\r
+    public void disconnect() {\r
+        TCPTransportState currentState = getCurrentState();\r
+        logInfo(String.format("TCPTransport: disconnect requested from client. Current state is: %s", currentState.name()));\r
+\r
+        if(currentState == TCPTransportState.CONNECTED) {\r
+            logInfo("TCPTransport: disconnect request accepted.");\r
+            synchronized (this) {\r
+                disconnect(null, null, true);\r
+            }\r
+        } else {\r
+            logInfo("TCPTransport: disconnect request rejected. Transport is not connected");\r
+        }\r
+    }\r
+\r
+    /**\r
+     * Performs actual work related to disconnecting from ApplinkCore.\r
+     *\r
+     * @param message Message that describes disconnect reason\r
+     * @param exception Some of the possible exceptions that was the reason of disconnecting\r
+     * @param stopThread True if not only disconnection must be done but also thread that handles connection must be\r
+     *                   also stopped so no reconnect attempts will be made\r
+     */\r
+    private synchronized void disconnect(String message, Exception exception, boolean stopThread) {\r
+\r
+        if(getCurrentState() == TCPTransportState.DISCONNECTING) {\r
+            logInfo("TCPTransport: disconnecting already in progress");\r
+            return;\r
+        }\r
+\r
+        setCurrentState(TCPTransportState.DISCONNECTING);\r
+\r
+        String disconnectMsg = (message == null ? "" : message);\r
+        if (exception != null) {\r
+            disconnectMsg += ", " + exception.toString();\r
+        }\r
+\r
+        try {\r
+            if(mThread != null && stopThread) {\r
+                mThread.halt();\r
+                mThread.interrupt();\r
+            }\r
+\r
+            if(mSocket != null){\r
+                mSocket.close();\r
+            }\r
+            mSocket = null;\r
+        } catch (IOException e) {\r
+            logError("TCPTransport.disconnect: Exception during disconnect: " + e.getMessage());\r
+        }\r
+\r
+        if (exception == null) {\r
+            // This disconnect was not caused by an error, notify the proxy that\r
+            // the transport has been disconnected.\r
+            logInfo("Disconnect is correct. Handling it");\r
+            handleTransportDisconnected(disconnectMsg);\r
+        } else {\r
+            // This disconnect was caused by an error, notify the proxy\r
+            // that there was a transport error.\r
+            logError("Disconnect is incorrect. Handling it as error");\r
+            handleTransportError(disconnectMsg, exception);\r
+        }\r
+    }\r
+\r
+    /**\r
+     * Overridden abstract method which returns specific type of this transport.\r
+     *\r
+     * @return Constant value - TransportType.TCP.\r
+     *\r
+     * @see TransportType\r
+     */\r
+    public TransportType getTransportType() {\r
+        return TransportType.TCP;\r
+    }\r
+\r
+    /**\r
+     * Internal method for logging information messages\r
+     * @param message Message to log\r
+     */\r
+    protected void logInfo(String message) {\r
+        Log.i(getClass().getName(), message);\r
+    }\r
+\r
+    /**\r
+     * Internal method for logging error messages\r
+     * @param message Message to log\r
+     */\r
+    protected void logError(String message) {\r
+        Log.e(getClass().getName(), message);\r
+    }\r
+\r
+    /**\r
+     * Internal method for logging warning messages\r
+     * @param message Message to log\r
+     */\r
+    protected void logWarning(String message) {\r
+        Log.w(getClass().getName(), message);\r
+    }\r
+\r
+    /**\r
+     * Internal method for logging error message together with information about exception that was the reason of it\r
+     * @param message Message to log\r
+     * @param throwable Exception, that was the main reason for logged error message\r
+     */\r
+    protected void logError(String message, Throwable throwable) {\r
+        Log.e(getClass().getName(), message, throwable);\r
+    }\r
+\r
+    /**\r
+     * Internal class that represents separate thread, that does actual work, related to connecting/reading/writing data\r
+     */\r
+    private class TCPTransportThread extends Thread {\r
+\r
+        /**\r
+         * Represents current thread state - halted or not. This flag is used to change internal behavior depending\r
+         * on current state.\r
+         */\r
+        private Boolean isHalted = false;\r
+\r
+        /**\r
+         * Method that marks thread as halted.\r
+         */\r
+        public void halt() {\r
+            isHalted = true;\r
+        }\r
+\r
+        /**\r
+         * Tries to connect to the applink core. Behavior depends autoReconnect configuration param:\r
+         *      a) If autoReconnect is false, then only one connect try will be performed.\r
+         *      b) If autoReconnect is true, then in case of connection error continuous reconnect will be performed\r
+         *          after short delay until connection will be established or retry count will be reached\r
+         *\r
+         * @return true if connection established and false otherwise\r
+         */\r
+        private boolean connect() {\r
+            boolean bConnected;\r
+            int remainingRetry = RECONNECT_RETRY_COUNT;\r
+\r
+            synchronized (TCPTransport.this) {\r
+                do {\r
+                    try {\r
+\r
+                        if ((null != mSocket) && (!mSocket.isClosed())) {\r
+                            logInfo("TCPTransport.connect: Socket is not closed. Trying to close it");\r
+                            mSocket.close();\r
+                        }\r
+\r
+                        logInfo(String.format("TCPTransport.connect: Socket is closed. Trying to connect to %s", mConfig));\r
+                        mSocket = new Socket();\r
+                        mSocket.connect(new InetSocketAddress(mConfig.getIPAddress(), mConfig.getPort()));\r
+                        mOutputStream = mSocket.getOutputStream();\r
+                        mInputStream = mSocket.getInputStream();\r
+\r
+                    } catch (IOException e) {\r
+                        logError("TCPTransport.connect: Exception during connect stage: " + e.getMessage());\r
+                    }\r
+\r
+                    bConnected = (null != mSocket) && mSocket.isConnected();\r
+\r
+                    if(bConnected){\r
+                        logInfo("TCPTransport.connect: Socket connected");\r
+                    }else{\r
+                        if(mConfig.getAutoReconnect()){\r
+                            remainingRetry--;\r
+                            logInfo(String.format("TCPTransport.connect: Socket not connected. AutoReconnect is ON. retryCount is: %d. Waiting for reconnect delay: %d"\r
+                                    , remainingRetry, RECONNECT_DELAY));\r
+                            waitFor(RECONNECT_DELAY);\r
+                        } else {\r
+                            logInfo("TCPTransport.connect: Socket not connected. AutoReconnect is OFF");\r
+                        }\r
+                    }\r
+                } while ((!bConnected) && (mConfig.getAutoReconnect()) && (remainingRetry > 0) && (!isHalted));\r
+\r
+                return bConnected;\r
+            }\r
+        }\r
+\r
+        /**\r
+         * Performs actual thread work\r
+         */\r
+        @Override\r
+        public void run() {\r
+            logInfo("TCPTransport.run: transport thread created. Starting connect stage");\r
+\r
+            while(!isHalted) {\r
+                setCurrentState(TCPTransportState.CONNECTING);\r
+                if(!connect()){\r
+                    if (isHalted) {\r
+                        logInfo("TCPTransport.run: Connection failed, but thread already halted");\r
+                    } else {\r
+                        disconnect("Failed to connect to SMARTDEVICELINK", new SmartDeviceLinkException("Failed to connect to SMARTDEVICELINK"\r
+                                , SmartDeviceLinkExceptionCause.SMARTDEVICELINK_CONNECTION_FAILED), true);\r
+                    }\r
+                    break;\r
+                }\r
+\r
+                synchronized (TCPTransport.this) {\r
+                    setCurrentState(TCPTransportState.CONNECTED);\r
+                    handleTransportConnected();\r
+                }\r
+\r
+                byte[] buffer = new byte[READ_BUFFER_SIZE];\r
+\r
+                while (!isHalted) {\r
+                    logInfo("TCPTransport.run: Waiting for data...");\r
+                    int bytesRead;\r
+                    try {\r
+                        bytesRead = mInputStream.read(buffer);\r
+                    } catch (IOException e) {\r
+                        internalHandleStreamReadError();\r
+                        break;\r
+                    }\r
+\r
+                    synchronized (TCPTransport.this) {\r
+                        if (mThread.isInterrupted()) {\r
+                            logInfo("TCPTransport.run: Got new data but thread is interrupted");\r
+                            break;\r
+                        }\r
+                    }\r
+\r
+                    logInfo("TCPTransport.run: Got new data");\r
+                    if (-1 == bytesRead) {\r
+                        internalHandleTCPDisconnect();\r
+                        break;\r
+                    } else if (0 == bytesRead) {\r
+                        logInfo("TCPTransport.run: Received zero bytes");\r
+                    } else {\r
+                        logInfo(String.format("TCPTransport.run: Received %d bytes", bytesRead));\r
+                        synchronized (TCPTransport.this) {\r
+                            handleReceivedBytes(buffer, bytesRead);\r
+                        }\r
+                    }\r
+                }\r
+            }\r
+\r
+            logInfo("TCPTransport.run: Thread terminated");\r
+            setCurrentState(TCPTransportState.IDLE);\r
+        }\r
+\r
+        /**\r
+         * Internal handling of Tcp disconnection\r
+         */\r
+        private void internalHandleTCPDisconnect() {\r
+            if(isHalted){\r
+                logInfo("TCPTransport.run: TCP disconnect received, but thread already halted");\r
+            } else {\r
+                logInfo("TCPTransport.run: TCP disconnect received");\r
+                disconnect("TCPTransport.run: End of stream reached", null, false);\r
+            }\r
+        }\r
+\r
+        /**\r
+         * Internal handling of reading data from input stream\r
+         */\r
+        private void internalHandleStreamReadError() {\r
+            if(isHalted){\r
+                logError("TCPTransport.run: Exception during reading data, but thread already halted");\r
+            } else {\r
+                logError("TCPTransport.run: Exception during reading data");\r
+                disconnect("Failed to read data from SMARTDEVICELINK", new SmartDeviceLinkException("Failed to read data from SMARTDEVICELINK"\r
+                        , SmartDeviceLinkExceptionCause.SMARTDEVICELINK_CONNECTION_FAILED), false);\r
+            }\r
+        }\r
+    }\r
+\r
+    /**\r
+     * Returns current TCP transport state\r
+     *\r
+     * @return current state\r
+     */\r
+    private synchronized TCPTransportState getCurrentState() {\r
+        return mCurrentState;\r
+    }\r
+\r
+    /**\r
+     * Sets current TCP transport state\r
+     * @param currentState New state\r
+     */\r
+    private synchronized void setCurrentState(TCPTransportState currentState) {\r
+        logInfo(String.format("Current state changed to: %s", currentState));\r
+        this.mCurrentState = currentState;\r
+    }\r
+\r
+    /**\r
+     * Implementation of waiting required delay that cannot be interrupted\r
+     * @param timeMs Time in milliseconds of required delay\r
+     */\r
+    private void waitFor(long timeMs) {\r
+        long endTime = System.currentTimeMillis() +timeMs;\r
+        while (System.currentTimeMillis() < endTime) {\r
+            synchronized (this) {\r
+                try {\r
+                    wait(endTime - System.currentTimeMillis());\r
+                } catch (Exception e) {\r
+                    // Nothing To Do, simple wait\r
+                }\r
+            }\r
+        }\r
+    }\r
+\r
+    /**\r
+     * Defines available states of the TCP transport\r
+     */\r
+    private enum TCPTransportState {\r
+        /**\r
+         * TCP transport is created. No connection opened\r
+         */\r
+        IDLE,\r
+\r
+        /**\r
+         * TCP transport is in progress of establishing connection.\r
+         */\r
+        CONNECTING,\r
+\r
+        /**\r
+         * TCP transport is connected to applink core\r
+         */\r
+        CONNECTED,\r
+\r
+        /**\r
+         * TCP transport is in progress of disconnecting\r
+         */\r
+        DISCONNECTING\r
+    }\r
+} // end-class\r
old mode 100644 (file)
new mode 100755 (executable)
index 78358f9..a8ab3f1
@@ -1,85 +1,82 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.transport;
-
-/**
- * Container of TCP transport specific configuration. 
- */
-public final class TCPTransportConfig extends BaseTransportConfig {
-       
-       /**
-        * Value of port to use in TCP connection.
-        */
-       private final int mPort;
-       
-       /**
-        * Value of IP address to use in TCP connection.
-        */
-       private final String mIpAddress;
-
-    /**
-     * Value of flag which is set to true if tcp connection must be automatically reestablished in case of disconnection
-     */
-    private final boolean mAutoReconnect;
-
-    /**
-        * Constructor. Objects of this class must be created for known port and IP address value.
-        * 
-        * @param port Port for TCP connection.
-        * @param ipAddress IP address for TCP connection.
-     * @param autoReconnect Flag which must be set to true if tcp connection must be automatically reestablished in
-     *                      case of disconnection
-        */
-    public TCPTransportConfig(int port, String ipAddress, boolean autoReconnect) {
-               mPort = port;
-               mIpAddress = ipAddress;
-        mAutoReconnect = autoReconnect;
-    }
-       
-       /**
-        * Gets value of Port.
-        * 
-        * @return Port for TCP connection.
-        */
-       public int getPort() {
-               return mPort;
-       }
-               
-       /**
-        * Gets value of IP address.
-        * 
-        * @return IP address for TCP connection.
-        */
-       public String getIPAddress() {
-               return mIpAddress;
-       }
-
-    /**
-     * Gets value of AutoReconnect
-     * @return Flag that determines automatic reconnection
-     */
-    public boolean getAutoReconnect() {
-        return mAutoReconnect;
-    }
-
-    /**
-        * Overridden abstract method which returns specific type of this transport configuration.
-        * 
-        * @return Constant value TransportType.TCP. 
-        * 
-        * @see TransportType
-        */
-       public TransportType getTransportType() {
-               return TransportType.TCP;
-       }
-
-    @Override
-    public String toString() {
-        return "TCPTransportConfig{" +
-                "Port=" + mPort +
-                ", IpAddress='" + mIpAddress + '\'' +
-                ", AutoReconnect=" + mAutoReconnect +
-                '}';
-    }
-}
+package com.smartdevicelink.transport;\r
+\r
+/**\r
+ * Container of TCP transport specific configuration. \r
+ */\r
+public final class TCPTransportConfig extends BaseTransportConfig {\r
+       \r
+       /**\r
+        * Value of port to use in TCP connection.\r
+        */\r
+       private final int mPort;\r
+       \r
+       /**\r
+        * Value of IP address to use in TCP connection.\r
+        */\r
+       private final String mIpAddress;\r
+\r
+    /**\r
+     * Value of flag which is set to true if tcp connection must be automatically reestablished in case of disconnection\r
+     */\r
+    private final boolean mAutoReconnect;\r
+\r
+    /**\r
+        * Constructor. Objects of this class must be created for known port and IP address value.\r
+        * \r
+        * @param port Port for TCP connection.\r
+        * @param ipAddress IP address for TCP connection.\r
+     * @param autoReconnect Flag which must be set to true if tcp connection must be automatically reestablished in\r
+     *                      case of disconnection\r
+        */\r
+    public TCPTransportConfig(int port, String ipAddress, boolean autoReconnect) {\r
+               mPort = port;\r
+               mIpAddress = ipAddress;\r
+        mAutoReconnect = autoReconnect;\r
+    }\r
+       \r
+       /**\r
+        * Gets value of Port.\r
+        * \r
+        * @return Port for TCP connection.\r
+        */\r
+       public int getPort() {\r
+               return mPort;\r
+       }\r
+               \r
+       /**\r
+        * Gets value of IP address.\r
+        * \r
+        * @return IP address for TCP connection.\r
+        */\r
+       public String getIPAddress() {\r
+               return mIpAddress;\r
+       }\r
+\r
+    /**\r
+     * Gets value of AutoReconnect\r
+     * @return Flag that determines automatic reconnection\r
+     */\r
+    public boolean getAutoReconnect() {\r
+        return mAutoReconnect;\r
+    }\r
+\r
+    /**\r
+        * Overridden abstract method which returns specific type of this transport configuration.\r
+        * \r
+        * @return Constant value TransportType.TCP. \r
+        * \r
+        * @see TransportType\r
+        */\r
+       public TransportType getTransportType() {\r
+               return TransportType.TCP;\r
+       }\r
+\r
+    @Override\r
+    public String toString() {\r
+        return "TCPTransportConfig{" +\r
+                "Port=" + mPort +\r
+                ", IpAddress='" + mIpAddress + '\'' +\r
+                ", AutoReconnect=" + mAutoReconnect +\r
+                '}';\r
+    }\r
+}\r
old mode 100644 (file)
new mode 100755 (executable)
index 62cdc34..29ea4c4
@@ -1,20 +1,17 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.transport;
-
-/**
- * Defines available types of the transports.
- */
-public enum TransportType {
-       
-       /**
-        * Transport type is Bluetooth.
-        */
-       BLUETOOTH,
-       
-       /**
-        * Transport type is TCP.
-        */
-       TCP
-}
+package com.smartdevicelink.transport;\r
+\r
+/**\r
+ * Defines available types of the transports.\r
+ */\r
+public enum TransportType {\r
+       \r
+       /**\r
+        * Transport type is Bluetooth.\r
+        */\r
+       BLUETOOTH,\r
+       \r
+       /**\r
+        * Transport type is TCP.\r
+        */\r
+       TCP\r
+}\r
index d7f6a64..50b1fd4 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.util;
-
-public class Base64 {
-
-       private static final String defaultString = "Man is distinguished, not only by his reason, but by this singular passion from other animals, which is a lust of the mind, that by a perseverance of delight in the continued and indefatigable generation of knowledge, exceeds the short vehemence of any carnal pleasure";
-
-       private static char[] map = new char[64];
-       private static byte[] unmap = new byte['z' + 1];
-       static {
-               byte i = 0;
-               for (char c = 'A'; c <= 'Z'; c++) {
-                       unmap[c] = i;
-                       map[i++] = c;
-               }
-               for (char c = 'a'; c <= 'z'; c++) {
-                       unmap[c] = i;
-                       map[i++] = c;
-               }
-               for (char c = '0'; c <= '9'; c++) {
-                       unmap[c] = i;
-                       map[i++] = c;
-               }
-               unmap['+'] = i;
-               map[i++] = '+';
-               unmap['/'] = i;
-               map[i++] = '/';
-
-               unmap['='] = 0;
-       }
-
-       /**
-        * @param args
-        */
-       public static void main(String[] args) {
-
-               String toEncode = defaultString;
-               if (args.length > 0) {
-                       toEncode = args[0];
-               }
-               System.out.println(toEncode);
-               String encoded = encode(toEncode.getBytes());
-               System.out.println(encoded);
-               String decoded = new String(decode(encoded));
-               System.out.println(decoded);
-       }
-
-       public static String encode(byte[] toEncode) {
-
-               int iSrc = 0;
-               int iDest = 0;
-               int srcLen = toEncode.length;
-               int destLen = (srcLen * 4 + 2) / 3;
-               int padLen = ((srcLen + 2) / 3) * 4;
-               char[] dest = new char[padLen];
-
-               while (iSrc < srcLen) {
-                       int src1 = toEncode[iSrc++];
-                       int src2 = (iSrc < srcLen) ? toEncode[iSrc++] : 0;
-                       int src3 = (iSrc < srcLen) ? toEncode[iSrc++] : 0;
-                       int dest1 = (src1 >>> 2);
-                       int dest2 = (src1 << 4) | (src2 >> 4);
-                       dest2 &= 0x3F;
-                       int dest3 = (src2 << 2) | (src3 >>> 6);
-                       dest3 &= 0x3F;
-                       int dest4 = src3 & 0x3F;
-                       dest[iDest++] = map[dest1];
-                       dest[iDest++] = map[dest2];
-                       dest[iDest] = iDest < destLen ? map[dest3] : '=';
-                       iDest++;
-                       dest[iDest] = iDest < destLen ? map[dest4] : '=';
-                       iDest++;
-               }
-
-               return new String(dest);
-       }
-
-       public static byte[] decode(String toDecode) {
-               int iSrc = 0;
-               int iDest = 0;
-               char[] src = toDecode.toCharArray();
-               int srcLen = src.length;
-               int destLen = ((srcLen / 4) * 3);
-               if (src[srcLen - 1] == '=') {
-                       destLen--;
-               }
-               if (src[srcLen - 2] == '=') {
-                       destLen--;
-               }
-               byte[] dest = new byte[destLen];
-
-               while (iSrc < srcLen) {
-                       byte src1 = unmap[src[iSrc++]];
-                       byte src2 = unmap[src[iSrc++]];
-                       byte src3 = unmap[src[iSrc++]];
-                       byte src4 = unmap[src[iSrc++]];
-                       int dest1 = (src1 << 2) | (src2 >>> 4);
-                       int dest2 = (src2 << 4) | (src3 >>> 2);
-                       int dest3 = (src3 << 6) | src4;
-                       dest[iDest++] = (byte) dest1;
-                       if (iDest < destLen) {
-                               dest[iDest++] = (byte) dest2;
-                       }
-                       if (iDest < destLen) {
-                               dest[iDest++] = (byte) dest3;
-                       }
-               }
-
-               return dest;
-       }
-
-}
+package com.smartdevicelink.util;\r
+\r
+public class Base64 {\r
+\r
+       private static final String defaultString = "Man is distinguished, not only by his reason, but by this singular passion from other animals, which is a lust of the mind, that by a perseverance of delight in the continued and indefatigable generation of knowledge, exceeds the short vehemence of any carnal pleasure";\r
+\r
+       private static char[] map = new char[64];\r
+       private static byte[] unmap = new byte['z' + 1];\r
+       static {\r
+               byte i = 0;\r
+               for (char c = 'A'; c <= 'Z'; c++) {\r
+                       unmap[c] = i;\r
+                       map[i++] = c;\r
+               }\r
+               for (char c = 'a'; c <= 'z'; c++) {\r
+                       unmap[c] = i;\r
+                       map[i++] = c;\r
+               }\r
+               for (char c = '0'; c <= '9'; c++) {\r
+                       unmap[c] = i;\r
+                       map[i++] = c;\r
+               }\r
+               unmap['+'] = i;\r
+               map[i++] = '+';\r
+               unmap['/'] = i;\r
+               map[i++] = '/';\r
+\r
+               unmap['='] = 0;\r
+       }\r
+\r
+       /**\r
+        * @param args\r
+        */\r
+       public static void main(String[] args) {\r
+\r
+               String toEncode = defaultString;\r
+               if (args.length > 0) {\r
+                       toEncode = args[0];\r
+               }\r
+               System.out.println(toEncode);\r
+               String encoded = encode(toEncode.getBytes());\r
+               System.out.println(encoded);\r
+               String decoded = new String(decode(encoded));\r
+               System.out.println(decoded);\r
+       }\r
+\r
+       public static String encode(byte[] toEncode) {\r
+\r
+               int iSrc = 0;\r
+               int iDest = 0;\r
+               int srcLen = toEncode.length;\r
+               int destLen = (srcLen * 4 + 2) / 3;\r
+               int padLen = ((srcLen + 2) / 3) * 4;\r
+               char[] dest = new char[padLen];\r
+\r
+               while (iSrc < srcLen) {\r
+                       int src1 = toEncode[iSrc++];\r
+                       int src2 = (iSrc < srcLen) ? toEncode[iSrc++] : 0;\r
+                       int src3 = (iSrc < srcLen) ? toEncode[iSrc++] : 0;\r
+                       int dest1 = (src1 >>> 2);\r
+                       int dest2 = (src1 << 4) | (src2 >> 4);\r
+                       dest2 &= 0x3F;\r
+                       int dest3 = (src2 << 2) | (src3 >>> 6);\r
+                       dest3 &= 0x3F;\r
+                       int dest4 = src3 & 0x3F;\r
+                       dest[iDest++] = map[dest1];\r
+                       dest[iDest++] = map[dest2];\r
+                       dest[iDest] = iDest < destLen ? map[dest3] : '=';\r
+                       iDest++;\r
+                       dest[iDest] = iDest < destLen ? map[dest4] : '=';\r
+                       iDest++;\r
+               }\r
+\r
+               return new String(dest);\r
+       }\r
+\r
+       public static byte[] decode(String toDecode) {\r
+               int iSrc = 0;\r
+               int iDest = 0;\r
+               char[] src = toDecode.toCharArray();\r
+               int srcLen = src.length;\r
+               int destLen = ((srcLen / 4) * 3);\r
+               if (src[srcLen - 1] == '=') {\r
+                       destLen--;\r
+               }\r
+               if (src[srcLen - 2] == '=') {\r
+                       destLen--;\r
+               }\r
+               byte[] dest = new byte[destLen];\r
+\r
+               while (iSrc < srcLen) {\r
+                       byte src1 = unmap[src[iSrc++]];\r
+                       byte src2 = unmap[src[iSrc++]];\r
+                       byte src3 = unmap[src[iSrc++]];\r
+                       byte src4 = unmap[src[iSrc++]];\r
+                       int dest1 = (src1 << 2) | (src2 >>> 4);\r
+                       int dest2 = (src2 << 4) | (src3 >>> 2);\r
+                       int dest3 = (src3 << 6) | src4;\r
+                       dest[iDest++] = (byte) dest1;\r
+                       if (iDest < destLen) {\r
+                               dest[iDest++] = (byte) dest2;\r
+                       }\r
+                       if (iDest < destLen) {\r
+                               dest[iDest++] = (byte) dest3;\r
+                       }\r
+               }\r
+\r
+               return dest;\r
+       }\r
+\r
+}\r
index f74856d..4cb1927 100755 (executable)
@@ -1,75 +1,72 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.util;
-
-public class BitConverter {
-       public static String bytesToHex(byte [] bytes) {
-               return bytesToHex(bytes, 0, bytes.length);
-       } // end-method
-
-       public static String bytesToHex(byte[] bytes, int offset, int length) {
-               if (bytes == null) { return null; }
-               final char[] HexDigits = new char[] {'0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'a', 'b', 'c', 'd', 'e', 'f'};
-               byte b;
-               char[] hexChars = new char[2 * length];
-               //StringBuffer sb = new StringBuffer();
-               int upperBound = Math.min(bytes.length, (offset + length));
-               int baidx = 0;
-               int sidx = 0;
-               for (baidx = offset; baidx < upperBound; baidx++) {
-                       // Get the byte from the array
-                       b = bytes[baidx];
-                       // Use nibbles as index into hex digit array (left nibble, then right)
-                       hexChars[sidx++] = HexDigits[(b & 0xf0) >> 4];
-                       hexChars[sidx++] = HexDigits[(b & 0x0f)];
-               } // end-for
-               return new String(hexChars);
-       } // end-method
-
-       public static byte [] hexToBytes(String hexString) {
-               if (hexString == null) { return null; }
-               if (hexString.length() % 2 != 0) {
-                       hexString = "0" + hexString;
-               }
-               byte [] theBytes = new byte[hexString.length() / 2];
-               for (int i = 0; i < hexString.length(); i += 2) {
-                       String byteString = hexString.substring(i, i + 2);
-                       byte theByte = (byte)Integer.parseInt(byteString, 16);
-                       theBytes[i/2] = theByte;
-               }
-               return theBytes;
-       } // end-method
-
-       public static final byte[] intToByteArray(int value) {
-               return new byte[] {
-                               (byte)(value >>> 24),
-                               (byte)(value >>> 16),
-                               (byte)(value >>> 8),
-                               (byte)value};
-       }
-       
-       public static int intFromByteArray(byte[] sizeBuf, int offset) {
-       int ret = 0;
-       for (int i = offset; i < offset + 4; i++) {
-               ret <<= 8;
-               ret |= 0xFF & sizeBuf[i];
-       }
-       return ret;
-    }
-
-       public static final byte[] shortToByteArray(short value) {
-               return new byte[] {
-                               (byte)(value >>> 8),
-                               (byte)value};
-       }
-       
-       public static short shortFromByteArray(byte[] sizeBuf, int offset) {
-       short ret = 0;
-       for (int i = offset; i < offset + 2; i++) {
-               ret <<= 8;
-               ret |= 0xFF & sizeBuf[i];
-       }
-       return ret;
-    }
-}
+package com.smartdevicelink.util;\r
+\r
+public class BitConverter {\r
+       public static String bytesToHex(byte [] bytes) {\r
+               return bytesToHex(bytes, 0, bytes.length);\r
+       } // end-method\r
+\r
+       public static String bytesToHex(byte[] bytes, int offset, int length) {\r
+               if (bytes == null) { return null; }\r
+               final char[] HexDigits = new char[] {'0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'a', 'b', 'c', 'd', 'e', 'f'};\r
+               byte b;\r
+               char[] hexChars = new char[2 * length];\r
+               //StringBuffer sb = new StringBuffer();\r
+               int upperBound = Math.min(bytes.length, (offset + length));\r
+               int baidx = 0;\r
+               int sidx = 0;\r
+               for (baidx = offset; baidx < upperBound; baidx++) {\r
+                       // Get the byte from the array\r
+                       b = bytes[baidx];\r
+                       // Use nibbles as index into hex digit array (left nibble, then right)\r
+                       hexChars[sidx++] = HexDigits[(b & 0xf0) >> 4];\r
+                       hexChars[sidx++] = HexDigits[(b & 0x0f)];\r
+               } // end-for\r
+               return new String(hexChars);\r
+       } // end-method\r
+\r
+       public static byte [] hexToBytes(String hexString) {\r
+               if (hexString == null) { return null; }\r
+               if (hexString.length() % 2 != 0) {\r
+                       hexString = "0" + hexString;\r
+               }\r
+               byte [] theBytes = new byte[hexString.length() / 2];\r
+               for (int i = 0; i < hexString.length(); i += 2) {\r
+                       String byteString = hexString.substring(i, i + 2);\r
+                       byte theByte = (byte)Integer.parseInt(byteString, 16);\r
+                       theBytes[i/2] = theByte;\r
+               }\r
+               return theBytes;\r
+       } // end-method\r
+\r
+       public static final byte[] intToByteArray(int value) {\r
+               return new byte[] {\r
+                               (byte)(value >>> 24),\r
+                               (byte)(value >>> 16),\r
+                               (byte)(value >>> 8),\r
+                               (byte)value};\r
+       }\r
+       \r
+       public static int intFromByteArray(byte[] sizeBuf, int offset) {\r
+       int ret = 0;\r
+       for (int i = offset; i < offset + 4; i++) {\r
+               ret <<= 8;\r
+               ret |= 0xFF & sizeBuf[i];\r
+       }\r
+       return ret;\r
+    }\r
+\r
+       public static final byte[] shortToByteArray(short value) {\r
+               return new byte[] {\r
+                               (byte)(value >>> 8),\r
+                               (byte)value};\r
+       }\r
+       \r
+       public static short shortFromByteArray(byte[] sizeBuf, int offset) {\r
+       short ret = 0;\r
+       for (int i = offset; i < offset + 2; i++) {\r
+               ret <<= 8;\r
+               ret |= 0xFF & sizeBuf[i];\r
+       }\r
+       return ret;\r
+    }\r
+}\r
index 6ccdebe..3730be6 100755 (executable)
@@ -1,55 +1,52 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.util;
-
-import java.util.Enumeration;
-import java.util.Vector;
-
-public abstract class ByteEnumer {     
-       
-       protected ByteEnumer(byte value, String name) {
-               this.value = value;
-               this.name = name;
-       }
-       
-       private byte value;
-       private String name;
-       
-       public byte getValue() { return value; }
-       public String getName() { return name; }
-       
-       public boolean equals(ByteEnumer other) {
-               return name == other.getName();
-       }
-       
-       public boolean eq(ByteEnumer other) {
-               return equals(other);
-       }
-               
-       public byte value() {
-               return value;
-       }
-       
-       public static ByteEnumer get(Vector theList, byte value) {
-               Enumeration enumer = theList.elements();
-               while (enumer.hasMoreElements()) {
-                       ByteEnumer current = (ByteEnumer)enumer.nextElement();
-                       if (current.getValue() == value) {
-                               return current;
-                       }
-               }
-               return null;
-       }
-       
-       public static ByteEnumer get(Vector theList, String name) {
-               Enumeration enumer = theList.elements();
-               while (enumer.hasMoreElements()) {
-                       ByteEnumer current = (ByteEnumer)enumer.nextElement();
-                       if (current.getName().equals(name)) {
-                               return current;
-                       }
-               }
-               return null;
-       }
-}
+package com.smartdevicelink.util;\r
+\r
+import java.util.Enumeration;\r
+import java.util.Vector;\r
+\r
+public abstract class ByteEnumer {     \r
+       \r
+       protected ByteEnumer(byte value, String name) {\r
+               this.value = value;\r
+               this.name = name;\r
+       }\r
+       \r
+       private byte value;\r
+       private String name;\r
+       \r
+       public byte getValue() { return value; }\r
+       public String getName() { return name; }\r
+       \r
+       public boolean equals(ByteEnumer other) {\r
+               return name == other.getName();\r
+       }\r
+       \r
+       public boolean eq(ByteEnumer other) {\r
+               return equals(other);\r
+       }\r
+               \r
+       public byte value() {\r
+               return value;\r
+       }\r
+       \r
+       public static ByteEnumer get(Vector theList, byte value) {\r
+               Enumeration enumer = theList.elements();\r
+               while (enumer.hasMoreElements()) {\r
+                       ByteEnumer current = (ByteEnumer)enumer.nextElement();\r
+                       if (current.getValue() == value) {\r
+                               return current;\r
+                       }\r
+               }\r
+               return null;\r
+       }\r
+       \r
+       public static ByteEnumer get(Vector theList, String name) {\r
+               Enumeration enumer = theList.elements();\r
+               while (enumer.hasMoreElements()) {\r
+                       ByteEnumer current = (ByteEnumer)enumer.nextElement();\r
+                       if (current.getName().equals(name)) {\r
+                               return current;\r
+                       }\r
+               }\r
+               return null;\r
+       }\r
+}\r
index f8e0001..9321155 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.util;
-
-import java.util.Vector;
-
-import android.util.Log;
-
-import com.smartdevicelink.exception.SmartDeviceLinkException;
-import com.smartdevicelink.proxy.Version;
-import com.smartdevicelink.transport.SiphonServer;
-
-public class DebugTool {
-       
-       public static final String TAG = "SmartDeviceLinkProxy";
-
-       private static boolean isErrorEnabled = false;
-       private static boolean isWarningEnabled = false;
-       private static boolean isInfoEnabled = false;
-       
-       public static void enableDebugTool() {
-               isErrorEnabled = true;
-               isWarningEnabled = true;
-               isInfoEnabled = true;
-       }
-
-       public static void disableDebugTool() {
-               isErrorEnabled = false;
-               isWarningEnabled = false;
-               isInfoEnabled = false;
-       }
-       
-       private static String prependProxyVersionNumberToString(String string) {
-               if (Version.VERSION != null && string != null) {
-                       string = Version.VERSION + ": " + string;
-               }
-               
-               return string;
-       }
-
-       public static void logError(String msg) {
-               
-               Boolean wasWritten = false;
-               
-               msg = prependProxyVersionNumberToString(msg);
-               
-               wasWritten = logToSiphon(msg);
-               
-               if (isErrorEnabled && !wasWritten) {
-                       NativeLogTool.logError(TAG, msg);
-               }
-       }
-
-       public static void logError(String msg, Throwable ex) {
-               Boolean wasWritten = false;
-               
-               msg = prependProxyVersionNumberToString(msg);
-               
-               if (ex != null) {
-                       wasWritten = logToSiphon(msg + " Exception String: " + ex.toString());
-               } else {
-                       wasWritten = logToSiphon(msg);
-               }
-               
-               if (isErrorEnabled && !wasWritten) {
-                       NativeLogTool.logError(TAG, msg, ex);
-               }
-       }
-       
-       public static void logWarning(String msg) {
-               Boolean wasWritten = false;
-               
-               msg = prependProxyVersionNumberToString(msg);
-               
-               wasWritten = logToSiphon(msg);
-               
-               if (isWarningEnabled && !wasWritten) {
-                       NativeLogTool.logWarning(TAG, msg);
-               }
-       }
-
-       public static void logInfo(String msg) {
-               Boolean wasWritten = false;
-               
-               msg = prependProxyVersionNumberToString(msg);
-               
-               wasWritten = logToSiphon(msg);
-               
-               if (isInfoEnabled && !wasWritten) {
-                       NativeLogTool.logInfo(TAG, msg);
-               }
-       }
-       
-       protected static Boolean logToSiphon(String msg) {
-               // Initialize the SiphonServer, will be ignored if already initialized
-               SiphonServer.init();
-               
-               // Write to the SiphonServer
-               return SiphonServer.sendSiphonLogData(msg);
-       }
-
-       protected static String getLine(Throwable ex) {
-               if (ex == null) { return null; }
-               String toPrint = ex.toString() + " :" + ex.getMessage();
-               for (int i=0; i<ex.getStackTrace().length; i++) {
-                       StackTraceElement elem = ex.getStackTrace()[i];
-                       toPrint += "\n  " + elem.toString();
-               }
-               
-               if (ex instanceof SmartDeviceLinkException) {
-                       SmartDeviceLinkException SmartDeviceLinkEx = (SmartDeviceLinkException) ex;
-                       if (SmartDeviceLinkEx.getInnerException() != null && SmartDeviceLinkEx != SmartDeviceLinkEx.getInnerException()) {
-                               toPrint += "\n  nested:\n";
-                               toPrint += getLine(SmartDeviceLinkEx.getInnerException());
-                       }
-               }
-               
-               return toPrint;
-       }
-
-
-       protected static Vector<IConsole> consoleListenerList = new Vector<IConsole>();
-
-       protected final static boolean isTransportEnabled = false;
-       protected final static boolean isRPCEnabled = false;
-
-       public static void addConsole(IConsole console) {
-               synchronized(consoleListenerList) {
-                       consoleListenerList.addElement(console);
-               }
-       }
-
-       public static void removeConsole(IConsole console) {
-               synchronized(consoleListenerList) {
-                       consoleListenerList.removeElement(console);
-               }
-       }
-
-       public static void clearConsoles() {
-               synchronized(consoleListenerList) {
-                       consoleListenerList.removeAllElements();
-               }
-       }
-       
-       public static void logTransport(String msg) {
-               if (isTransportEnabled) {
-                       Log.d(TAG, msg);
-                       logInfoToConsole(msg);
-               }
-       }
-
-       public static void logRPCSend(String rpcMsg) {
-               if (isRPCEnabled) {
-                       Log.d(TAG, "Sending RPC message: " + rpcMsg);
-                       logRPCSendToConsole(rpcMsg);
-               }
-       }
-
-       public static void logRPCReceive(String rpcMsg) {
-               if (isRPCEnabled) {
-                       Log.d(TAG, "Received RPC message: " + rpcMsg);
-                       logRPCSendToConsole(rpcMsg);
-               }
-       }
-
-       protected static void logInfoToConsole(String msg) {
-               Vector<IConsole> localList;
-               synchronized(consoleListenerList) {
-                       localList = (Vector<IConsole>) consoleListenerList.clone();
-               }
-               
-               for (int i = 0; i < localList.size(); i++) {
-                       IConsole consoleListener = (IConsole) localList.elementAt(i);
-                       try {
-                               consoleListener.logInfo(msg);
-                       } catch (Exception ex) {
-                               Log.e(TAG, "Failure propagating logInfo: " + ex.toString(), ex);
-                       } // end-catch
-               }
-       }
-       
-       protected static void logErrorToConsole(String msg) {
-               Vector<IConsole> localList;
-               synchronized(consoleListenerList) {
-                       localList = (Vector<IConsole>) consoleListenerList.clone();
-               }
-               for (int i = 0; i < localList.size(); i++) {
-                       IConsole consoleListener = (IConsole) localList.elementAt(i);
-                       try {
-                               consoleListener.logError(msg);
-                       } catch (Exception ex) {
-                               Log.e(TAG, "Failure propagating logError: " + ex.toString(), ex);
-                       } // end-catch
-               }
-       }
-       
-       protected static void logErrorToConsole(String msg, Throwable e) {
-               Vector<IConsole> localList;
-               synchronized(consoleListenerList) {
-                       localList = (Vector<IConsole>) consoleListenerList.clone();
-               }
-               
-               for (int i = 0; i < localList.size(); i++) {
-                       IConsole consoleListener = (IConsole) localList.elementAt(i);
-                       try {
-                               consoleListener.logError(msg, e);
-                       } catch (Exception ex) {
-                               Log.e(TAG, "Failure propagating logError: " + ex.toString(), ex);
-                       } // end-catch
-               }
-       }
-       
-       protected static void logRPCSendToConsole(String msg) {
-               Vector<IConsole> localList;
-               synchronized(consoleListenerList) {
-                       localList = (Vector<IConsole>) consoleListenerList.clone();
-               }
-               
-               for (int i = 0; i < localList.size(); i++) {
-                       IConsole consoleListener = (IConsole) localList.elementAt(i);
-                       try {
-                               consoleListener.logRPCSend(msg);
-                       } catch (Exception ex) {
-                               Log.e(TAG, "Failure propagating logRPCSend: " + ex.toString(), ex);
-                       } // end-catch
-               }
-       }
-       
-       protected static void logRPCReceiveToConsole(String msg) {
-               Vector<IConsole> localList;
-               synchronized(consoleListenerList) {
-                       localList = (Vector<IConsole>) consoleListenerList.clone();
-               }
-               
-               for (int i = 0; i < localList.size(); i++) {
-                       IConsole consoleListener = (IConsole) localList.elementAt(i);
-                       try {
-                               consoleListener.logRPCReceive(msg);
-                       } catch (Exception ex) {
-                               Log.e(TAG, "Failure propagating logRPCReceive: " + ex.toString(), ex);
-                       } // end-catch
-               }
-       }
-}
+package com.smartdevicelink.util;\r
+\r
+import java.util.Vector;\r
+\r
+import android.util.Log;\r
+\r
+import com.smartdevicelink.exception.SmartDeviceLinkException;\r
+import com.smartdevicelink.proxy.Version;\r
+import com.smartdevicelink.transport.SiphonServer;\r
+\r
+public class DebugTool {\r
+       \r
+\r
+       public static final String TAG = "SmartDeviceLinkProxy";\r
+\r
+       private static boolean isErrorEnabled = false;\r
+       private static boolean isWarningEnabled = false;\r
+       private static boolean isInfoEnabled = false;\r
+       \r
+       public static void enableDebugTool() {\r
+               isErrorEnabled = true;\r
+               isWarningEnabled = true;\r
+               isInfoEnabled = true;\r
+       }\r
+\r
+       public static void disableDebugTool() {\r
+               isErrorEnabled = true;\r
+               isWarningEnabled = false;\r
+               isInfoEnabled = false;\r
+       }\r
+       \r
+       public static boolean isDebugEnabled() \r
+       {\r
+               if (isWarningEnabled && isInfoEnabled) return true;\r
+               \r
+               return false;           \r
+       }\r
+       \r
+       private static String prependProxyVersionNumberToString(String string) {\r
+               if (Version.VERSION != null && string != null) {\r
+                       string = Version.VERSION + ": " + string;\r
+               }\r
+               \r
+               return string;\r
+       }\r
+\r
+       public static void logError(String msg) {\r
+               \r
+               Boolean wasWritten = false;\r
+               \r
+               msg = prependProxyVersionNumberToString(msg);\r
+               \r
+               wasWritten = logToSiphon(msg);\r
+               \r
+               if (isErrorEnabled && !wasWritten) {\r
+                       NativeLogTool.logError(TAG, msg);\r
+               }\r
+       }\r
+\r
+       public static void logError(String msg, Throwable ex) {\r
+               Boolean wasWritten = false;\r
+               \r
+               msg = prependProxyVersionNumberToString(msg);\r
+               \r
+               if (ex != null) {\r
+                       wasWritten = logToSiphon(msg + " Exception String: " + ex.toString());\r
+               } else {\r
+                       wasWritten = logToSiphon(msg);\r
+               }\r
+               \r
+               if (isErrorEnabled && !wasWritten) {\r
+                       NativeLogTool.logError(TAG, msg, ex);\r
+               }\r
+       }\r
+       \r
+       public static void logWarning(String msg) {\r
+               Boolean wasWritten = false;\r
+               \r
+               msg = prependProxyVersionNumberToString(msg);\r
+               \r
+               wasWritten = logToSiphon(msg);\r
+               \r
+               if (isWarningEnabled && !wasWritten) {\r
+                       NativeLogTool.logWarning(TAG, msg);\r
+               }\r
+       }\r
+\r
+       public static void logInfo(String msg) {\r
+               Boolean wasWritten = false;\r
+               \r
+               msg = prependProxyVersionNumberToString(msg);\r
+               \r
+               wasWritten = logToSiphon(msg);\r
+               \r
+               if (isInfoEnabled && !wasWritten) {\r
+                       NativeLogTool.logInfo(TAG, msg);\r
+               }\r
+       }\r
+\r
+       public static void logInfo(String msg, boolean bPrependVersion) {\r
+               Boolean wasWritten = false;\r
+               \r
+               if (bPrependVersion) msg = prependProxyVersionNumberToString(msg);\r
+               \r
+               wasWritten = logToSiphon(msg);\r
+               \r
+               if (isInfoEnabled && !wasWritten) {\r
+                       NativeLogTool.logInfo(TAG, msg);\r
+               }\r
+       }\r
+       \r
+       protected static Boolean logToSiphon(String msg) {\r
+               // Initialize the SiphonServer, will be ignored if already initialized\r
+               SiphonServer.init();\r
+               \r
+               // Write to the SiphonServer\r
+               return SiphonServer.sendSiphonLogData(msg);\r
+       }\r
+\r
+       protected static String getLine(Throwable ex) {\r
+               if (ex == null) { return null; }\r
+               String toPrint = ex.toString() + " :" + ex.getMessage();\r
+               for (int i=0; i<ex.getStackTrace().length; i++) {\r
+                       StackTraceElement elem = ex.getStackTrace()[i];\r
+                       toPrint += "\n  " + elem.toString();\r
+               }\r
+               \r
+               if (ex instanceof SmartDeviceLinkException) {\r
+                       SmartDeviceLinkException smartDeviceLinkEx = (SmartDeviceLinkException) ex;\r
+                       if (smartDeviceLinkEx.getInnerException() != null && smartDeviceLinkEx != smartDeviceLinkEx.getInnerException()) {\r
+                               toPrint += "\n  nested:\n";\r
+                               toPrint += getLine(smartDeviceLinkEx.getInnerException());\r
+                       }\r
+               }\r
+               \r
+               return toPrint;\r
+       }\r
+\r
+\r
+       protected static Vector<IConsole> consoleListenerList = new Vector<IConsole>();\r
+\r
+       protected final static boolean isTransportEnabled = false;\r
+       protected final static boolean isRPCEnabled = false;\r
+\r
+       public static void addConsole(IConsole console) {\r
+               synchronized(consoleListenerList) {\r
+                       consoleListenerList.addElement(console);\r
+               }\r
+       }\r
+\r
+       public static void removeConsole(IConsole console) {\r
+               synchronized(consoleListenerList) {\r
+                       consoleListenerList.removeElement(console);\r
+               }\r
+       }\r
+\r
+       public static void clearConsoles() {\r
+               synchronized(consoleListenerList) {\r
+                       consoleListenerList.removeAllElements();\r
+               }\r
+       }\r
+       \r
+       public static void logTransport(String msg) {\r
+               if (isTransportEnabled) {\r
+                       Log.d(TAG, msg);\r
+                       logInfoToConsole(msg);\r
+               }\r
+       }\r
+\r
+       public static void logRPCSend(String rpcMsg) {\r
+               if (isRPCEnabled) {\r
+                       Log.d(TAG, "Sending RPC message: " + rpcMsg);\r
+                       logRPCSendToConsole(rpcMsg);\r
+               }\r
+       }\r
+\r
+       public static void logRPCReceive(String rpcMsg) {\r
+               if (isRPCEnabled) {\r
+                       Log.d(TAG, "Received RPC message: " + rpcMsg);\r
+                       logRPCSendToConsole(rpcMsg);\r
+               }\r
+       }\r
+\r
+       protected static void logInfoToConsole(String msg) {\r
+               Vector<IConsole> localList;\r
+               synchronized(consoleListenerList) {\r
+                       localList = (Vector<IConsole>) consoleListenerList.clone();\r
+               }\r
+               \r
+               for (int i = 0; i < localList.size(); i++) {\r
+                       IConsole consoleListener = (IConsole) localList.elementAt(i);\r
+                       try {\r
+                               consoleListener.logInfo(msg);\r
+                       } catch (Exception ex) {\r
+                               Log.e(TAG, "Failure propagating logInfo: " + ex.toString(), ex);\r
+                       } // end-catch\r
+               }\r
+       }\r
+       \r
+       protected static void logErrorToConsole(String msg) {\r
+               Vector<IConsole> localList;\r
+               synchronized(consoleListenerList) {\r
+                       localList = (Vector<IConsole>) consoleListenerList.clone();\r
+               }\r
+               for (int i = 0; i < localList.size(); i++) {\r
+                       IConsole consoleListener = (IConsole) localList.elementAt(i);\r
+                       try {\r
+                               consoleListener.logError(msg);\r
+                       } catch (Exception ex) {\r
+                               Log.e(TAG, "Failure propagating logError: " + ex.toString(), ex);\r
+                       } // end-catch\r
+               }\r
+       }\r
+       \r
+       protected static void logErrorToConsole(String msg, Throwable e) {\r
+               Vector<IConsole> localList;\r
+               synchronized(consoleListenerList) {\r
+                       localList = (Vector<IConsole>) consoleListenerList.clone();\r
+               }\r
+               \r
+               for (int i = 0; i < localList.size(); i++) {\r
+                       IConsole consoleListener = (IConsole) localList.elementAt(i);\r
+                       try {\r
+                               consoleListener.logError(msg, e);\r
+                       } catch (Exception ex) {\r
+                               Log.e(TAG, "Failure propagating logError: " + ex.toString(), ex);\r
+                       } // end-catch\r
+               }\r
+       }\r
+       \r
+       protected static void logRPCSendToConsole(String msg) {\r
+               Vector<IConsole> localList;\r
+               synchronized(consoleListenerList) {\r
+                       localList = (Vector<IConsole>) consoleListenerList.clone();\r
+               }\r
+               \r
+               for (int i = 0; i < localList.size(); i++) {\r
+                       IConsole consoleListener = (IConsole) localList.elementAt(i);\r
+                       try {\r
+                               consoleListener.logRPCSend(msg);\r
+                       } catch (Exception ex) {\r
+                               Log.e(TAG, "Failure propagating logRPCSend: " + ex.toString(), ex);\r
+                       } // end-catch\r
+               }\r
+       }\r
+       \r
+       protected static void logRPCReceiveToConsole(String msg) {\r
+               Vector<IConsole> localList;\r
+               synchronized(consoleListenerList) {\r
+                       localList = (Vector<IConsole>) consoleListenerList.clone();\r
+               }\r
+               \r
+               for (int i = 0; i < localList.size(); i++) {\r
+                       IConsole consoleListener = (IConsole) localList.elementAt(i);\r
+                       try {\r
+                               consoleListener.logRPCReceive(msg);\r
+                       } catch (Exception ex) {\r
+                               Log.e(TAG, "Failure propagating logRPCReceive: " + ex.toString(), ex);\r
+                       } // end-catch\r
+               }\r
+       }\r
+}\r
index 4537f1b..8d6d4a0 100755 (executable)
@@ -1,12 +1,10 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.util;
-
-public interface IConsole {
-       void logInfo(String msg);
-       void logError(String msg);
-       void logError(String msg, Throwable ex);
-       void logRPCSend(String rpcMsg);
-       void logRPCReceive(String rpcMsg);
-}
+package com.smartdevicelink.util;\r
+\r
+\r
+public interface IConsole {\r
+       void logInfo(String msg);\r
+       void logError(String msg);\r
+       void logError(String msg, Throwable ex);\r
+       void logRPCSend(String rpcMsg);\r
+       void logRPCReceive(String rpcMsg);\r
+}\r
index d2c6241..ae124a1 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.util;
-
-public class Mime {
-       
-       private static String m_base64Chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
-       
-       public static Boolean isSafeASCII(String check) {
-               if (check.contains("&") || check.contains("<") || check.contains("]]") || check.contains("}") )
-                       return false;  // these things aren't reliably CDATA encodable
-               
-               return true;
-       }
-       
-       public static String base64Encode(String toEncode) {
-               
-               byte[] bytesToEncode = new byte[toEncode.length()];   
-               for (int i=0; i< toEncode.length(); i++) 
-                       bytesToEncode[i] = (byte)toEncode.charAt(i);      
-               
-               StringBuilder sb = new StringBuilder();
-
-               int             idxin = 0;
-               int             b64idx = 0;
-
-               for (idxin=0;idxin < bytesToEncode.length;idxin++) {
-                       switch (idxin % 3) {
-                               case 0:
-                                       b64idx = (bytesToEncode[idxin] >> 2) & 0x3f;
-                                       break;
-                               case 1:
-                                       b64idx = (bytesToEncode[idxin] >> 4) & 0x0f;
-                                       b64idx |= ((bytesToEncode[idxin-1] << 4)& 0x30);
-                                       break;
-                               case 2:
-                                       b64idx = (bytesToEncode[idxin] >> 6) & 0x03;
-                                       b64idx |= ((bytesToEncode[idxin-1] << 2)& 0x3c);
-                                       sb.append(m_base64Chars.charAt(b64idx));
-                                       b64idx = bytesToEncode[idxin] & 0x3f;
-                                       break;
-                       } // end-switch
-                       sb.append(m_base64Chars.charAt(b64idx));
-               } // end-for
-
-               switch (idxin % 3) {
-                       case 0:
-                               break;
-                       case 1:
-                               b64idx = (bytesToEncode[idxin-1] << 4) & 0x30;
-                               sb.append(m_base64Chars.charAt(b64idx));
-                               sb.append("==");
-                               break;
-                       case 2:
-                               b64idx = ((bytesToEncode[idxin-1] << 2)& 0x3c);
-                               sb.append(m_base64Chars.charAt(b64idx));
-                               sb.append('=');
-                               break;
-               } // end-switch
-               
-               return sb.toString();
-       } // end-method
-       
-       
-       private byte[] base64Decode(String base64String) {
-               byte[] outBytes = null;
-               byte[] base64ASCIIString = null;
-               final String ASCII_Encoding = "US-ASCII";
-               
-               // Convert b64 string to raw bytes
-               try {
-                       base64ASCIIString = base64String.getBytes(ASCII_Encoding);
-               } catch (Exception ex){
-                       // TODO
-                       //publishStatus("Failure converting b64string to ASCII string: " + ex.toString());
-                       return null;
-               }
-               
-               if (!m_decodeInitComplete) {
-                       m_decodeInitComplete = true;
-                       initForDecode();
-               } // end-if
-
-               int     numInChars = base64ASCIIString.length;
-
-               if ((numInChars % 4) > 0) {
-                       return null;
-               } // end-if
-
-               int numOutBytes = base64ASCIIString.length / 4;
-               numOutBytes *= 3;
-               int     eqpos = base64String.indexOf("=");
-               if (eqpos >= 0) {
-                       numOutBytes--;
-                       if (base64String.substring(eqpos).indexOf("==") >= 0) {
-                               numOutBytes--;
-                       } // end-if
-               } // end-if
-               outBytes = new byte[numOutBytes];
-
-               byte    b64idxbits = 0x00;
-               int             iidx = 0, oidx = 0;
-               byte    writeByte = 0x00;
-               byte    b64ASCIIChar = 0x00;
-               for (iidx=0, oidx=0;iidx < numInChars;iidx++) {
-                       b64ASCIIChar = base64ASCIIString[iidx];
-                       if (b64ASCIIChar == 0x3d /*'='*/) {
-                               return outBytes;
-                       } // end-if
-
-                       if (!isb64char(b64ASCIIChar)) {
-                               return null;
-                       } // end-if
-
-                       switch (iidx % 4) {
-                               case 0:
-                                       break;
-                               case 1:
-                                       b64idxbits = b64decode[base64ASCIIString[iidx-1]];
-                                       writeByte = (byte)((b64idxbits << 2) | ((b64decode[b64ASCIIChar] >> 4) & 0x03));
-                                       outBytes[oidx++] = writeByte;
-                                       break;
-                               case 2:
-                                       b64idxbits = b64decode[base64ASCIIString[iidx-1]];
-                                       writeByte = (byte)(((b64idxbits << 4) & 0xf0) | ((b64decode[b64ASCIIChar] >> 2) & 0x0f));
-                                       outBytes[oidx++] = writeByte;
-                                       break;
-                               case 3:
-                                       b64idxbits = b64decode[base64ASCIIString[iidx-1]];
-                                       writeByte = (byte)(((b64idxbits << 6) & 0xc0) | ((b64decode[b64ASCIIChar]) & 0x3f));
-                                       outBytes[oidx++] = writeByte;
-                                       break;
-                       } // end-switch
-               } // end-for
-
-               return outBytes;
-
-       } // end-method
-
-
-       private static  byte[]  b64decode = new byte[256];
-       // A-Z is 0x41-0x5a
-       // a-z is 0x61-0x7a
-       // 0-9 is 0x30-0x39
-       // + is 0x2b
-       // / is 0x2f
-
-       private static  boolean m_decodeInitComplete = false;
-
-       private void initForDecode() {
-               int aidx = 0;
-               int lidx = 0;
-               // Set A-Z
-               for (aidx=0x41, lidx=0;aidx <= 0x5a;aidx++, lidx++) {
-                       b64decode[aidx] = (byte)lidx;
-               } // end-for
-               // Set a-z
-               for (aidx=0x61;aidx <= 0x7a;aidx++, lidx++) {
-                       b64decode[aidx] = (byte)lidx;
-               } // end-for
-               // Set 0-9
-               for (aidx=0x30;aidx <= 0x39;aidx++, lidx++) {
-                       b64decode[aidx] = (byte)lidx;
-               } // end-for
-               // Set '+'
-               b64decode[0x2b] = (byte)lidx++;
-               // Set '/'
-               b64decode[0x2f] = (byte)lidx++;
-       } // end-method
-
-       private boolean isb64char(byte b) {
-               // A-Z is 0x41-0x5a
-               // a-z is 0x61-0x7a
-               // 0-9 is 0x30-0x39
-               // + is 0x2b
-               // / is 0x2f
-               return (   (b >= 0x41 && b <= 0x5a)
-                       || (b >= 0x61 && b <= 0x7a)
-                       || (b >= 0x30 && b <= 0x39)
-                       || (b == 0x2b)
-                       || (b == 0x2f)
-                       );
-       } // end-method
-}
+package com.smartdevicelink.util;\r
+\r
+public class Mime {\r
+       \r
+       private static String m_base64Chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";\r
+       \r
+       public static Boolean isSafeASCII(String check) {\r
+               if (check.contains("&") || check.contains("<") || check.contains("]]") || check.contains("}") )\r
+                       return false;  // these things aren't reliably CDATA encodable\r
+               \r
+               return true;\r
+       }\r
+       \r
+       public static String base64Encode(String toEncode) {\r
+               \r
+               byte[] bytesToEncode = new byte[toEncode.length()];   \r
+               for (int i=0; i< toEncode.length(); i++) \r
+                       bytesToEncode[i] = (byte)toEncode.charAt(i);      \r
+               \r
+               StringBuilder sb = new StringBuilder();\r
+\r
+               int             idxin = 0;\r
+               int             b64idx = 0;\r
+\r
+               for (idxin=0;idxin < bytesToEncode.length;idxin++) {\r
+                       switch (idxin % 3) {\r
+                               case 0:\r
+                                       b64idx = (bytesToEncode[idxin] >> 2) & 0x3f;\r
+                                       break;\r
+                               case 1:\r
+                                       b64idx = (bytesToEncode[idxin] >> 4) & 0x0f;\r
+                                       b64idx |= ((bytesToEncode[idxin-1] << 4)& 0x30);\r
+                                       break;\r
+                               case 2:\r
+                                       b64idx = (bytesToEncode[idxin] >> 6) & 0x03;\r
+                                       b64idx |= ((bytesToEncode[idxin-1] << 2)& 0x3c);\r
+                                       sb.append(m_base64Chars.charAt(b64idx));\r
+                                       b64idx = bytesToEncode[idxin] & 0x3f;\r
+                                       break;\r
+                       } // end-switch\r
+                       sb.append(m_base64Chars.charAt(b64idx));\r
+               } // end-for\r
+\r
+               switch (idxin % 3) {\r
+                       case 0:\r
+                               break;\r
+                       case 1:\r
+                               b64idx = (bytesToEncode[idxin-1] << 4) & 0x30;\r
+                               sb.append(m_base64Chars.charAt(b64idx));\r
+                               sb.append("==");\r
+                               break;\r
+                       case 2:\r
+                               b64idx = ((bytesToEncode[idxin-1] << 2)& 0x3c);\r
+                               sb.append(m_base64Chars.charAt(b64idx));\r
+                               sb.append('=');\r
+                               break;\r
+               } // end-switch\r
+               \r
+               return sb.toString();\r
+       } // end-method\r
+       \r
+       \r
+       private byte[] base64Decode(String base64String) {\r
+               byte[] outBytes = null;\r
+               byte[] base64ASCIIString = null;\r
+               final String ASCII_Encoding = "US-ASCII";\r
+               \r
+               // Convert b64 string to raw bytes\r
+               try {\r
+                       base64ASCIIString = base64String.getBytes(ASCII_Encoding);\r
+               } catch (Exception ex){\r
+                       // TODO\r
+                       //publishStatus("Failure converting b64string to ASCII string: " + ex.toString());\r
+                       return null;\r
+               }\r
+               \r
+               if (!m_decodeInitComplete) {\r
+                       m_decodeInitComplete = true;\r
+                       initForDecode();\r
+               } // end-if\r
+\r
+               int     numInChars = base64ASCIIString.length;\r
+\r
+               if ((numInChars % 4) > 0) {\r
+                       return null;\r
+               } // end-if\r
+\r
+               int numOutBytes = base64ASCIIString.length / 4;\r
+               numOutBytes *= 3;\r
+               int     eqpos = base64String.indexOf("=");\r
+               if (eqpos >= 0) {\r
+                       numOutBytes--;\r
+                       if (base64String.substring(eqpos).indexOf("==") >= 0) {\r
+                               numOutBytes--;\r
+                       } // end-if\r
+               } // end-if\r
+               outBytes = new byte[numOutBytes];\r
+\r
+               byte    b64idxbits = 0x00;\r
+               int             iidx = 0, oidx = 0;\r
+               byte    writeByte = 0x00;\r
+               byte    b64ASCIIChar = 0x00;\r
+               for (iidx=0, oidx=0;iidx < numInChars;iidx++) {\r
+                       b64ASCIIChar = base64ASCIIString[iidx];\r
+                       if (b64ASCIIChar == 0x3d /*'='*/) {\r
+                               return outBytes;\r
+                       } // end-if\r
+\r
+                       if (!isb64char(b64ASCIIChar)) {\r
+                               return null;\r
+                       } // end-if\r
+\r
+                       switch (iidx % 4) {\r
+                               case 0:\r
+                                       break;\r
+                               case 1:\r
+                                       b64idxbits = b64decode[base64ASCIIString[iidx-1]];\r
+                                       writeByte = (byte)((b64idxbits << 2) | ((b64decode[b64ASCIIChar] >> 4) & 0x03));\r
+                                       outBytes[oidx++] = writeByte;\r
+                                       break;\r
+                               case 2:\r
+                                       b64idxbits = b64decode[base64ASCIIString[iidx-1]];\r
+                                       writeByte = (byte)(((b64idxbits << 4) & 0xf0) | ((b64decode[b64ASCIIChar] >> 2) & 0x0f));\r
+                                       outBytes[oidx++] = writeByte;\r
+                                       break;\r
+                               case 3:\r
+                                       b64idxbits = b64decode[base64ASCIIString[iidx-1]];\r
+                                       writeByte = (byte)(((b64idxbits << 6) & 0xc0) | ((b64decode[b64ASCIIChar]) & 0x3f));\r
+                                       outBytes[oidx++] = writeByte;\r
+                                       break;\r
+                       } // end-switch\r
+               } // end-for\r
+\r
+               return outBytes;\r
+\r
+       } // end-method\r
+\r
+\r
+       private static  byte[]  b64decode = new byte[256];\r
+       // A-Z is 0x41-0x5a\r
+       // a-z is 0x61-0x7a\r
+       // 0-9 is 0x30-0x39\r
+       // + is 0x2b\r
+       // / is 0x2f\r
+\r
+       private static  boolean m_decodeInitComplete = false;\r
+\r
+       private void initForDecode() {\r
+               int aidx = 0;\r
+               int lidx = 0;\r
+               // Set A-Z\r
+               for (aidx=0x41, lidx=0;aidx <= 0x5a;aidx++, lidx++) {\r
+                       b64decode[aidx] = (byte)lidx;\r
+               } // end-for\r
+               // Set a-z\r
+               for (aidx=0x61;aidx <= 0x7a;aidx++, lidx++) {\r
+                       b64decode[aidx] = (byte)lidx;\r
+               } // end-for\r
+               // Set 0-9\r
+               for (aidx=0x30;aidx <= 0x39;aidx++, lidx++) {\r
+                       b64decode[aidx] = (byte)lidx;\r
+               } // end-for\r
+               // Set '+'\r
+               b64decode[0x2b] = (byte)lidx++;\r
+               // Set '/'\r
+               b64decode[0x2f] = (byte)lidx++;\r
+       } // end-method\r
+\r
+       private boolean isb64char(byte b) {\r
+               // A-Z is 0x41-0x5a\r
+               // a-z is 0x61-0x7a\r
+               // 0-9 is 0x30-0x39\r
+               // + is 0x2b\r
+               // / is 0x2f\r
+               return (   (b >= 0x41 && b <= 0x5a)\r
+                       || (b >= 0x61 && b <= 0x7a)\r
+                       || (b >= 0x30 && b <= 0x39)\r
+                       || (b == 0x2b)\r
+                       || (b == 0x2f)\r
+                       );\r
+       } // end-method\r
+}\r
index 6e11f88..d4cb847 100755 (executable)
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.util;
-
-import android.util.Log;
-
-import com.smartdevicelink.proxy.SmartDeviceLinkProxyBase;
-
-public class NativeLogTool {
-       
-       static private boolean logToSystemEnabled = true;
-       private static final int ChunkSize = 4000;
-       
-       private enum LogTarget {
-               Info
-               ,Warning
-               ,Error
-       }
-
-       public static void setEnableState(boolean en) {
-               logToSystemEnabled = en;
-       } // end-method
-
-       public static boolean isEnabled() {
-               return logToSystemEnabled;
-       } // end-method
-       
-       public static void logInfo(String message) {
-               logInfo(SmartDeviceLinkProxyBase.TAG, message);
-       }
-       
-       public static void logInfo(String tag, String message) {
-               if (logToSystemEnabled) {
-                       log(LogTarget.Info, tag, message);
-               }
-       }
-       
-       public static void logWarning(String message) {
-               logWarning(SmartDeviceLinkProxyBase.TAG, message);
-       }
-       
-       public static void logWarning(String tag, String message) {
-               if (logToSystemEnabled) {
-                       log(LogTarget.Warning, tag, message);
-               }
-       }
-       
-       public static void logError(String message) {
-               logError(SmartDeviceLinkProxyBase.TAG, message);
-       }
-       
-       public static void logError(String tag, String message) {
-               if (logToSystemEnabled) {
-                       log(LogTarget.Error, tag, message);
-               }
-       }
-       
-       public static void logError(String message, Throwable t) {
-               logError(SmartDeviceLinkProxyBase.TAG, message, t);
-       }
-       
-       public static void logError(String tag, String message, Throwable t) {
-               // If the call to logError is passed a throwable, write directly to the system log
-               if (logToSystemEnabled) {
-                       Log.e(tag, message, t);
-               }
-       }
-       
-       private static void log(LogTarget ltarg, String source, String logMsg) {
-               // Don't log empty messages
-               if (logMsg == null || logMsg.length() == 0) {
-                       return;
-               } // end-if
-
-               int bytesWritten = 0;
-               int substrSize = 0;
-               String tag = source;
-               String chunk = null;
-               try {
-                       for (int idx=0;idx < logMsg.length();idx += substrSize) {
-                               substrSize = Math.min(ChunkSize, logMsg.length() - idx);
-                               chunk = logMsg.substring(idx, idx + substrSize);
-                               switch (ltarg) {
-                                       case Info:
-                                               bytesWritten = Log.i(tag, chunk);
-                                               break;
-                                       case Warning:
-                                               bytesWritten = Log.w(tag, chunk);
-                                               break;
-                                       case Error:
-                                               bytesWritten = Log.e(tag, chunk);
-                                               break;
-                               } // end-switch
-                               if (bytesWritten < chunk.length()) {
-                                       Log.e(SmartDeviceLinkProxyBase.TAG, "Calling Log.e: msg length=" + chunk.length() + ", bytesWritten=" + bytesWritten);
-                               } // end-if
-                       } // end-while
-               } catch (Exception ex) {
-                       Log.e(SmartDeviceLinkProxyBase.TAG, "Failure writing " + ltarg.name() + " fragments to android log:" + ex.toString());
-               } // end-catch
-       } // end-method
-}
+package com.smartdevicelink.util;\r
+\r
+import android.util.Log;\r
+\r
+import com.smartdevicelink.proxy.SmartDeviceLinkProxyBase;\r
+\r
+public class NativeLogTool {\r
+       \r
+       static private boolean logToSystemEnabled = true;\r
+       private static final int ChunkSize = 4000;\r
+       \r
+       private enum LogTarget {\r
+               Info\r
+               ,Warning\r
+               ,Error\r
+       }\r
+\r
+       public static void setEnableState(boolean en) {\r
+               logToSystemEnabled = en;\r
+       } // end-method\r
+\r
+       public static boolean isEnabled() {\r
+               return logToSystemEnabled;\r
+       } // end-method\r
+       \r
+       public static void logInfo(String message) {\r
+               logInfo(SmartDeviceLinkProxyBase.TAG, message);\r
+       }\r
+       \r
+       public static void logInfo(String tag, String message) {\r
+               if (logToSystemEnabled) {\r
+                       log(LogTarget.Info, tag, message);\r
+               }\r
+       }\r
+       \r
+       public static void logWarning(String message) {\r
+               logWarning(SmartDeviceLinkProxyBase.TAG, message);\r
+       }\r
+       \r
+       public static void logWarning(String tag, String message) {\r
+               if (logToSystemEnabled) {\r
+                       log(LogTarget.Warning, tag, message);\r
+               }\r
+       }\r
+       \r
+       public static void logError(String message) {\r
+               logError(SmartDeviceLinkProxyBase.TAG, message);\r
+       }\r
+       \r
+       public static void logError(String tag, String message) {\r
+               if (logToSystemEnabled) {\r
+                       log(LogTarget.Error, tag, message);\r
+               }\r
+       }\r
+       \r
+       public static void logError(String message, Throwable t) {\r
+               logError(SmartDeviceLinkProxyBase.TAG, message, t);\r
+       }\r
+       \r
+       public static void logError(String tag, String message, Throwable t) {\r
+               // If the call to logError is passed a throwable, write directly to the system log\r
+               if (logToSystemEnabled) {\r
+                       Log.e(tag, message, t);\r
+               }\r
+       }\r
+       \r
+       private static void log(LogTarget ltarg, String source, String logMsg) {\r
+               // Don't log empty messages\r
+               if (logMsg == null || logMsg.length() == 0) {\r
+                       return;\r
+               } // end-if\r
+\r
+               int bytesWritten = 0;\r
+               int substrSize = 0;\r
+               String tag = source;\r
+               String chunk = null;\r
+               try {\r
+                       for (int idx=0;idx < logMsg.length();idx += substrSize) {\r
+                               substrSize = Math.min(ChunkSize, logMsg.length() - idx);\r
+                               chunk = logMsg.substring(idx, idx + substrSize);\r
+                               switch (ltarg) {\r
+                                       case Info:\r
+                                               bytesWritten = Log.i(tag, chunk);\r
+                                               break;\r
+                                       case Warning:\r
+                                               bytesWritten = Log.w(tag, chunk);\r
+                                               break;\r
+                                       case Error:\r
+                                               bytesWritten = Log.e(tag, chunk);\r
+                                               break;\r
+                               } // end-switch\r
+                               if (bytesWritten < chunk.length()) {\r
+                                       Log.e(SmartDeviceLinkProxyBase.TAG, "Calling Log.e: msg length=" + chunk.length() + ", bytesWritten=" + bytesWritten);\r
+                               } // end-if\r
+                       } // end-while\r
+               } catch (Exception ex) {\r
+                       Log.e(SmartDeviceLinkProxyBase.TAG, "Failure writing " + ltarg.name() + " fragments to android log:" + ex.toString());\r
+               } // end-catch\r
+       } // end-method\r
+}\r
index e8c1814..34ab1a3 100755 (executable)
@@ -1,50 +1,47 @@
-//
-// Copyright (c) 2013 Ford Motor Company
-//
-package com.smartdevicelink.util;
-
-import java.util.Vector;
-
-public abstract class StringEnumer {    
-       
-       protected StringEnumer(int value, String name) {
-               this.value = value;
-               this.name = name;
-       }
-       
-       private int value;
-       private String name;
-       
-       public int getValue() { return value; }
-       public String getName() { return name; }
-       
-       public boolean equals(StringEnumer other) {
-               return name == other.getName();
-       }
-       
-       public boolean eq(StringEnumer other) {
-               return equals(other);
-       }
-       
-       public String toString() {
-               return name;
-       }
-       
-       public static StringEnumer get(Vector<? extends StringEnumer> theList, int value) {
-               for (StringEnumer current : theList) {
-                       if (current.getValue() == value) {
-                               return current;
-                       }
-               }
-               return null;
-       }
-       
-       public static StringEnumer get(Vector<? extends StringEnumer> theList, String name) {
-               for (StringEnumer current : theList) {
-                       if (current.getName().equalsIgnoreCase(name)) {
-                               return current;
-                       }
-               }
-               return null;
-       }
-}
+package com.smartdevicelink.util;\r
+\r
+import java.util.Vector;\r
+\r
+public abstract class StringEnumer {    \r
+       \r
+       protected StringEnumer(int value, String name) {\r
+               this.value = value;\r
+               this.name = name;\r
+       }\r
+       \r
+       private int value;\r
+       private String name;\r
+       \r
+       public int getValue() { return value; }\r
+       public String getName() { return name; }\r
+       \r
+       public boolean equals(StringEnumer other) {\r
+               return name == other.getName();\r
+       }\r
+       \r
+       public boolean eq(StringEnumer other) {\r
+               return equals(other);\r
+       }\r
+       \r
+       public String toString() {\r
+               return name;\r
+       }\r
+       \r
+       public static StringEnumer get(Vector<? extends StringEnumer> theList, int value) {\r
+               for (StringEnumer current : theList) {\r
+                       if (current.getValue() == value) {\r
+                               return current;\r
+                       }\r
+               }\r
+               return null;\r
+       }\r
+       \r
+       public static StringEnumer get(Vector<? extends StringEnumer> theList, String name) {\r
+               for (StringEnumer current : theList) {\r
+                       if (current.getName().equalsIgnoreCase(name)) {\r
+                               return current;\r
+                       }\r
+               }\r
+               return null;\r
+       }\r
+}\r