-
public interface IThingHomeDataManager
Manage 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 GroupBean
getGroupBean(long groupId)
Get GroupBean by group id. abstract DeviceBean
getDeviceBean(String devId)
Get DeviceBean by device id. abstract RoomBean
getGroupRoomBean(long groupId)
Get RoomBean by group id. abstract RoomBean
getRoomBean(long roomId)
Get RoomBean by room id. abstract RoomBean
getDeviceRoomBean(String devId)
Get RoomBean by device id. abstract RoomBean
getRoomBeanByHomeInDevice(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 HomeBean
getHomeBean(long homeId)
Get HomeBean abstract List<DeviceBean>
getSubDeviceBean(String devId)
Get the list of sub-devices by the parent device id abstract DeviceBean
getSubDeviceBeanByNodeId(String devId, String nodeId)
Get DeviceBean of sub-device by the parent device id and sub-device node id. abstract ProductBean
getProductBean(String productId)
use getProductBeanByVer abstract ProductBean
getProductBeanByVer(String productId, String productVer)
Get ProductBean by product id and product version. abstract void
getPanelInfoBean(String productId, IThingDataCallback<ProductPanelInfoBean> callback)
abstract void
getPanelInfoBean(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 Object
getDp(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 DeviceRespBean
getDevRespBean(String devId)
Get DeviceRespBean by device id. abstract DeviceRespBean
getSubDevRespBean(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 void
getProductRefList(long homeId, IThingDataCallback<ArrayList<ProductRefBean>> callback)
Gets ProductRefBean list. abstract ProductRefBean
getProductRefBean(String productId)
Gets ProductRefBean. abstract void
getProductRefBean(String productId, long homeId, IThingDataCallback<ProductRefBean> callback)
Gets product ref list. abstract void
addDevRespList(List<DeviceRespBean> deviceRespBeans)
Add the list of DeviceRespBean to cache. abstract void
addProductList(List<ProductBean> productBeans)
Add the list of ProductBean to cache. abstract void
queryDev(String devId, IThingDataCallback<DeviceBean> callback)
Query DeviceBean from server. abstract void
queryDev(long homeId, String devId, IThingDataCallback<DeviceBean> callback)
Query DeviceBean from server, generally use {queryDev} abstract void
queryGroup(long groupId, IThingDataCallback<GroupBean> callback)
Query GroupBean from server. abstract void
querySubDev(String meshId, String devId, IThingDataCallback<DeviceBean> callback)
Query DeviceBean of sub-device from server. abstract void
getSubDevList(String devId, IThingDataCallback<List<DeviceBean>> callback)
Query the DeviceBean of the sub-device list from server. abstract void
discoveredLanDevice(IThingSearchDeviceListener listener)
Register local area network discovery device listener. abstract void
unRegisterDiscoveredLanDeviceListener(IThingSearchDeviceListener listener)
Unregister local area network discovery device listener. abstract ProductStandardConfig
getStandardProductConfig(String productId)
Get standard product config from cache. abstract boolean
isStandardProduct(String productId)
Determine whether it is standard device. abstract IStandardConverter
getStandardConverter()
Get standard product standard code/id converter. abstract void
getStandardProductConfig(String productId, IThingDataCallback<ProductStandardConfig> callback)
Get standard product config from cloud. abstract void
getStandardProductConfigList(long homeId, IThingDataCallback<ArrayList<ProductStandardConfig>> callback)
Gets standard product config list by homeID. abstract boolean
hasHomeCacheData(long homeId)
whether home data based on homeid abstract boolean
isHomeAdmin(long homeId)
get home isAdmin based on homeid abstract int
getHomeRole(long homeId)
get home role based on homeid abstract void
setAutoLoadPanelInfo(boolean autoLoad)
should load panel info after home data retrieved, default is false abstract boolean
shouldAutoLoadPanelInfo()
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
-
-
-
-