-
public interface IThingHomeDataManagerManage the cache of homes, rooms, groups, and devices.
-
-
Method Summary
Modifier and Type Method Description abstract List<RoomBean>getHomeRoomList(long homeId)Get the list of rooms in the home. abstract List<GroupBean>getHomeGroupList(long homeId)Get the list of groups in the home. abstract List<DeviceBean>getHomeDeviceList(long homeId)Get the list of devices in the home. abstract List<BlueMeshBean>getHomeMeshList(long homeId)Get the list of mesh devices in the home. abstract List<SigMeshBean>getHomeSigMeshList(long homeId)Get the list of sigmesh devices in the home. abstract List<DeviceBean>getHomeShareDeviceList(long homeId)Get the list of share devices in the home. abstract List<GroupBean>getHomeShareGroupList(long homeId)Get the list of share groups in the home. abstract GroupBeangetGroupBean(long groupId)Get GroupBean by group id. abstract DeviceBeangetDeviceBean(String devId)Get DeviceBean by device id. abstract RoomBeangetGroupRoomBean(long groupId)Get RoomBean by group id. abstract RoomBeangetRoomBean(long roomId)Get RoomBean by room id. abstract RoomBeangetDeviceRoomBean(String devId)Get RoomBean by device id. abstract RoomBeangetRoomBeanByHomeInDevice(long homeId, String devId)Get RoomBean by device id and homeid. abstract List<DeviceBean>getGroupDeviceList(long groupId)Get the list of devices in the group. abstract List<GroupBean>getMeshGroupList(String meshId)Get the list of groups in the mesh. abstract List<DeviceBean>getMeshDeviceList(String meshId)Get the list of devices in the mesh. abstract List<DeviceBean>getRoomDeviceList(long roomId)Get the list of devices in the room. abstract List<GroupBean>getRoomGroupList(long roomId)Get the list of groups in the room. abstract HomeBeangetHomeBean(long homeId)Get HomeBean abstract List<DeviceBean>getSubDeviceBean(String devId)Get the list of sub-devices by the parent device id abstract DeviceBeangetSubDeviceBeanByNodeId(String devId, String nodeId)Get DeviceBean of sub-device by the parent device id and sub-device node id. abstract ProductBeangetProductBean(String productId)use getProductBeanByVer abstract ProductBeangetProductBeanByVer(String productId, String productVer)Get ProductBean by product id and product version. abstract voidgetPanelInfoBean(String productId, IThingDataCallback<ProductPanelInfoBean> callback)abstract voidgetPanelInfoBean(String productId, String productVer, IThingDataCallback<ProductPanelInfoBean> callback)abstract ArrayList<DeviceAndGroupInHomeBean>getHidedDeviceGroupListCache(Long homeId)get the cache list of device and group with hide tag abstract ObjectgetDp(String devId, String dpId)Get data point value by device id and data point id. abstract Map<String, Object>getDps(String devId)Get data points values. abstract Map<String, SchemaBean>getSchema(String devId)Get schema info by device id. abstract DeviceRespBeangetDevRespBean(String devId)Get DeviceRespBean by device id. abstract DeviceRespBeangetSubDevRespBean(String meshId, String nodeId)Get DeviceRespBean of sub-devices by the parent device id and sub-device node id. abstract List<DeviceRespBean>getDevRespBeanList()Get list of DeviceRespBean in current home. abstract HashMap<String, ProductRefBean>getProductRefList()Get extra product properties. abstract voidgetProductRefList(long homeId, IThingDataCallback<ArrayList<ProductRefBean>> callback)Gets ProductRefBean list. abstract ProductRefBeangetProductRefBean(String productId)Gets ProductRefBean. abstract voidgetProductRefBean(String productId, long homeId, IThingDataCallback<ProductRefBean> callback)Gets product ref list. abstract voidaddDevRespList(List<DeviceRespBean> deviceRespBeans)Add the list of DeviceRespBean to cache. abstract voidaddProductList(List<ProductBean> productBeans)Add the list of ProductBean to cache. abstract voidqueryDev(String devId, IThingDataCallback<DeviceBean> callback)Query DeviceBean from server. abstract voidqueryDev(long homeId, String devId, IThingDataCallback<DeviceBean> callback)Query DeviceBean from server, generally use {queryDev} abstract voidqueryGroup(long groupId, IThingDataCallback<GroupBean> callback)Query GroupBean from server. abstract voidquerySubDev(String meshId, String devId, IThingDataCallback<DeviceBean> callback)Query DeviceBean of sub-device from server. abstract voidgetSubDevList(String devId, IThingDataCallback<List<DeviceBean>> callback)Query the DeviceBean of the sub-device list from server. abstract voiddiscoveredLanDevice(IThingSearchDeviceListener listener)Register local area network discovery device listener. abstract voidunRegisterDiscoveredLanDeviceListener(IThingSearchDeviceListener listener)Unregister local area network discovery device listener. abstract ProductStandardConfiggetStandardProductConfig(String productId)Get standard product config from cache. abstract booleanisStandardProduct(String productId)Determine whether it is standard device. abstract IStandardConvertergetStandardConverter()Get standard product standard code/id converter. abstract voidgetStandardProductConfig(String productId, IThingDataCallback<ProductStandardConfig> callback)Get standard product config from cloud. abstract voidgetStandardProductConfigList(long homeId, IThingDataCallback<ArrayList<ProductStandardConfig>> callback)Gets standard product config list by homeID. abstract booleanhasHomeCacheData(long homeId)whether home data based on homeid abstract booleanisHomeAdmin(long homeId)get home isAdmin based on homeid abstract intgetHomeRole(long homeId)get home role based on homeid abstract voidsetAutoLoadPanelInfo(boolean autoLoad)should load panel info after home data retrieved, default is false abstract booleanshouldAutoLoadPanelInfo()should load panel info after home data retrieved -
-
Method Detail
-
getHomeRoomList
abstract List<RoomBean> getHomeRoomList(long homeId)
Get the list of rooms in the home.
- Parameters:
homeId- home id
-
getHomeGroupList
abstract List<GroupBean> getHomeGroupList(long homeId)
Get the list of groups in the home.
- Parameters:
homeId- home id
-
getHomeDeviceList
abstract List<DeviceBean> getHomeDeviceList(long homeId)
Get the list of devices in the home.
- Parameters:
homeId- home id
-
getHomeMeshList
abstract List<BlueMeshBean> getHomeMeshList(long homeId)
Get the list of mesh devices in the home.
- Parameters:
homeId- home id
-
getHomeSigMeshList
abstract List<SigMeshBean> getHomeSigMeshList(long homeId)
Get the list of sigmesh devices in the home.
- Parameters:
homeId- home id
-
getHomeShareDeviceList
abstract List<DeviceBean> getHomeShareDeviceList(long homeId)
Get the list of share devices in the home.
- Parameters:
homeId- home id
-
getHomeShareGroupList
abstract List<GroupBean> getHomeShareGroupList(long homeId)
Get the list of share groups in the home.
- Parameters:
homeId- home id
-
getGroupBean
abstract GroupBean getGroupBean(long groupId)
Get GroupBean by group id.
- Parameters:
groupId- group id
-
getDeviceBean
abstract DeviceBean getDeviceBean(String devId)
Get DeviceBean by device id.
- Parameters:
devId- device id
-
getGroupRoomBean
abstract RoomBean getGroupRoomBean(long groupId)
Get RoomBean by group id.
- Parameters:
groupId- group id
-
getRoomBean
abstract RoomBean getRoomBean(long roomId)
Get RoomBean by room id.
- Parameters:
roomId- room id
-
getDeviceRoomBean
abstract RoomBean getDeviceRoomBean(String devId)
Get RoomBean by device id.
- Parameters:
devId- device id
-
getRoomBeanByHomeInDevice
abstract RoomBean getRoomBeanByHomeInDevice(long homeId, String devId)
Get RoomBean by device id and homeid.
- Parameters:
homeId- home iddevId- device id
-
getGroupDeviceList
abstract List<DeviceBean> getGroupDeviceList(long groupId)
Get the list of devices in the group.
- Parameters:
groupId- group id
-
getMeshGroupList
abstract List<GroupBean> getMeshGroupList(String meshId)
Get the list of groups in the mesh.
- Parameters:
meshId- meshId
-
getMeshDeviceList
abstract List<DeviceBean> getMeshDeviceList(String meshId)
Get the list of devices in the mesh.
- Parameters:
meshId- meshId
-
getRoomDeviceList
abstract List<DeviceBean> getRoomDeviceList(long roomId)
Get the list of devices in the room.
- Parameters:
roomId- roomId
-
getRoomGroupList
abstract List<GroupBean> getRoomGroupList(long roomId)
Get the list of groups in the room.
- Parameters:
roomId- roomId
-
getHomeBean
abstract HomeBean getHomeBean(long homeId)
Get HomeBean
- Parameters:
homeId- homeId
-
getSubDeviceBean
abstract List<DeviceBean> getSubDeviceBean(String devId)
Get the list of sub-devices by the parent device id
- Parameters:
devId- parent device id.
-
getSubDeviceBeanByNodeId
abstract DeviceBean getSubDeviceBeanByNodeId(String devId, String nodeId)
Get DeviceBean of sub-device by the parent device id and sub-device node id.
- Parameters:
devId- parent device id.nodeId- sub-device node id.
-
getProductBean
@Deprecated() abstract ProductBean getProductBean(String productId)
- Parameters:
productId- product id.
-
getProductBeanByVer
abstract ProductBean getProductBeanByVer(String productId, String productVer)
Get ProductBean by product id and product version.
- Parameters:
productId- product id.
-
getPanelInfoBean
abstract void getPanelInfoBean(String productId, IThingDataCallback<ProductPanelInfoBean> callback)
-
getPanelInfoBean
abstract void getPanelInfoBean(String productId, String productVer, IThingDataCallback<ProductPanelInfoBean> callback)
-
getHidedDeviceGroupListCache
abstract ArrayList<DeviceAndGroupInHomeBean> getHidedDeviceGroupListCache(Long homeId)
get the cache list of device and group with hide tag
-
getDp
abstract Object getDp(String devId, String dpId)
Get data point value by device id and data point id.
- Parameters:
devId- device iddpId- data point id
-
getDps
abstract Map<String, Object> getDps(String devId)
Get data points values.
- Parameters:
devId- device id.
-
getSchema
abstract Map<String, SchemaBean> getSchema(String devId)
Get schema info by device id.
- Parameters:
devId- devId
-
getDevRespBean
abstract DeviceRespBean getDevRespBean(String devId)
Get DeviceRespBean by device id.
- Parameters:
devId- devId
-
getSubDevRespBean
abstract DeviceRespBean getSubDevRespBean(String meshId, String nodeId)
Get DeviceRespBean of sub-devices by the parent device id and sub-device node id.
- Parameters:
meshId- parent device id.nodeId- sub-device node id.
-
getDevRespBeanList
abstract List<DeviceRespBean> getDevRespBeanList()
Get list of DeviceRespBean in current home.
-
getProductRefList
abstract HashMap<String, ProductRefBean> getProductRefList()
Get extra product properties.
-
getProductRefList
@Deprecated() abstract void getProductRefList(long homeId, IThingDataCallback<ArrayList<ProductRefBean>> callback)
Gets ProductRefBean list.
- Parameters:
homeId- the home idcallback- the callback
-
getProductRefBean
abstract ProductRefBean getProductRefBean(String productId)
Gets ProductRefBean.
- Parameters:
productId- the product id
-
getProductRefBean
@Deprecated() abstract void getProductRefBean(String productId, long homeId, IThingDataCallback<ProductRefBean> callback)
Gets product ref list.
- Parameters:
productId- the product IdhomeId- the home idcallback- the callback
-
addDevRespList
abstract void addDevRespList(List<DeviceRespBean> deviceRespBeans)
Add the list of DeviceRespBean to cache.
- Parameters:
deviceRespBeans- the list of DeviceRespBean
-
addProductList
abstract void addProductList(List<ProductBean> productBeans)
Add the list of ProductBean to cache.
- Parameters:
productBeans- the list of ProductBean
-
queryDev
abstract void queryDev(String devId, IThingDataCallback<DeviceBean> callback)
Query DeviceBean from server.
- Parameters:
devId- device idcallback- callback
-
queryDev
abstract void queryDev(long homeId, String devId, IThingDataCallback<DeviceBean> callback)
Query DeviceBean from server, generally use {queryDev}
- Parameters:
homeId- homeId, can be 0 or -1.devId- device id.callback- callback
-
queryGroup
abstract void queryGroup(long groupId, IThingDataCallback<GroupBean> callback)
Query GroupBean from server.
- Parameters:
groupId- group idcallback- callback
-
querySubDev
abstract void querySubDev(String meshId, String devId, IThingDataCallback<DeviceBean> callback)
Query DeviceBean of sub-device from server.
- Parameters:
meshId- parent device id.devId- sub-device id.callback- callback
-
getSubDevList
abstract void getSubDevList(String devId, IThingDataCallback<List<DeviceBean>> callback)
Query the DeviceBean of the sub-device list from server.
- Parameters:
devId- parent device id.callback- callback
-
discoveredLanDevice
abstract void discoveredLanDevice(IThingSearchDeviceListener listener)
Register local area network discovery device listener.
- Parameters:
listener- local area network discovery device listener, IThingSearchDeviceListener.
-
unRegisterDiscoveredLanDeviceListener
abstract void unRegisterDiscoveredLanDeviceListener(IThingSearchDeviceListener listener)
Unregister local area network discovery device listener.
- Parameters:
listener- local area network discovery device listener, IThingSearchDeviceListener.
-
getStandardProductConfig
abstract ProductStandardConfig getStandardProductConfig(String productId)
Get standard product config from cache.
- Parameters:
productId- Product id.
-
isStandardProduct
abstract boolean isStandardProduct(String productId)
Determine whether it is standard device.
Indicates whether the use of standard control commands is supported.
- Parameters:
productId- the product id
-
getStandardConverter
abstract IStandardConverter getStandardConverter()
Get standard product standard code/id converter.
-
getStandardProductConfig
abstract void getStandardProductConfig(String productId, IThingDataCallback<ProductStandardConfig> callback)
Get standard product config from cloud.
- Parameters:
productId- Product id.
-
getStandardProductConfigList
@Deprecated() abstract void getStandardProductConfigList(long homeId, IThingDataCallback<ArrayList<ProductStandardConfig>> callback)
Gets standard product config list by homeID.
- Parameters:
homeId- the home idcallback- the callback
-
hasHomeCacheData
abstract boolean hasHomeCacheData(long homeId)
whether home data based on homeid
- Parameters:
homeId- the home id
-
isHomeAdmin
abstract boolean isHomeAdmin(long homeId)
get home isAdmin based on homeid
- Parameters:
homeId- the home id
-
getHomeRole
abstract int getHomeRole(long homeId)
get home role based on homeid
- Parameters:
homeId- the home id
-
setAutoLoadPanelInfo
abstract void setAutoLoadPanelInfo(boolean autoLoad)
should load panel info after home data retrieved, default is false
-
shouldAutoLoadPanelInfo
abstract boolean shouldAutoLoadPanelInfo()
should load panel info after home data retrieved
-
-
-
-