Configuring the Binding Relationship
API Function
This API is used to configure the IP address and port number of the IoT platform before binding a device.
API Description
1 | public static boolean setConfig(int key, String value);
|
Class
BindConfig
Parameter Description
| Parameter | Mandatory or Optional | Type | Description |
|---|---|---|---|
| key | Mandatory | int | Configuration items used for device binding.
|
| value | Mandatory | String | Value of each configuration item.
|
Return Value
| Return Value | Description |
|---|---|
| true | Success |
| false | Failure |
Example
1 2 3 | //Call this API to configure the IP address and port number of the IoT platform for device binding.
BindConfig.setConfig(BindConfig.BIND_CONFIG_ADDR, "127.0.0.1");
BindConfig.setConfig(BindConfig.BIND_CONFIG_PORT, "8943");
|
Last Article: Releasing AgentLite Resources
Next Article: Binding a Device
Did this article solve your problem?
Thank you for your score!Your feedback would help us improve the website.