summaryrefslogtreecommitdiff
path: root/android/sdl_android/src/main/java/com/smartdevicelink/proxy/rpc/SetAppIcon.java
diff options
context:
space:
mode:
Diffstat (limited to 'android/sdl_android/src/main/java/com/smartdevicelink/proxy/rpc/SetAppIcon.java')
-rw-r--r--android/sdl_android/src/main/java/com/smartdevicelink/proxy/rpc/SetAppIcon.java98
1 files changed, 98 insertions, 0 deletions
diff --git a/android/sdl_android/src/main/java/com/smartdevicelink/proxy/rpc/SetAppIcon.java b/android/sdl_android/src/main/java/com/smartdevicelink/proxy/rpc/SetAppIcon.java
new file mode 100644
index 000000000..02ee081c2
--- /dev/null
+++ b/android/sdl_android/src/main/java/com/smartdevicelink/proxy/rpc/SetAppIcon.java
@@ -0,0 +1,98 @@
+package com.smartdevicelink.proxy.rpc;
+
+import android.support.annotation.NonNull;
+
+import com.smartdevicelink.protocol.enums.FunctionID;
+import com.smartdevicelink.proxy.RPCRequest;
+
+import java.util.Hashtable;
+
+/**
+ * Used to set existing local file on SDL as the app's icon. Not supported on
+ * first generation SDL vehicles
+ *
+ * <p><b>Parameter List</b></p>
+ *
+ * <table border="1" rules="all">
+ * <tr>
+ * <th>Param Name</th>
+ * <th>Type</th>
+ * <th>Description</th>
+ * <th> Req.</th>
+ * <th>Notes</th>
+ * <th>Version Available</th>
+ * </tr>
+ * <tr>
+ * <td>SDLFileName</td>
+ * <td>String</td>
+ * <td>File reference name.</td>
+ * <td>Y</td>
+ * <td>Maxlength=500</td>
+ * <td>SmartDeviceLink 2.0</td>
+ * </tr>
+ *
+ * </table>
+ *
+ *<p><b>Response </b></p>
+ *<p><b> Non-default Result Codes: </b></p>
+ *<p>SUCCESS</p>
+ * <p> INVALID_DATA</p>
+ * <p> OUT_OF_MEMORY</p>
+ * <p> TOO_MANY_PENDING_REQUESTS</p>
+ * <p> APPLICATION_NOT_REGISTERED</p>
+ * <p> GENERIC_ERROR</p>
+ * <p> REJECTED</p>
+ *
+ * @since SmartDeviceLink 2.0
+ * @see Image
+ */
+public class SetAppIcon extends RPCRequest {
+ public static final String KEY_SDL_FILE_NAME = "syncFileName";
+
+ /**
+ * Constructs a new SetAppIcon object
+ */
+ public SetAppIcon() {
+ super(FunctionID.SET_APP_ICON.toString());
+ }
+
+ /**
+ * Constructs a new SetAppIcon object indicated by the Hashtable parameter
+ * <p></p>
+ *
+ * @param hash The Hashtable to use
+ */
+ public SetAppIcon(Hashtable<String, Object> hash) {
+ super(hash);
+ }
+
+ /**
+ * Constructs a new SetAppIcon object
+ * @param sdlFileName a String value representing a file reference name <br>
+ * <b>Notes: </b>Maxlength=500, however the max file name length may vary based on remote filesystem limitations
+ */
+ public SetAppIcon(@NonNull String sdlFileName) {
+ this();
+ setSdlFileName(sdlFileName);
+ }
+
+ /**
+ * Sets a file reference name
+ *
+ * @param sdlFileName
+ * a String value representing a file reference name
+ * <p></p>
+ * <b>Notes: </b>Maxlength=500, however the max file name length may vary based on remote filesystem limitations
+ */
+ public void setSdlFileName(@NonNull String sdlFileName) {
+ setParameters(KEY_SDL_FILE_NAME, sdlFileName);
+ }
+
+ /**
+ * Gets a file reference name
+ * @return String -a String value
+ */
+ public String getSdlFileName() {
+ return getString(KEY_SDL_FILE_NAME);
+ }
+}