SDL_Android/SmartDeviceLinkAndroidProxy - added the correct version of the proxy
[profile/ivi/smartdevicelink.git] / SDL_Android / SmartDeviceLinkProxyAndroid / src / com / smartdevicelink / proxy / rpc / UnsubscribeButton.java
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