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