diff --git a/src/android/CHIPTool/.idea/runConfigurations.xml b/src/android/CHIPTool/.idea/runConfigurations.xml
new file mode 100644
index 00000000000000..7f68460d8b38ac
--- /dev/null
+++ b/src/android/CHIPTool/.idea/runConfigurations.xml
@@ -0,0 +1,12 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/android/CHIPTool/app/src/main/java/com/google/chip/chiptool/clusterclient/clusterinteraction/ClusterDetailFragment.kt b/src/android/CHIPTool/app/src/main/java/com/google/chip/chiptool/clusterclient/clusterinteraction/ClusterDetailFragment.kt
index bb8def19a7e2c0..268841a7cf95e3 100644
--- a/src/android/CHIPTool/app/src/main/java/com/google/chip/chiptool/clusterclient/clusterinteraction/ClusterDetailFragment.kt
+++ b/src/android/CHIPTool/app/src/main/java/com/google/chip/chiptool/clusterclient/clusterinteraction/ClusterDetailFragment.kt
@@ -15,7 +15,7 @@ import androidx.core.view.forEach
import androidx.fragment.app.Fragment
import chip.clusterinfo.ClusterCommandCallback
import chip.clusterinfo.ClusterInfo
-import chip.clusterinfo.CommandInfo
+import chip.clusterinfo.InteractionInfo
import chip.clusterinfo.CommandResponseInfo
import chip.clusterinfo.DelegatedClusterCallback
import chip.devicecontroller.ChipClusters
@@ -53,7 +53,7 @@ class ClusterDetailFragment : Fragment() {
private lateinit var selectedClusterInfo: ClusterInfo
private lateinit var selectedCluster: ChipClusters.BaseChipCluster
private lateinit var selectedCommandCallback: DelegatedClusterCallback
- private lateinit var selectedCommandInfo: CommandInfo
+ private lateinit var selectedInteractionInfo: InteractionInfo
private var devicePtr = 0L
private var endpointId = 0
@@ -80,12 +80,12 @@ class ClusterDetailFragment : Fragment() {
val commandArguments = HashMap()
parameterList.forEach {
val type =
- selectedCommandInfo.commandParameters[it.clusterParameterNameTv.text.toString()]!!.type
+ selectedInteractionInfo.commandParameters[it.clusterParameterNameTv.text.toString()]!!.type
val data = castStringToType(it.clusterParameterData.text.toString(), type)!!
commandArguments[it.clusterParameterNameTv.text.toString()] = data
}
- selectedCommandInfo.getCommandFunction()
+ selectedInteractionInfo.getCommandFunction()
.invokeCommand(selectedCluster, selectedCommandCallback, commandArguments)
}
}
@@ -94,7 +94,6 @@ class ClusterDetailFragment : Fragment() {
private fun castStringToType(data: String, type: Class<*>): Any? {
return when (type) {
Int::class.java -> data.toInt()
- String::class.java -> data
Boolean::class.java -> data.toBoolean()
else -> data
}
@@ -141,8 +140,8 @@ class ClusterDetailFragment : Fragment() {
callbackList.removeAllViews()
selectedCluster = selectedClusterInfo.createClusterFunction.create(devicePtr, endpointId)
val selectedCommand: String = commandAutoComplete.adapter.getItem(position).toString()
- selectedCommandInfo = selectedClusterInfo.commands[selectedCommand]!!
- selectedCommandCallback = selectedCommandInfo.commandCallbackSupplier.get()
+ selectedInteractionInfo = selectedClusterInfo.commands[selectedCommand]!!
+ selectedCommandCallback = selectedInteractionInfo.commandCallbackSupplier.get()
populateCommandParameter(inflater, parameterList)
selectedCommandCallback.setCallbackDelegate(object : ClusterCommandCallback {
override fun onSuccess(responseValues: Map) {
@@ -167,7 +166,7 @@ class ClusterDetailFragment : Fragment() {
}
private fun populateCommandParameter(inflater: LayoutInflater, parameterList: LinearLayout) {
- selectedCommandInfo.commandParameters.forEach { (paramName, paramInfo) ->
+ selectedInteractionInfo.commandParameters.forEach { (paramName, paramInfo) ->
val param = inflater.inflate(R.layout.cluster_parameter_item, null, false) as ConstraintLayout
param.clusterParameterNameTv.text = "${paramName}"
param.clusterParameterTypeTv.text = "${paramInfo.type}"
@@ -182,37 +181,55 @@ class ClusterDetailFragment : Fragment() {
) {
responseValues.forEach { (variableNameType, response) ->
if (response is List<*>) {
- if (response.size == 0) {
- val emptyCallback =
- inflater.inflate(R.layout.cluster_callback_item, null, false) as ConstraintLayout
- emptyCallback.clusterCallbackNameTv.text = "Result is empty"
- callbackList.addView(emptyCallback)
- } else {
- response.forEachIndexed { index, it ->
- val objectCallback =
- inflater.inflate(R.layout.cluster_callback_item, null, false) as ConstraintLayout
- objectCallback.clusterCallbackNameTv.text = variableNameType.name + "[$index]"
- val objectDeserializationString = it.toString()
- val callbackClassName = it!!.javaClass.toString().split('$').last()
- objectCallback.clusterCallbackDataTv.text = callbackClassName
- objectCallback.clusterCallbackDataTv.setOnClickListener {
- AlertDialog.Builder(requireContext())
- .setTitle(callbackClassName)
- .setMessage(objectDeserializationString)
- .create()
- .show()
- }
- objectCallback.clusterCallbackTypeTv.text = "List<$callbackClassName>"
- callbackList.addView(objectCallback)
- }
- }
+ createListReadAttributeView(response, inflater, callbackList, variableNameType)
} else {
- val callback =
+ createBasicReadAttributeView(response, inflater, callbackList, variableNameType)
+ }
+ }
+ }
+
+ private fun createBasicReadAttributeView(
+ response: Any,
+ inflater: LayoutInflater,
+ callbackList: LinearLayout,
+ variableNameType: CommandResponseInfo
+ ) {
+ val callbackItem =
+ inflater.inflate(R.layout.cluster_callback_item, null, false) as ConstraintLayout
+ callbackItem.clusterCallbackNameTv.text = variableNameType.name
+ callbackItem.clusterCallbackDataTv.text = response.toString()
+ callbackItem.clusterCallbackTypeTv.text = variableNameType.type
+ callbackList.addView(callbackItem)
+ }
+
+ private fun createListReadAttributeView(
+ response: List<*>,
+ inflater: LayoutInflater,
+ callbackList: LinearLayout,
+ variableNameType: CommandResponseInfo
+ ) {
+ if (response.isEmpty()) {
+ val emptyCallback =
+ inflater.inflate(R.layout.cluster_callback_item, null, false) as ConstraintLayout
+ emptyCallback.clusterCallbackNameTv.text = "Result is empty"
+ callbackList.addView(emptyCallback)
+ } else {
+ response.forEachIndexed { index, it ->
+ val readAttributeCallbackItem =
inflater.inflate(R.layout.cluster_callback_item, null, false) as ConstraintLayout
- callback.clusterCallbackNameTv.text = variableNameType.name
- callback.clusterCallbackDataTv.text = response.toString()
- callback.clusterCallbackTypeTv.text = variableNameType.type
- callbackList.addView(callback)
+ readAttributeCallbackItem.clusterCallbackNameTv.text = variableNameType.name + "[$index]"
+ val objectString = it.toString()
+ val callbackClassName = it!!.javaClass.toString().split('$').last()
+ readAttributeCallbackItem.clusterCallbackDataTv.text = callbackClassName
+ readAttributeCallbackItem.clusterCallbackDataTv.setOnClickListener {
+ AlertDialog.Builder(requireContext())
+ .setTitle(callbackClassName)
+ .setMessage(objectString)
+ .create()
+ .show()
+ }
+ readAttributeCallbackItem.clusterCallbackTypeTv.text = "List<$callbackClassName>"
+ callbackList.addView(readAttributeCallbackItem)
}
}
}
diff --git a/src/controller/java/BUILD.gn b/src/controller/java/BUILD.gn
index 31fafee2743e64..6a1efd413ca8ea 100644
--- a/src/controller/java/BUILD.gn
+++ b/src/controller/java/BUILD.gn
@@ -69,10 +69,10 @@ android_library("java") {
sources = [
"src/chip/clusterinfo/ClusterCommandCallback.java",
"src/chip/clusterinfo/ClusterInfo.java",
- "src/chip/clusterinfo/CommandInfo.java",
"src/chip/clusterinfo/CommandParameterInfo.java",
"src/chip/clusterinfo/CommandResponseInfo.java",
"src/chip/clusterinfo/DelegatedClusterCallback.java",
+ "src/chip/clusterinfo/InteractionInfo.java",
"src/chip/devicecontroller/ChipClusterException.java",
"src/chip/devicecontroller/ChipCommandType.java",
"src/chip/devicecontroller/ChipDeviceController.java",
diff --git a/src/controller/java/src/chip/clusterinfo/ClusterInfo.java b/src/controller/java/src/chip/clusterinfo/ClusterInfo.java
index cb4dee857cceb8..efd37f150dae5f 100644
--- a/src/controller/java/src/chip/clusterinfo/ClusterInfo.java
+++ b/src/controller/java/src/chip/clusterinfo/ClusterInfo.java
@@ -6,9 +6,10 @@
/** ClusterInfo maps commands and provides a constructor function for a cluster. */
public class ClusterInfo {
private final ClusterConstructor createClusterFunction;
- private final Map commands;
+ private final Map commands;
- public ClusterInfo(ClusterConstructor createClusterFunction, Map commands) {
+ public ClusterInfo(
+ ClusterConstructor createClusterFunction, Map commands) {
this.createClusterFunction = createClusterFunction;
this.commands = commands;
}
@@ -17,11 +18,11 @@ public ClusterConstructor getCreateClusterFunction() {
return createClusterFunction;
}
- public Map getCommands() {
+ public Map getCommands() {
return commands;
}
- public void combineCommands(Map newCommands) {
+ public void combineCommands(Map newCommands) {
this.commands.putAll(newCommands);
}
diff --git a/src/controller/java/src/chip/clusterinfo/CommandInfo.java b/src/controller/java/src/chip/clusterinfo/InteractionInfo.java
similarity index 83%
rename from src/controller/java/src/chip/clusterinfo/CommandInfo.java
rename to src/controller/java/src/chip/clusterinfo/InteractionInfo.java
index 7bc59c1571ff88..c389cbb33c9812 100644
--- a/src/controller/java/src/chip/clusterinfo/CommandInfo.java
+++ b/src/controller/java/src/chip/clusterinfo/InteractionInfo.java
@@ -5,16 +5,16 @@
import java.util.function.Supplier;
/**
- * CommandInfo has a functional interface to invoke arbitrary commands based on cluster, callback
- * and a map of arguments, a Supplier that provides {@link DelegatedClusterCallback}, and maps the
- * parameter and commandParametersInfo.
+ * InteractionInfo has a functional interface to invoke arbitrary interaction based on cluster,
+ * callback and a map of arguments, a Supplier that provides {@link DelegatedClusterCallback}, and
+ * maps the parameter and commandParametersInfo.
*/
-public class CommandInfo {
+public class InteractionInfo {
public ClusterCommandFunction commandFunction;
private Supplier commandCallbackSupplier;
private Map commandParameters;
- public CommandInfo(
+ public InteractionInfo(
ClusterCommandFunction commandFunction,
Supplier commandCallbackSupplier,
Map commandParameters) {
diff --git a/src/controller/java/templates/ChipClusters-java.zapt b/src/controller/java/templates/ChipClusters-java.zapt
index a8949a104cbb91..6949da07b66c68 100644
--- a/src/controller/java/templates/ChipClusters-java.zapt
+++ b/src/controller/java/templates/ChipClusters-java.zapt
@@ -5,6 +5,7 @@ package chip.devicecontroller;
import androidx.annotation.Nullable;
import java.util.List;
+import java.util.Arrays;
import java.util.Optional;
public class ChipClusters {
@@ -179,18 +180,9 @@ public class ChipClusters {
{{else if isStruct}}
{{! TODO: Add support for structs here }}
{{else if (isOctetString type)}}
- output.append("byte[] {{asLowerCamelCase name}}: [");
- for (int i = 0; i < {{asLowerCamelCase name}}.length; i++) {
- if (i != {{asLowerCamelCase name}}.length - 1) {
- output.append({{asLowerCamelCase name}}[i]);
- output.append(", ");
- }
- else {
- output.append({{asLowerCamelCase name}}[i]);
- output.append("]");
- output.append("\n");
- }
- }
+ output.append("byte[] ");
+ output.append(Arrays.toString({{asLowerCamelCase name}}));
+ output.append("\n");
{{else if (isCharString type)}}
output.append("String {{asLowerCamelCase name}}: ");
output.append(this.{{asLowerCamelCase name}});
diff --git a/src/controller/java/templates/ClusterInfo-java.zapt b/src/controller/java/templates/ClusterInfo-java.zapt
index 0270c88a27217f..252fc7528cd765 100644
--- a/src/controller/java/templates/ClusterInfo-java.zapt
+++ b/src/controller/java/templates/ClusterInfo-java.zapt
@@ -9,7 +9,7 @@ import java.util.Map;
import java.util.List;
import java.util.HashMap;
import chip.clusterinfo.ClusterInfo;
-import chip.clusterinfo.CommandInfo;
+import chip.clusterinfo.InteractionInfo;
import chip.clusterinfo.CommandParameterInfo;
import chip.clusterinfo.DelegatedClusterCallback;
import chip.clusterinfo.ClusterCommandCallback;
@@ -248,15 +248,34 @@ public class ClusterInfoMapping {
{{/chip_client_clusters}}
public Map getClusterMap() {
+ Map clusterMap = initializeClusterMap();
+ Map> commandMap = getCommandMap();
+ combineCommand(clusterMap, commandMap);
+ Map> readAttributeMap = getReadAttributeMap();
+ combineCommand(clusterMap, readAttributeMap);
+ return clusterMap;
+ }
+
+ public Map initializeClusterMap() {
Map clusterMap = new HashMap<>();
- getCommandMap(clusterMap);
- getReadAttributeMap(clusterMap);
+ {{#chip_client_clusters}}
+ ClusterInfo {{asLowerCamelCase name}}ClusterInfo = new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.{{asUpperCamelCase name}}Cluster(ptr, endpointId), new HashMap<>());
+ clusterMap.put("{{asLowerCamelCase name}}", {{asLowerCamelCase name}}ClusterInfo);
+ {{/chip_client_clusters}}
return clusterMap;
}
- public Map getCommandMap(Map clusterMap) {
+ public void combineCommand(Map destination, Map> source) {
+ {{#chip_client_clusters}}
+ destination.get("{{asLowerCamelCase name}}").combineCommands(source.get("{{asLowerCamelCase name}}"));
+ {{/chip_client_clusters}}
+ }
+
+ public Map> getCommandMap() {
+ Map> commandMap = new HashMap<>();
{{#chip_client_clusters}}
- Map {{asLowerCamelCase name}}ClusterCommandInfoMap = new LinkedHashMap<>();
+ Map {{asLowerCamelCase name}}ClusterInteractionInfoMap = new LinkedHashMap<>();
{{#chip_cluster_commands}}
Map {{asLowerCamelCase ../name}}{{asLowerCamelCase name}}CommandParams = new LinkedHashMap();
{{! TODO: fill out parameter types }}
@@ -270,7 +289,7 @@ public class ClusterInfoMapping {
{{/if}}
// Populate commands
{{#if hasSpecificResponse}}
- CommandInfo {{asLowerCamelCase ../name}}{{asLowerCamelCase name}}CommandInfo = new CommandInfo(
+ InteractionInfo {{asLowerCamelCase ../name}}{{asLowerCamelCase name}}InteractionInfo = new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.{{asUpperCamelCase ../name}}Cluster) cluster)
.{{asLowerCamelCase name}}((ChipClusters.{{asUpperCamelCase ../name}}Cluster.{{asUpperCamelCase responseName}}Callback) callback
@@ -284,7 +303,7 @@ public class ClusterInfoMapping {
{{asLowerCamelCase ../name}}{{asLowerCamelCase name}}CommandParams
);
{{else}}
- CommandInfo {{asLowerCamelCase ../name}}{{asLowerCamelCase name}}CommandInfo = new CommandInfo(
+ InteractionInfo {{asLowerCamelCase ../name}}{{asLowerCamelCase name}}InteractionInfo = new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.{{asUpperCamelCase ../name}}Cluster) cluster)
.{{asLowerCamelCase name}}((DefaultClusterCallback) callback
@@ -298,23 +317,21 @@ public class ClusterInfoMapping {
{{asLowerCamelCase ../name}}{{asLowerCamelCase name}}CommandParams
);
{{/if}}
- {{asLowerCamelCase ../name}}ClusterCommandInfoMap.put("{{asLowerCamelCase name}}", {{asLowerCamelCase ../name}}{{asLowerCamelCase name}}CommandInfo);
+ {{asLowerCamelCase ../name}}ClusterInteractionInfoMap.put("{{asLowerCamelCase name}}", {{asLowerCamelCase ../name}}{{asLowerCamelCase name}}InteractionInfo);
{{/chip_cluster_commands}}
- // Populate cluster
- ClusterInfo {{asLowerCamelCase name}}ClusterInfo = new ClusterInfo(
- (ptr, endpointId) -> new ChipClusters.{{asUpperCamelCase name}}Cluster(ptr, endpointId), {{asLowerCamelCase name}}ClusterCommandInfoMap);
- clusterMap.put("{{asLowerCamelCase name}}", {{asLowerCamelCase name}}ClusterInfo);
+ commandMap.put("{{asLowerCamelCase name}}", {{asLowerCamelCase name}}ClusterInteractionInfoMap);
{{/chip_client_clusters}}
- return clusterMap;
+ return commandMap;
}
- public Map getReadAttributeMap(Map clusterMap) {
+ public Map> getReadAttributeMap() {
+ Map> readAttributeMap = new HashMap<>();
{{#chip_client_clusters}}
- Map read{{asUpperCamelCase name}}CommandInfo = new LinkedHashMap<>();
+ Map read{{asUpperCamelCase name}}InteractionInfo = new LinkedHashMap<>();
// read attribute
{{#chip_server_cluster_attributes}}
Map read{{asUpperCamelCase ../name}}{{asUpperCamelCase name}}CommandParams = new LinkedHashMap();
- CommandInfo read{{asUpperCamelCase ../name}}{{asUpperCamelCase name}}AttributeCommandInfo = new CommandInfo(
+ InteractionInfo read{{asUpperCamelCase ../name}}{{asUpperCamelCase name}}AttributeInteractionInfo = new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.{{asUpperCamelCase ../name}}Cluster) cluster).read{{asUpperCamelCase name}}Attribute(
{{#if isList}}
@@ -331,12 +348,11 @@ public class ClusterInfoMapping {
{{/if}}
read{{asUpperCamelCase ../name}}{{asUpperCamelCase name}}CommandParams
);
- read{{asUpperCamelCase ../name}}CommandInfo.put("read{{asUpperCamelCase name}}Attribute", read{{asUpperCamelCase ../name}}{{asUpperCamelCase name}}AttributeCommandInfo);
+ read{{asUpperCamelCase ../name}}InteractionInfo.put("read{{asUpperCamelCase name}}Attribute", read{{asUpperCamelCase ../name}}{{asUpperCamelCase name}}AttributeInteractionInfo);
{{/chip_server_cluster_attributes}}
- // combine the read Attribute into the original commands
- clusterMap.get("{{asLowerCamelCase name}}").combineCommands(read{{asUpperCamelCase name}}CommandInfo);
+ readAttributeMap.put("{{asLowerCamelCase name}}", read{{asUpperCamelCase name}}InteractionInfo);
{{/chip_client_clusters}}
- return clusterMap;
+ return readAttributeMap;
}
}
diff --git a/src/controller/java/zap-generated/chip/devicecontroller/ChipClusters.java b/src/controller/java/zap-generated/chip/devicecontroller/ChipClusters.java
index 0636e1cc60b37d..1d4f42aed4fd38 100644
--- a/src/controller/java/zap-generated/chip/devicecontroller/ChipClusters.java
+++ b/src/controller/java/zap-generated/chip/devicecontroller/ChipClusters.java
@@ -20,6 +20,7 @@
package chip.devicecontroller;
import androidx.annotation.Nullable;
+import java.util.Arrays;
import java.util.List;
import java.util.Optional;
@@ -1038,17 +1039,9 @@ public String toString() {
output.append(this.type);
output.append("\n");
- output.append("byte[] endpoints: [");
- for (int i = 0; i < endpoints.length; i++) {
- if (i != endpoints.length - 1) {
- output.append(endpoints[i]);
- output.append(", ");
- } else {
- output.append(endpoints[i]);
- output.append("]");
- output.append("\n");
- }
- }
+ output.append("byte[] ");
+ output.append(Arrays.toString(endpoints));
+ output.append("\n");
return output.toString();
}
@@ -3314,17 +3307,9 @@ public String toString() {
output.append(this.offPremiseServicesReachableIPv6);
output.append("\n");
- output.append("byte[] hardwareAddress: [");
- for (int i = 0; i < hardwareAddress.length; i++) {
- if (i != hardwareAddress.length - 1) {
- output.append(hardwareAddress[i]);
- output.append(", ");
- } else {
- output.append(hardwareAddress[i]);
- output.append("]");
- output.append("\n");
- }
- }
+ output.append("byte[] ");
+ output.append(Arrays.toString(hardwareAddress));
+ output.append("\n");
output.append("int type: ");
output.append(this.type);
@@ -3461,17 +3446,9 @@ public String toString() {
output.append(this.groupKeyIndex);
output.append("\n");
- output.append("byte[] groupKeyRoot: [");
- for (int i = 0; i < groupKeyRoot.length; i++) {
- if (i != groupKeyRoot.length - 1) {
- output.append(groupKeyRoot[i]);
- output.append(", ");
- } else {
- output.append(groupKeyRoot[i]);
- output.append("]");
- output.append("\n");
- }
- }
+ output.append("byte[] ");
+ output.append(Arrays.toString(groupKeyRoot));
+ output.append("\n");
output.append("long groupKeyEpochStartTime: ");
output.append(this.groupKeyEpochStartTime);
@@ -5261,17 +5238,9 @@ public String toString() {
output.append(this.fabricIndex);
output.append("\n");
- output.append("byte[] rootPublicKey: [");
- for (int i = 0; i < rootPublicKey.length; i++) {
- if (i != rootPublicKey.length - 1) {
- output.append(rootPublicKey[i]);
- output.append(", ");
- } else {
- output.append(rootPublicKey[i]);
- output.append("]");
- output.append("\n");
- }
- }
+ output.append("byte[] ");
+ output.append(Arrays.toString(rootPublicKey));
+ output.append("\n");
output.append("int vendorId: ");
output.append(this.vendorId);
@@ -6586,17 +6555,9 @@ public String toString() {
output.append(this.fabricIndex);
output.append("\n");
- output.append("byte[] operationalCert: [");
- for (int i = 0; i < operationalCert.length; i++) {
- if (i != operationalCert.length - 1) {
- output.append(operationalCert[i]);
- output.append(", ");
- } else {
- output.append(operationalCert[i]);
- output.append("]");
- output.append("\n");
- }
- }
+ output.append("byte[] ");
+ output.append(Arrays.toString(operationalCert));
+ output.append("\n");
return output.toString();
}
diff --git a/src/controller/java/zap-generated/chip/devicecontroller/ClusterInfoMapping.java b/src/controller/java/zap-generated/chip/devicecontroller/ClusterInfoMapping.java
index 4951539c962c4c..758a98b4219747 100644
--- a/src/controller/java/zap-generated/chip/devicecontroller/ClusterInfoMapping.java
+++ b/src/controller/java/zap-generated/chip/devicecontroller/ClusterInfoMapping.java
@@ -21,10 +21,10 @@
import chip.clusterinfo.ClusterCommandCallback;
import chip.clusterinfo.ClusterInfo;
-import chip.clusterinfo.CommandInfo;
import chip.clusterinfo.CommandParameterInfo;
import chip.clusterinfo.CommandResponseInfo;
import chip.clusterinfo.DelegatedClusterCallback;
+import chip.clusterinfo.InteractionInfo;
import chip.devicecontroller.ChipClusters.DefaultClusterCallback;
import java.util.HashMap;
import java.util.LinkedHashMap;
@@ -3117,14 +3117,387 @@ public void onError(Exception ex) {
}
public Map getClusterMap() {
+ Map clusterMap = initializeClusterMap();
+ Map> commandMap = getCommandMap();
+ combineCommand(clusterMap, commandMap);
+ Map> readAttributeMap = getReadAttributeMap();
+ combineCommand(clusterMap, readAttributeMap);
+ return clusterMap;
+ }
+
+ public Map initializeClusterMap() {
Map clusterMap = new HashMap<>();
- getCommandMap(clusterMap);
- getReadAttributeMap(clusterMap);
+ ClusterInfo accountLoginClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.AccountLoginCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("accountLogin", accountLoginClusterInfo);
+ ClusterInfo administratorCommissioningClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) ->
+ new ChipClusters.AdministratorCommissioningCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("administratorCommissioning", administratorCommissioningClusterInfo);
+ ClusterInfo applicationBasicClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.ApplicationBasicCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("applicationBasic", applicationBasicClusterInfo);
+ ClusterInfo applicationLauncherClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.ApplicationLauncherCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("applicationLauncher", applicationLauncherClusterInfo);
+ ClusterInfo audioOutputClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.AudioOutputCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("audioOutput", audioOutputClusterInfo);
+ ClusterInfo barrierControlClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.BarrierControlCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("barrierControl", barrierControlClusterInfo);
+ ClusterInfo basicClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.BasicCluster(ptr, endpointId), new HashMap<>());
+ clusterMap.put("basic", basicClusterInfo);
+ ClusterInfo binaryInputBasicClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.BinaryInputBasicCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("binaryInputBasic", binaryInputBasicClusterInfo);
+ ClusterInfo bindingClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.BindingCluster(ptr, endpointId), new HashMap<>());
+ clusterMap.put("binding", bindingClusterInfo);
+ ClusterInfo booleanStateClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.BooleanStateCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("booleanState", booleanStateClusterInfo);
+ ClusterInfo bridgedActionsClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.BridgedActionsCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("bridgedActions", bridgedActionsClusterInfo);
+ ClusterInfo bridgedDeviceBasicClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.BridgedDeviceBasicCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("bridgedDeviceBasic", bridgedDeviceBasicClusterInfo);
+ ClusterInfo colorControlClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.ColorControlCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("colorControl", colorControlClusterInfo);
+ ClusterInfo contentLauncherClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.ContentLauncherCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("contentLauncher", contentLauncherClusterInfo);
+ ClusterInfo descriptorClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.DescriptorCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("descriptor", descriptorClusterInfo);
+ ClusterInfo diagnosticLogsClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.DiagnosticLogsCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("diagnosticLogs", diagnosticLogsClusterInfo);
+ ClusterInfo doorLockClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.DoorLockCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("doorLock", doorLockClusterInfo);
+ ClusterInfo electricalMeasurementClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.ElectricalMeasurementCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("electricalMeasurement", electricalMeasurementClusterInfo);
+ ClusterInfo ethernetNetworkDiagnosticsClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) ->
+ new ChipClusters.EthernetNetworkDiagnosticsCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("ethernetNetworkDiagnostics", ethernetNetworkDiagnosticsClusterInfo);
+ ClusterInfo fixedLabelClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.FixedLabelCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("fixedLabel", fixedLabelClusterInfo);
+ ClusterInfo flowMeasurementClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.FlowMeasurementCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("flowMeasurement", flowMeasurementClusterInfo);
+ ClusterInfo generalCommissioningClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.GeneralCommissioningCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("generalCommissioning", generalCommissioningClusterInfo);
+ ClusterInfo generalDiagnosticsClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.GeneralDiagnosticsCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("generalDiagnostics", generalDiagnosticsClusterInfo);
+ ClusterInfo groupKeyManagementClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.GroupKeyManagementCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("groupKeyManagement", groupKeyManagementClusterInfo);
+ ClusterInfo groupsClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.GroupsCluster(ptr, endpointId), new HashMap<>());
+ clusterMap.put("groups", groupsClusterInfo);
+ ClusterInfo identifyClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.IdentifyCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("identify", identifyClusterInfo);
+ ClusterInfo illuminanceMeasurementClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.IlluminanceMeasurementCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("illuminanceMeasurement", illuminanceMeasurementClusterInfo);
+ ClusterInfo keypadInputClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.KeypadInputCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("keypadInput", keypadInputClusterInfo);
+ ClusterInfo levelControlClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.LevelControlCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("levelControl", levelControlClusterInfo);
+ ClusterInfo lowPowerClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.LowPowerCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("lowPower", lowPowerClusterInfo);
+ ClusterInfo mediaInputClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.MediaInputCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("mediaInput", mediaInputClusterInfo);
+ ClusterInfo mediaPlaybackClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.MediaPlaybackCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("mediaPlayback", mediaPlaybackClusterInfo);
+ ClusterInfo modeSelectClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.ModeSelectCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("modeSelect", modeSelectClusterInfo);
+ ClusterInfo networkCommissioningClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.NetworkCommissioningCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("networkCommissioning", networkCommissioningClusterInfo);
+ ClusterInfo otaSoftwareUpdateProviderClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.OtaSoftwareUpdateProviderCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("otaSoftwareUpdateProvider", otaSoftwareUpdateProviderClusterInfo);
+ ClusterInfo otaSoftwareUpdateRequestorClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) ->
+ new ChipClusters.OtaSoftwareUpdateRequestorCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("otaSoftwareUpdateRequestor", otaSoftwareUpdateRequestorClusterInfo);
+ ClusterInfo occupancySensingClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.OccupancySensingCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("occupancySensing", occupancySensingClusterInfo);
+ ClusterInfo onOffClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.OnOffCluster(ptr, endpointId), new HashMap<>());
+ clusterMap.put("onOff", onOffClusterInfo);
+ ClusterInfo onOffSwitchConfigurationClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.OnOffSwitchConfigurationCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("onOffSwitchConfiguration", onOffSwitchConfigurationClusterInfo);
+ ClusterInfo operationalCredentialsClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.OperationalCredentialsCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("operationalCredentials", operationalCredentialsClusterInfo);
+ ClusterInfo powerSourceClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.PowerSourceCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("powerSource", powerSourceClusterInfo);
+ ClusterInfo pressureMeasurementClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.PressureMeasurementCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("pressureMeasurement", pressureMeasurementClusterInfo);
+ ClusterInfo pumpConfigurationAndControlClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) ->
+ new ChipClusters.PumpConfigurationAndControlCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("pumpConfigurationAndControl", pumpConfigurationAndControlClusterInfo);
+ ClusterInfo relativeHumidityMeasurementClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) ->
+ new ChipClusters.RelativeHumidityMeasurementCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("relativeHumidityMeasurement", relativeHumidityMeasurementClusterInfo);
+ ClusterInfo scenesClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.ScenesCluster(ptr, endpointId), new HashMap<>());
+ clusterMap.put("scenes", scenesClusterInfo);
+ ClusterInfo softwareDiagnosticsClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.SoftwareDiagnosticsCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("softwareDiagnostics", softwareDiagnosticsClusterInfo);
+ ClusterInfo switchClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.SwitchCluster(ptr, endpointId), new HashMap<>());
+ clusterMap.put("switch", switchClusterInfo);
+ ClusterInfo tvChannelClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.TvChannelCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("tvChannel", tvChannelClusterInfo);
+ ClusterInfo targetNavigatorClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.TargetNavigatorCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("targetNavigator", targetNavigatorClusterInfo);
+ ClusterInfo temperatureMeasurementClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.TemperatureMeasurementCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("temperatureMeasurement", temperatureMeasurementClusterInfo);
+ ClusterInfo testClusterClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.TestClusterCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("testCluster", testClusterClusterInfo);
+ ClusterInfo thermostatClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.ThermostatCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("thermostat", thermostatClusterInfo);
+ ClusterInfo thermostatUserInterfaceConfigurationClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) ->
+ new ChipClusters.ThermostatUserInterfaceConfigurationCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put(
+ "thermostatUserInterfaceConfiguration", thermostatUserInterfaceConfigurationClusterInfo);
+ ClusterInfo threadNetworkDiagnosticsClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.ThreadNetworkDiagnosticsCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("threadNetworkDiagnostics", threadNetworkDiagnosticsClusterInfo);
+ ClusterInfo wakeOnLanClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.WakeOnLanCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("wakeOnLan", wakeOnLanClusterInfo);
+ ClusterInfo wiFiNetworkDiagnosticsClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.WiFiNetworkDiagnosticsCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("wiFiNetworkDiagnostics", wiFiNetworkDiagnosticsClusterInfo);
+ ClusterInfo windowCoveringClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.WindowCoveringCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("windowCovering", windowCoveringClusterInfo);
return clusterMap;
}
- public Map getCommandMap(Map clusterMap) {
- Map accountLoginClusterCommandInfoMap = new LinkedHashMap<>();
+ public void combineCommand(
+ Map destination, Map> source) {
+ destination.get("accountLogin").combineCommands(source.get("accountLogin"));
+ destination
+ .get("administratorCommissioning")
+ .combineCommands(source.get("administratorCommissioning"));
+ destination.get("applicationBasic").combineCommands(source.get("applicationBasic"));
+ destination.get("applicationLauncher").combineCommands(source.get("applicationLauncher"));
+ destination.get("audioOutput").combineCommands(source.get("audioOutput"));
+ destination.get("barrierControl").combineCommands(source.get("barrierControl"));
+ destination.get("basic").combineCommands(source.get("basic"));
+ destination.get("binaryInputBasic").combineCommands(source.get("binaryInputBasic"));
+ destination.get("binding").combineCommands(source.get("binding"));
+ destination.get("booleanState").combineCommands(source.get("booleanState"));
+ destination.get("bridgedActions").combineCommands(source.get("bridgedActions"));
+ destination.get("bridgedDeviceBasic").combineCommands(source.get("bridgedDeviceBasic"));
+ destination.get("colorControl").combineCommands(source.get("colorControl"));
+ destination.get("contentLauncher").combineCommands(source.get("contentLauncher"));
+ destination.get("descriptor").combineCommands(source.get("descriptor"));
+ destination.get("diagnosticLogs").combineCommands(source.get("diagnosticLogs"));
+ destination.get("doorLock").combineCommands(source.get("doorLock"));
+ destination.get("electricalMeasurement").combineCommands(source.get("electricalMeasurement"));
+ destination
+ .get("ethernetNetworkDiagnostics")
+ .combineCommands(source.get("ethernetNetworkDiagnostics"));
+ destination.get("fixedLabel").combineCommands(source.get("fixedLabel"));
+ destination.get("flowMeasurement").combineCommands(source.get("flowMeasurement"));
+ destination.get("generalCommissioning").combineCommands(source.get("generalCommissioning"));
+ destination.get("generalDiagnostics").combineCommands(source.get("generalDiagnostics"));
+ destination.get("groupKeyManagement").combineCommands(source.get("groupKeyManagement"));
+ destination.get("groups").combineCommands(source.get("groups"));
+ destination.get("identify").combineCommands(source.get("identify"));
+ destination.get("illuminanceMeasurement").combineCommands(source.get("illuminanceMeasurement"));
+ destination.get("keypadInput").combineCommands(source.get("keypadInput"));
+ destination.get("levelControl").combineCommands(source.get("levelControl"));
+ destination.get("lowPower").combineCommands(source.get("lowPower"));
+ destination.get("mediaInput").combineCommands(source.get("mediaInput"));
+ destination.get("mediaPlayback").combineCommands(source.get("mediaPlayback"));
+ destination.get("modeSelect").combineCommands(source.get("modeSelect"));
+ destination.get("networkCommissioning").combineCommands(source.get("networkCommissioning"));
+ destination
+ .get("otaSoftwareUpdateProvider")
+ .combineCommands(source.get("otaSoftwareUpdateProvider"));
+ destination
+ .get("otaSoftwareUpdateRequestor")
+ .combineCommands(source.get("otaSoftwareUpdateRequestor"));
+ destination.get("occupancySensing").combineCommands(source.get("occupancySensing"));
+ destination.get("onOff").combineCommands(source.get("onOff"));
+ destination
+ .get("onOffSwitchConfiguration")
+ .combineCommands(source.get("onOffSwitchConfiguration"));
+ destination.get("operationalCredentials").combineCommands(source.get("operationalCredentials"));
+ destination.get("powerSource").combineCommands(source.get("powerSource"));
+ destination.get("pressureMeasurement").combineCommands(source.get("pressureMeasurement"));
+ destination
+ .get("pumpConfigurationAndControl")
+ .combineCommands(source.get("pumpConfigurationAndControl"));
+ destination
+ .get("relativeHumidityMeasurement")
+ .combineCommands(source.get("relativeHumidityMeasurement"));
+ destination.get("scenes").combineCommands(source.get("scenes"));
+ destination.get("softwareDiagnostics").combineCommands(source.get("softwareDiagnostics"));
+ destination.get("switch").combineCommands(source.get("switch"));
+ destination.get("tvChannel").combineCommands(source.get("tvChannel"));
+ destination.get("targetNavigator").combineCommands(source.get("targetNavigator"));
+ destination.get("temperatureMeasurement").combineCommands(source.get("temperatureMeasurement"));
+ destination.get("testCluster").combineCommands(source.get("testCluster"));
+ destination.get("thermostat").combineCommands(source.get("thermostat"));
+ destination
+ .get("thermostatUserInterfaceConfiguration")
+ .combineCommands(source.get("thermostatUserInterfaceConfiguration"));
+ destination
+ .get("threadNetworkDiagnostics")
+ .combineCommands(source.get("threadNetworkDiagnostics"));
+ destination.get("wakeOnLan").combineCommands(source.get("wakeOnLan"));
+ destination.get("wiFiNetworkDiagnostics").combineCommands(source.get("wiFiNetworkDiagnostics"));
+ destination.get("windowCovering").combineCommands(source.get("windowCovering"));
+ }
+
+ public Map> getCommandMap() {
+ Map> commandMap = new HashMap<>();
+ Map accountLoginClusterInteractionInfoMap = new LinkedHashMap<>();
Map accountLogingetSetupPINCommandParams =
new LinkedHashMap();
CommandParameterInfo accountLogingetSetupPINtempAccountIdentifierCommandParameterInfo =
@@ -3133,8 +3506,8 @@ public Map getCommandMap(Map clusterMa
"tempAccountIdentifier", accountLogingetSetupPINtempAccountIdentifierCommandParameterInfo);
// Populate commands
- CommandInfo accountLogingetSetupPINCommandInfo =
- new CommandInfo(
+ InteractionInfo accountLogingetSetupPINInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.AccountLoginCluster) cluster)
.getSetupPIN(
@@ -3143,7 +3516,8 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedGetSetupPINResponseCallback(),
accountLogingetSetupPINCommandParams);
- accountLoginClusterCommandInfoMap.put("getSetupPIN", accountLogingetSetupPINCommandInfo);
+ accountLoginClusterInteractionInfoMap.put(
+ "getSetupPIN", accountLogingetSetupPINInteractionInfo);
Map accountLoginloginCommandParams =
new LinkedHashMap();
CommandParameterInfo accountLoginlogintempAccountIdentifierCommandParameterInfo =
@@ -3156,8 +3530,8 @@ public Map getCommandMap(Map clusterMa
accountLoginloginCommandParams.put("setupPIN", accountLoginloginsetupPINCommandParameterInfo);
// Populate commands
- CommandInfo accountLoginloginCommandInfo =
- new CommandInfo(
+ InteractionInfo accountLoginloginInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.AccountLoginCluster) cluster)
.login(
@@ -3167,14 +3541,9 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
accountLoginloginCommandParams);
- accountLoginClusterCommandInfoMap.put("login", accountLoginloginCommandInfo);
- // Populate cluster
- ClusterInfo accountLoginClusterInfo =
- new ClusterInfo(
- (ptr, endpointId) -> new ChipClusters.AccountLoginCluster(ptr, endpointId),
- accountLoginClusterCommandInfoMap);
- clusterMap.put("accountLogin", accountLoginClusterInfo);
- Map administratorCommissioningClusterCommandInfoMap =
+ accountLoginClusterInteractionInfoMap.put("login", accountLoginloginInteractionInfo);
+ commandMap.put("accountLogin", accountLoginClusterInteractionInfoMap);
+ Map administratorCommissioningClusterInteractionInfoMap =
new LinkedHashMap<>();
Map
administratorCommissioningopenBasicCommissioningWindowCommandParams =
@@ -3187,8 +3556,8 @@ public Map getCommandMap(Map clusterMa
administratorCommissioningopenBasicCommissioningWindowcommissioningTimeoutCommandParameterInfo);
// Populate commands
- CommandInfo administratorCommissioningopenBasicCommissioningWindowCommandInfo =
- new CommandInfo(
+ InteractionInfo administratorCommissioningopenBasicCommissioningWindowInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.AdministratorCommissioningCluster) cluster)
.openBasicCommissioningWindow(
@@ -3197,9 +3566,9 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
administratorCommissioningopenBasicCommissioningWindowCommandParams);
- administratorCommissioningClusterCommandInfoMap.put(
+ administratorCommissioningClusterInteractionInfoMap.put(
"openBasicCommissioningWindow",
- administratorCommissioningopenBasicCommissioningWindowCommandInfo);
+ administratorCommissioningopenBasicCommissioningWindowInteractionInfo);
Map
administratorCommissioningopenCommissioningWindowCommandParams =
new LinkedHashMap();
@@ -3244,8 +3613,8 @@ public Map getCommandMap(Map clusterMa
administratorCommissioningopenCommissioningWindowpasscodeIDCommandParameterInfo);
// Populate commands
- CommandInfo administratorCommissioningopenCommissioningWindowCommandInfo =
- new CommandInfo(
+ InteractionInfo administratorCommissioningopenCommissioningWindowInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.AdministratorCommissioningCluster) cluster)
.openCommissioningWindow(
@@ -3259,29 +3628,25 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
administratorCommissioningopenCommissioningWindowCommandParams);
- administratorCommissioningClusterCommandInfoMap.put(
- "openCommissioningWindow", administratorCommissioningopenCommissioningWindowCommandInfo);
+ administratorCommissioningClusterInteractionInfoMap.put(
+ "openCommissioningWindow",
+ administratorCommissioningopenCommissioningWindowInteractionInfo);
Map administratorCommissioningrevokeCommissioningCommandParams =
new LinkedHashMap();
// Populate commands
- CommandInfo administratorCommissioningrevokeCommissioningCommandInfo =
- new CommandInfo(
+ InteractionInfo administratorCommissioningrevokeCommissioningInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.AdministratorCommissioningCluster) cluster)
.revokeCommissioning((DefaultClusterCallback) callback);
},
() -> new DelegatedDefaultClusterCallback(),
administratorCommissioningrevokeCommissioningCommandParams);
- administratorCommissioningClusterCommandInfoMap.put(
- "revokeCommissioning", administratorCommissioningrevokeCommissioningCommandInfo);
- // Populate cluster
- ClusterInfo administratorCommissioningClusterInfo =
- new ClusterInfo(
- (ptr, endpointId) ->
- new ChipClusters.AdministratorCommissioningCluster(ptr, endpointId),
- administratorCommissioningClusterCommandInfoMap);
- clusterMap.put("administratorCommissioning", administratorCommissioningClusterInfo);
- Map applicationBasicClusterCommandInfoMap = new LinkedHashMap<>();
+ administratorCommissioningClusterInteractionInfoMap.put(
+ "revokeCommissioning", administratorCommissioningrevokeCommissioningInteractionInfo);
+ commandMap.put(
+ "administratorCommissioning", administratorCommissioningClusterInteractionInfoMap);
+ Map applicationBasicClusterInteractionInfoMap = new LinkedHashMap<>();
Map applicationBasicchangeStatusCommandParams =
new LinkedHashMap();
CommandParameterInfo applicationBasicchangeStatusstatusCommandParameterInfo =
@@ -3290,8 +3655,8 @@ public Map getCommandMap(Map clusterMa
"status", applicationBasicchangeStatusstatusCommandParameterInfo);
// Populate commands
- CommandInfo applicationBasicchangeStatusCommandInfo =
- new CommandInfo(
+ InteractionInfo applicationBasicchangeStatusInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.ApplicationBasicCluster) cluster)
.changeStatus(
@@ -3299,15 +3664,11 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
applicationBasicchangeStatusCommandParams);
- applicationBasicClusterCommandInfoMap.put(
- "changeStatus", applicationBasicchangeStatusCommandInfo);
- // Populate cluster
- ClusterInfo applicationBasicClusterInfo =
- new ClusterInfo(
- (ptr, endpointId) -> new ChipClusters.ApplicationBasicCluster(ptr, endpointId),
- applicationBasicClusterCommandInfoMap);
- clusterMap.put("applicationBasic", applicationBasicClusterInfo);
- Map applicationLauncherClusterCommandInfoMap = new LinkedHashMap<>();
+ applicationBasicClusterInteractionInfoMap.put(
+ "changeStatus", applicationBasicchangeStatusInteractionInfo);
+ commandMap.put("applicationBasic", applicationBasicClusterInteractionInfoMap);
+ Map applicationLauncherClusterInteractionInfoMap =
+ new LinkedHashMap<>();
Map applicationLauncherlaunchAppCommandParams =
new LinkedHashMap();
CommandParameterInfo applicationLauncherlaunchAppdataCommandParameterInfo =
@@ -3326,8 +3687,8 @@ public Map getCommandMap(Map clusterMa
"applicationId", applicationLauncherlaunchAppapplicationIdCommandParameterInfo);
// Populate commands
- CommandInfo applicationLauncherlaunchAppCommandInfo =
- new CommandInfo(
+ InteractionInfo applicationLauncherlaunchAppInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.ApplicationLauncherCluster) cluster)
.launchApp(
@@ -3338,15 +3699,10 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedLaunchAppResponseCallback(),
applicationLauncherlaunchAppCommandParams);
- applicationLauncherClusterCommandInfoMap.put(
- "launchApp", applicationLauncherlaunchAppCommandInfo);
- // Populate cluster
- ClusterInfo applicationLauncherClusterInfo =
- new ClusterInfo(
- (ptr, endpointId) -> new ChipClusters.ApplicationLauncherCluster(ptr, endpointId),
- applicationLauncherClusterCommandInfoMap);
- clusterMap.put("applicationLauncher", applicationLauncherClusterInfo);
- Map audioOutputClusterCommandInfoMap = new LinkedHashMap<>();
+ applicationLauncherClusterInteractionInfoMap.put(
+ "launchApp", applicationLauncherlaunchAppInteractionInfo);
+ commandMap.put("applicationLauncher", applicationLauncherClusterInteractionInfoMap);
+ Map audioOutputClusterInteractionInfoMap = new LinkedHashMap<>();
Map audioOutputrenameOutputCommandParams =
new LinkedHashMap();
CommandParameterInfo audioOutputrenameOutputindexCommandParameterInfo =
@@ -3360,8 +3716,8 @@ public Map getCommandMap(Map clusterMa
"name", audioOutputrenameOutputnameCommandParameterInfo);
// Populate commands
- CommandInfo audioOutputrenameOutputCommandInfo =
- new CommandInfo(
+ InteractionInfo audioOutputrenameOutputInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.AudioOutputCluster) cluster)
.renameOutput(
@@ -3371,7 +3727,8 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
audioOutputrenameOutputCommandParams);
- audioOutputClusterCommandInfoMap.put("renameOutput", audioOutputrenameOutputCommandInfo);
+ audioOutputClusterInteractionInfoMap.put(
+ "renameOutput", audioOutputrenameOutputInteractionInfo);
Map audioOutputselectOutputCommandParams =
new LinkedHashMap();
CommandParameterInfo audioOutputselectOutputindexCommandParameterInfo =
@@ -3380,8 +3737,8 @@ public Map getCommandMap(Map clusterMa
"index", audioOutputselectOutputindexCommandParameterInfo);
// Populate commands
- CommandInfo audioOutputselectOutputCommandInfo =
- new CommandInfo(
+ InteractionInfo audioOutputselectOutputInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.AudioOutputCluster) cluster)
.selectOutput(
@@ -3389,14 +3746,10 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
audioOutputselectOutputCommandParams);
- audioOutputClusterCommandInfoMap.put("selectOutput", audioOutputselectOutputCommandInfo);
- // Populate cluster
- ClusterInfo audioOutputClusterInfo =
- new ClusterInfo(
- (ptr, endpointId) -> new ChipClusters.AudioOutputCluster(ptr, endpointId),
- audioOutputClusterCommandInfoMap);
- clusterMap.put("audioOutput", audioOutputClusterInfo);
- Map barrierControlClusterCommandInfoMap = new LinkedHashMap<>();
+ audioOutputClusterInteractionInfoMap.put(
+ "selectOutput", audioOutputselectOutputInteractionInfo);
+ commandMap.put("audioOutput", audioOutputClusterInteractionInfoMap);
+ Map barrierControlClusterInteractionInfoMap = new LinkedHashMap<>();
Map barrierControlbarrierControlGoToPercentCommandParams =
new LinkedHashMap();
CommandParameterInfo barrierControlbarrierControlGoToPercentpercentOpenCommandParameterInfo =
@@ -3405,8 +3758,8 @@ public Map getCommandMap(Map clusterMa
"percentOpen", barrierControlbarrierControlGoToPercentpercentOpenCommandParameterInfo);
// Populate commands
- CommandInfo barrierControlbarrierControlGoToPercentCommandInfo =
- new CommandInfo(
+ InteractionInfo barrierControlbarrierControlGoToPercentInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.BarrierControlCluster) cluster)
.barrierControlGoToPercent(
@@ -3415,54 +3768,39 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
barrierControlbarrierControlGoToPercentCommandParams);
- barrierControlClusterCommandInfoMap.put(
- "barrierControlGoToPercent", barrierControlbarrierControlGoToPercentCommandInfo);
+ barrierControlClusterInteractionInfoMap.put(
+ "barrierControlGoToPercent", barrierControlbarrierControlGoToPercentInteractionInfo);
Map barrierControlbarrierControlStopCommandParams =
new LinkedHashMap();
// Populate commands
- CommandInfo barrierControlbarrierControlStopCommandInfo =
- new CommandInfo(
+ InteractionInfo barrierControlbarrierControlStopInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.BarrierControlCluster) cluster)
.barrierControlStop((DefaultClusterCallback) callback);
},
() -> new DelegatedDefaultClusterCallback(),
barrierControlbarrierControlStopCommandParams);
- barrierControlClusterCommandInfoMap.put(
- "barrierControlStop", barrierControlbarrierControlStopCommandInfo);
- // Populate cluster
- ClusterInfo barrierControlClusterInfo =
- new ClusterInfo(
- (ptr, endpointId) -> new ChipClusters.BarrierControlCluster(ptr, endpointId),
- barrierControlClusterCommandInfoMap);
- clusterMap.put("barrierControl", barrierControlClusterInfo);
- Map basicClusterCommandInfoMap = new LinkedHashMap<>();
+ barrierControlClusterInteractionInfoMap.put(
+ "barrierControlStop", barrierControlbarrierControlStopInteractionInfo);
+ commandMap.put("barrierControl", barrierControlClusterInteractionInfoMap);
+ Map basicClusterInteractionInfoMap = new LinkedHashMap<>();
Map basicmfgSpecificPingCommandParams =
new LinkedHashMap();
// Populate commands
- CommandInfo basicmfgSpecificPingCommandInfo =
- new CommandInfo(
+ InteractionInfo basicmfgSpecificPingInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.BasicCluster) cluster)
.mfgSpecificPing((DefaultClusterCallback) callback);
},
() -> new DelegatedDefaultClusterCallback(),
basicmfgSpecificPingCommandParams);
- basicClusterCommandInfoMap.put("mfgSpecificPing", basicmfgSpecificPingCommandInfo);
- // Populate cluster
- ClusterInfo basicClusterInfo =
- new ClusterInfo(
- (ptr, endpointId) -> new ChipClusters.BasicCluster(ptr, endpointId),
- basicClusterCommandInfoMap);
- clusterMap.put("basic", basicClusterInfo);
- Map binaryInputBasicClusterCommandInfoMap = new LinkedHashMap<>();
- // Populate cluster
- ClusterInfo binaryInputBasicClusterInfo =
- new ClusterInfo(
- (ptr, endpointId) -> new ChipClusters.BinaryInputBasicCluster(ptr, endpointId),
- binaryInputBasicClusterCommandInfoMap);
- clusterMap.put("binaryInputBasic", binaryInputBasicClusterInfo);
- Map bindingClusterCommandInfoMap = new LinkedHashMap<>();
+ basicClusterInteractionInfoMap.put("mfgSpecificPing", basicmfgSpecificPingInteractionInfo);
+ commandMap.put("basic", basicClusterInteractionInfoMap);
+ Map binaryInputBasicClusterInteractionInfoMap = new LinkedHashMap<>();
+ commandMap.put("binaryInputBasic", binaryInputBasicClusterInteractionInfoMap);
+ Map bindingClusterInteractionInfoMap = new LinkedHashMap<>();
Map bindingbindCommandParams =
new LinkedHashMap();
CommandParameterInfo bindingbindnodeIdCommandParameterInfo =
@@ -3482,8 +3820,8 @@ public Map getCommandMap(Map clusterMa
bindingbindCommandParams.put("clusterId", bindingbindclusterIdCommandParameterInfo);
// Populate commands
- CommandInfo bindingbindCommandInfo =
- new CommandInfo(
+ InteractionInfo bindingbindInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.BindingCluster) cluster)
.bind(
@@ -3495,7 +3833,7 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
bindingbindCommandParams);
- bindingClusterCommandInfoMap.put("bind", bindingbindCommandInfo);
+ bindingClusterInteractionInfoMap.put("bind", bindingbindInteractionInfo);
Map bindingunbindCommandParams =
new LinkedHashMap();
CommandParameterInfo bindingunbindnodeIdCommandParameterInfo =
@@ -3515,8 +3853,8 @@ public Map getCommandMap(Map clusterMa
bindingunbindCommandParams.put("clusterId", bindingunbindclusterIdCommandParameterInfo);
// Populate commands
- CommandInfo bindingunbindCommandInfo =
- new CommandInfo(
+ InteractionInfo bindingunbindInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.BindingCluster) cluster)
.unbind(
@@ -3528,21 +3866,11 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
bindingunbindCommandParams);
- bindingClusterCommandInfoMap.put("unbind", bindingunbindCommandInfo);
- // Populate cluster
- ClusterInfo bindingClusterInfo =
- new ClusterInfo(
- (ptr, endpointId) -> new ChipClusters.BindingCluster(ptr, endpointId),
- bindingClusterCommandInfoMap);
- clusterMap.put("binding", bindingClusterInfo);
- Map booleanStateClusterCommandInfoMap = new LinkedHashMap<>();
- // Populate cluster
- ClusterInfo booleanStateClusterInfo =
- new ClusterInfo(
- (ptr, endpointId) -> new ChipClusters.BooleanStateCluster(ptr, endpointId),
- booleanStateClusterCommandInfoMap);
- clusterMap.put("booleanState", booleanStateClusterInfo);
- Map bridgedActionsClusterCommandInfoMap = new LinkedHashMap<>();
+ bindingClusterInteractionInfoMap.put("unbind", bindingunbindInteractionInfo);
+ commandMap.put("binding", bindingClusterInteractionInfoMap);
+ Map booleanStateClusterInteractionInfoMap = new LinkedHashMap<>();
+ commandMap.put("booleanState", booleanStateClusterInteractionInfoMap);
+ Map bridgedActionsClusterInteractionInfoMap = new LinkedHashMap<>();
Map bridgedActionsdisableActionCommandParams =
new LinkedHashMap();
CommandParameterInfo bridgedActionsdisableActionactionIDCommandParameterInfo =
@@ -3556,8 +3884,8 @@ public Map getCommandMap(Map clusterMa
"invokeID", bridgedActionsdisableActioninvokeIDCommandParameterInfo);
// Populate commands
- CommandInfo bridgedActionsdisableActionCommandInfo =
- new CommandInfo(
+ InteractionInfo bridgedActionsdisableActionInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.BridgedActionsCluster) cluster)
.disableAction(
@@ -3567,8 +3895,8 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
bridgedActionsdisableActionCommandParams);
- bridgedActionsClusterCommandInfoMap.put(
- "disableAction", bridgedActionsdisableActionCommandInfo);
+ bridgedActionsClusterInteractionInfoMap.put(
+ "disableAction", bridgedActionsdisableActionInteractionInfo);
Map bridgedActionsdisableActionWithDurationCommandParams =
new LinkedHashMap();
CommandParameterInfo bridgedActionsdisableActionWithDurationactionIDCommandParameterInfo =
@@ -3587,8 +3915,8 @@ public Map getCommandMap(Map clusterMa
"duration", bridgedActionsdisableActionWithDurationdurationCommandParameterInfo);
// Populate commands
- CommandInfo bridgedActionsdisableActionWithDurationCommandInfo =
- new CommandInfo(
+ InteractionInfo bridgedActionsdisableActionWithDurationInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.BridgedActionsCluster) cluster)
.disableActionWithDuration(
@@ -3599,8 +3927,8 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
bridgedActionsdisableActionWithDurationCommandParams);
- bridgedActionsClusterCommandInfoMap.put(
- "disableActionWithDuration", bridgedActionsdisableActionWithDurationCommandInfo);
+ bridgedActionsClusterInteractionInfoMap.put(
+ "disableActionWithDuration", bridgedActionsdisableActionWithDurationInteractionInfo);
Map bridgedActionsenableActionCommandParams =
new LinkedHashMap();
CommandParameterInfo bridgedActionsenableActionactionIDCommandParameterInfo =
@@ -3614,8 +3942,8 @@ public Map getCommandMap(Map clusterMa
"invokeID", bridgedActionsenableActioninvokeIDCommandParameterInfo);
// Populate commands
- CommandInfo bridgedActionsenableActionCommandInfo =
- new CommandInfo(
+ InteractionInfo bridgedActionsenableActionInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.BridgedActionsCluster) cluster)
.enableAction(
@@ -3625,7 +3953,8 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
bridgedActionsenableActionCommandParams);
- bridgedActionsClusterCommandInfoMap.put("enableAction", bridgedActionsenableActionCommandInfo);
+ bridgedActionsClusterInteractionInfoMap.put(
+ "enableAction", bridgedActionsenableActionInteractionInfo);
Map bridgedActionsenableActionWithDurationCommandParams =
new LinkedHashMap();
CommandParameterInfo bridgedActionsenableActionWithDurationactionIDCommandParameterInfo =
@@ -3644,8 +3973,8 @@ public Map getCommandMap(Map clusterMa
"duration", bridgedActionsenableActionWithDurationdurationCommandParameterInfo);
// Populate commands
- CommandInfo bridgedActionsenableActionWithDurationCommandInfo =
- new CommandInfo(
+ InteractionInfo bridgedActionsenableActionWithDurationInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.BridgedActionsCluster) cluster)
.enableActionWithDuration(
@@ -3656,8 +3985,8 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
bridgedActionsenableActionWithDurationCommandParams);
- bridgedActionsClusterCommandInfoMap.put(
- "enableActionWithDuration", bridgedActionsenableActionWithDurationCommandInfo);
+ bridgedActionsClusterInteractionInfoMap.put(
+ "enableActionWithDuration", bridgedActionsenableActionWithDurationInteractionInfo);
Map bridgedActionsinstantActionCommandParams =
new LinkedHashMap();
CommandParameterInfo bridgedActionsinstantActionactionIDCommandParameterInfo =
@@ -3671,8 +4000,8 @@ public Map getCommandMap(Map clusterMa
"invokeID", bridgedActionsinstantActioninvokeIDCommandParameterInfo);
// Populate commands
- CommandInfo bridgedActionsinstantActionCommandInfo =
- new CommandInfo(
+ InteractionInfo bridgedActionsinstantActionInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.BridgedActionsCluster) cluster)
.instantAction(
@@ -3682,8 +4011,8 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
bridgedActionsinstantActionCommandParams);
- bridgedActionsClusterCommandInfoMap.put(
- "instantAction", bridgedActionsinstantActionCommandInfo);
+ bridgedActionsClusterInteractionInfoMap.put(
+ "instantAction", bridgedActionsinstantActionInteractionInfo);
Map bridgedActionsinstantActionWithTransitionCommandParams =
new LinkedHashMap();
CommandParameterInfo bridgedActionsinstantActionWithTransitionactionIDCommandParameterInfo =
@@ -3704,8 +4033,8 @@ public Map getCommandMap(Map clusterMa
bridgedActionsinstantActionWithTransitiontransitionTimeCommandParameterInfo);
// Populate commands
- CommandInfo bridgedActionsinstantActionWithTransitionCommandInfo =
- new CommandInfo(
+ InteractionInfo bridgedActionsinstantActionWithTransitionInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.BridgedActionsCluster) cluster)
.instantActionWithTransition(
@@ -3716,8 +4045,8 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
bridgedActionsinstantActionWithTransitionCommandParams);
- bridgedActionsClusterCommandInfoMap.put(
- "instantActionWithTransition", bridgedActionsinstantActionWithTransitionCommandInfo);
+ bridgedActionsClusterInteractionInfoMap.put(
+ "instantActionWithTransition", bridgedActionsinstantActionWithTransitionInteractionInfo);
Map bridgedActionspauseActionCommandParams =
new LinkedHashMap();
CommandParameterInfo bridgedActionspauseActionactionIDCommandParameterInfo =
@@ -3731,8 +4060,8 @@ public Map getCommandMap(Map clusterMa
"invokeID", bridgedActionspauseActioninvokeIDCommandParameterInfo);
// Populate commands
- CommandInfo bridgedActionspauseActionCommandInfo =
- new CommandInfo(
+ InteractionInfo bridgedActionspauseActionInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.BridgedActionsCluster) cluster)
.pauseAction(
@@ -3742,7 +4071,8 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
bridgedActionspauseActionCommandParams);
- bridgedActionsClusterCommandInfoMap.put("pauseAction", bridgedActionspauseActionCommandInfo);
+ bridgedActionsClusterInteractionInfoMap.put(
+ "pauseAction", bridgedActionspauseActionInteractionInfo);
Map bridgedActionspauseActionWithDurationCommandParams =
new LinkedHashMap();
CommandParameterInfo bridgedActionspauseActionWithDurationactionIDCommandParameterInfo =
@@ -3761,8 +4091,8 @@ public Map getCommandMap(Map clusterMa
"duration", bridgedActionspauseActionWithDurationdurationCommandParameterInfo);
// Populate commands
- CommandInfo bridgedActionspauseActionWithDurationCommandInfo =
- new CommandInfo(
+ InteractionInfo bridgedActionspauseActionWithDurationInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.BridgedActionsCluster) cluster)
.pauseActionWithDuration(
@@ -3773,8 +4103,8 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
bridgedActionspauseActionWithDurationCommandParams);
- bridgedActionsClusterCommandInfoMap.put(
- "pauseActionWithDuration", bridgedActionspauseActionWithDurationCommandInfo);
+ bridgedActionsClusterInteractionInfoMap.put(
+ "pauseActionWithDuration", bridgedActionspauseActionWithDurationInteractionInfo);
Map bridgedActionsresumeActionCommandParams =
new LinkedHashMap();
CommandParameterInfo bridgedActionsresumeActionactionIDCommandParameterInfo =
@@ -3788,8 +4118,8 @@ public Map getCommandMap(Map clusterMa
"invokeID", bridgedActionsresumeActioninvokeIDCommandParameterInfo);
// Populate commands
- CommandInfo bridgedActionsresumeActionCommandInfo =
- new CommandInfo(
+ InteractionInfo bridgedActionsresumeActionInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.BridgedActionsCluster) cluster)
.resumeAction(
@@ -3799,7 +4129,8 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
bridgedActionsresumeActionCommandParams);
- bridgedActionsClusterCommandInfoMap.put("resumeAction", bridgedActionsresumeActionCommandInfo);
+ bridgedActionsClusterInteractionInfoMap.put(
+ "resumeAction", bridgedActionsresumeActionInteractionInfo);
Map bridgedActionsstartActionCommandParams =
new LinkedHashMap();
CommandParameterInfo bridgedActionsstartActionactionIDCommandParameterInfo =
@@ -3813,8 +4144,8 @@ public Map getCommandMap(Map clusterMa
"invokeID", bridgedActionsstartActioninvokeIDCommandParameterInfo);
// Populate commands
- CommandInfo bridgedActionsstartActionCommandInfo =
- new CommandInfo(
+ InteractionInfo bridgedActionsstartActionInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.BridgedActionsCluster) cluster)
.startAction(
@@ -3824,7 +4155,8 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
bridgedActionsstartActionCommandParams);
- bridgedActionsClusterCommandInfoMap.put("startAction", bridgedActionsstartActionCommandInfo);
+ bridgedActionsClusterInteractionInfoMap.put(
+ "startAction", bridgedActionsstartActionInteractionInfo);
Map bridgedActionsstartActionWithDurationCommandParams =
new LinkedHashMap();
CommandParameterInfo bridgedActionsstartActionWithDurationactionIDCommandParameterInfo =
@@ -3843,8 +4175,8 @@ public Map getCommandMap(Map clusterMa
"duration", bridgedActionsstartActionWithDurationdurationCommandParameterInfo);
// Populate commands
- CommandInfo bridgedActionsstartActionWithDurationCommandInfo =
- new CommandInfo(
+ InteractionInfo bridgedActionsstartActionWithDurationInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.BridgedActionsCluster) cluster)
.startActionWithDuration(
@@ -3855,8 +4187,8 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
bridgedActionsstartActionWithDurationCommandParams);
- bridgedActionsClusterCommandInfoMap.put(
- "startActionWithDuration", bridgedActionsstartActionWithDurationCommandInfo);
+ bridgedActionsClusterInteractionInfoMap.put(
+ "startActionWithDuration", bridgedActionsstartActionWithDurationInteractionInfo);
Map bridgedActionsstopActionCommandParams =
new LinkedHashMap();
CommandParameterInfo bridgedActionsstopActionactionIDCommandParameterInfo =
@@ -3870,8 +4202,8 @@ public Map getCommandMap(Map clusterMa
"invokeID", bridgedActionsstopActioninvokeIDCommandParameterInfo);
// Populate commands
- CommandInfo bridgedActionsstopActionCommandInfo =
- new CommandInfo(
+ InteractionInfo bridgedActionsstopActionInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.BridgedActionsCluster) cluster)
.stopAction(
@@ -3881,21 +4213,13 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
bridgedActionsstopActionCommandParams);
- bridgedActionsClusterCommandInfoMap.put("stopAction", bridgedActionsstopActionCommandInfo);
- // Populate cluster
- ClusterInfo bridgedActionsClusterInfo =
- new ClusterInfo(
- (ptr, endpointId) -> new ChipClusters.BridgedActionsCluster(ptr, endpointId),
- bridgedActionsClusterCommandInfoMap);
- clusterMap.put("bridgedActions", bridgedActionsClusterInfo);
- Map bridgedDeviceBasicClusterCommandInfoMap = new LinkedHashMap<>();
- // Populate cluster
- ClusterInfo bridgedDeviceBasicClusterInfo =
- new ClusterInfo(
- (ptr, endpointId) -> new ChipClusters.BridgedDeviceBasicCluster(ptr, endpointId),
- bridgedDeviceBasicClusterCommandInfoMap);
- clusterMap.put("bridgedDeviceBasic", bridgedDeviceBasicClusterInfo);
- Map colorControlClusterCommandInfoMap = new LinkedHashMap<>();
+ bridgedActionsClusterInteractionInfoMap.put(
+ "stopAction", bridgedActionsstopActionInteractionInfo);
+ commandMap.put("bridgedActions", bridgedActionsClusterInteractionInfoMap);
+ Map bridgedDeviceBasicClusterInteractionInfoMap =
+ new LinkedHashMap<>();
+ commandMap.put("bridgedDeviceBasic", bridgedDeviceBasicClusterInteractionInfoMap);
+ Map colorControlClusterInteractionInfoMap = new LinkedHashMap<>();
Map colorControlcolorLoopSetCommandParams =
new LinkedHashMap();
CommandParameterInfo colorControlcolorLoopSetupdateFlagsCommandParameterInfo =
@@ -3934,8 +4258,8 @@ public Map getCommandMap(Map clusterMa
"optionsOverride", colorControlcolorLoopSetoptionsOverrideCommandParameterInfo);
// Populate commands
- CommandInfo colorControlcolorLoopSetCommandInfo =
- new CommandInfo(
+ InteractionInfo colorControlcolorLoopSetInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.ColorControlCluster) cluster)
.colorLoopSet(
@@ -3950,7 +4274,8 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
colorControlcolorLoopSetCommandParams);
- colorControlClusterCommandInfoMap.put("colorLoopSet", colorControlcolorLoopSetCommandInfo);
+ colorControlClusterInteractionInfoMap.put(
+ "colorLoopSet", colorControlcolorLoopSetInteractionInfo);
Map colorControlenhancedMoveHueCommandParams =
new LinkedHashMap();
CommandParameterInfo colorControlenhancedMoveHuemoveModeCommandParameterInfo =
@@ -3974,8 +4299,8 @@ public Map getCommandMap(Map clusterMa
"optionsOverride", colorControlenhancedMoveHueoptionsOverrideCommandParameterInfo);
// Populate commands
- CommandInfo colorControlenhancedMoveHueCommandInfo =
- new CommandInfo(
+ InteractionInfo colorControlenhancedMoveHueInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.ColorControlCluster) cluster)
.enhancedMoveHue(
@@ -3987,8 +4312,8 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
colorControlenhancedMoveHueCommandParams);
- colorControlClusterCommandInfoMap.put(
- "enhancedMoveHue", colorControlenhancedMoveHueCommandInfo);
+ colorControlClusterInteractionInfoMap.put(
+ "enhancedMoveHue", colorControlenhancedMoveHueInteractionInfo);
Map colorControlenhancedMoveToHueCommandParams =
new LinkedHashMap();
CommandParameterInfo colorControlenhancedMoveToHueenhancedHueCommandParameterInfo =
@@ -4017,8 +4342,8 @@ public Map getCommandMap(Map clusterMa
"optionsOverride", colorControlenhancedMoveToHueoptionsOverrideCommandParameterInfo);
// Populate commands
- CommandInfo colorControlenhancedMoveToHueCommandInfo =
- new CommandInfo(
+ InteractionInfo colorControlenhancedMoveToHueInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.ColorControlCluster) cluster)
.enhancedMoveToHue(
@@ -4031,8 +4356,8 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
colorControlenhancedMoveToHueCommandParams);
- colorControlClusterCommandInfoMap.put(
- "enhancedMoveToHue", colorControlenhancedMoveToHueCommandInfo);
+ colorControlClusterInteractionInfoMap.put(
+ "enhancedMoveToHue", colorControlenhancedMoveToHueInteractionInfo);
Map colorControlenhancedMoveToHueAndSaturationCommandParams =
new LinkedHashMap();
CommandParameterInfo colorControlenhancedMoveToHueAndSaturationenhancedHueCommandParameterInfo =
@@ -4065,8 +4390,8 @@ public Map getCommandMap(Map clusterMa
colorControlenhancedMoveToHueAndSaturationoptionsOverrideCommandParameterInfo);
// Populate commands
- CommandInfo colorControlenhancedMoveToHueAndSaturationCommandInfo =
- new CommandInfo(
+ InteractionInfo colorControlenhancedMoveToHueAndSaturationInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.ColorControlCluster) cluster)
.enhancedMoveToHueAndSaturation(
@@ -4079,8 +4404,9 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
colorControlenhancedMoveToHueAndSaturationCommandParams);
- colorControlClusterCommandInfoMap.put(
- "enhancedMoveToHueAndSaturation", colorControlenhancedMoveToHueAndSaturationCommandInfo);
+ colorControlClusterInteractionInfoMap.put(
+ "enhancedMoveToHueAndSaturation",
+ colorControlenhancedMoveToHueAndSaturationInteractionInfo);
Map colorControlenhancedStepHueCommandParams =
new LinkedHashMap();
CommandParameterInfo colorControlenhancedStepHuestepModeCommandParameterInfo =
@@ -4109,8 +4435,8 @@ public Map getCommandMap(Map clusterMa
"optionsOverride", colorControlenhancedStepHueoptionsOverrideCommandParameterInfo);
// Populate commands
- CommandInfo colorControlenhancedStepHueCommandInfo =
- new CommandInfo(
+ InteractionInfo colorControlenhancedStepHueInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.ColorControlCluster) cluster)
.enhancedStepHue(
@@ -4123,8 +4449,8 @@ public Map getCommandMap(Map clusterMa
},
() -> new DelegatedDefaultClusterCallback(),
colorControlenhancedStepHueCommandParams);
- colorControlClusterCommandInfoMap.put(
- "enhancedStepHue", colorControlenhancedStepHueCommandInfo);
+ colorControlClusterInteractionInfoMap.put(
+ "enhancedStepHue", colorControlenhancedStepHueInteractionInfo);
Map colorControlmoveColorCommandParams =
new LinkedHashMap();
CommandParameterInfo colorControlmoveColorrateXCommandParameterInfo =
@@ -4146,8 +4472,8 @@ public Map getCommandMap(Map clusterMa
"optionsOverride", colorControlmoveColoroptionsOverrideCommandParameterInfo);
// Populate commands
- CommandInfo colorControlmoveColorCommandInfo =
- new CommandInfo(
+ InteractionInfo colorControlmoveColorInteractionInfo =
+ new InteractionInfo(
(cluster, callback, commandArguments) -> {
((ChipClusters.ColorControlCluster) cluster)
.moveColor(
@@ -4159,7 +4485,7 @@ public Map getCommandMap(Map