| {{> header}} |
| #include <jni/CHIPCallbackTypes.h> |
| |
| #include <app-common/zap-generated/cluster-objects.h> |
| #include <jni.h> |
| #include <zap-generated/CHIPClientCallbacks.h> |
| |
| namespace chip { |
| |
| {{#zcl_clusters}} |
| {{#zcl_commands_source_server}} |
| class CHIP{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase commandName}}Callback : public Callback::Callback<CHIP{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase commandName}}CallbackType> |
| { |
| public: |
| CHIP{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase commandName}}Callback(jobject javaCallback); |
| |
| ~CHIP{{asUpperCamelCase parent.name}}Cluster{{asUpperCamelCase commandName}}Callback(); |
| |
| static void CallbackFn(void * context, const chip::app::Clusters::{{asUpperCamelCase parent.name}}::Commands::{{asUpperCamelCase commandName}}::DecodableType & data); |
| |
| private: |
| jobject javaCallbackRef; |
| }; |
| |
| {{/zcl_commands_source_server}} |
| {{/zcl_clusters}} |
| } // namespace chip |