summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrett <geekman3454@protonmail.com>2018-08-23 10:52:23 -0400
committerBrett <geekman3454@protonmail.com>2018-08-23 10:52:23 -0400
commitf9899542658d19e889873781a28b240cc4b52070 (patch)
tree6bb17c7e4708c75b60357b3dc67e01a8ec0ddbb8
parent59eb7c3c4844a544f618c997643680739a276c1c (diff)
downloadsdl_android-f9899542658d19e889873781a28b240cc4b52070.tar.gz
refactored constructors to be next to each otherfeature/issue_739
-rw-r--r--sdl_android/src/main/java/com/smartdevicelink/proxy/rpc/Choice.java35
1 files changed, 19 insertions, 16 deletions
diff --git a/sdl_android/src/main/java/com/smartdevicelink/proxy/rpc/Choice.java b/sdl_android/src/main/java/com/smartdevicelink/proxy/rpc/Choice.java
index 8c2dbac98..e93196bd5 100644
--- a/sdl_android/src/main/java/com/smartdevicelink/proxy/rpc/Choice.java
+++ b/sdl_android/src/main/java/com/smartdevicelink/proxy/rpc/Choice.java
@@ -66,10 +66,12 @@ public class Choice extends RPCStruct {
public static final String KEY_VR_COMMANDS = "vrCommands";
public static final String KEY_CHOICE_ID = "choiceID";
public static final String KEY_IMAGE = "image";
+
/**
* Constructs a newly allocated Choice object
*/
public Choice() { }
+
/**
* Constructs a newly allocated Choice object indicated by the Hashtable parameter
* @param hash The Hashtable to use
@@ -77,6 +79,7 @@ public class Choice extends RPCStruct {
public Choice(Hashtable<String, Object> hash) {
super(hash);
}
+
/**
* Constructs a newly allocated Choice object
* @param choiceID Min: 0 Max: 65535
@@ -87,6 +90,22 @@ public class Choice extends RPCStruct {
setChoiceID(choiceID);
setMenuName(menuName);
}
+
+ /**
+ * Constructs a newly allocated Choice object
+ * @param choiceID Min: 0 Max: 65535
+ * @param menuName the menu name
+ * @param vrCommands the List of vrCommands
+ *
+ * Deprecated - use {@link #Choice(Integer, String)}
+ */
+ @Deprecated
+ public Choice(@NonNull Integer choiceID, @NonNull String menuName, @NonNull List<String> vrCommands) {
+ this();
+ setChoiceID(choiceID);
+ setMenuName(menuName);
+ setVrCommands(vrCommands);
+ }
/**
* VrCommands became optional as of RPC Spec 5.0. On legacy systems, we must still set VrCommands, as
@@ -118,22 +137,6 @@ public class Choice extends RPCStruct {
super.format(rpcVersion, formatParams);
}
-
- /**
- * Constructs a newly allocated Choice object
- * @param choiceID Min: 0 Max: 65535
- * @param menuName the menu name
- * @param vrCommands the List of vrCommands
- *
- * Deprecated - use {@link #Choice(Integer, String)}
- */
- @Deprecated
- public Choice(@NonNull Integer choiceID, @NonNull String menuName, @NonNull List<String> vrCommands) {
- this();
- setChoiceID(choiceID);
- setMenuName(menuName);
- setVrCommands(vrCommands);
- }
/**
* Get the application-scoped identifier that uniquely identifies this choice.
* @return choiceID Min: 0; Max: 65535