From 7e755f405dd1112a201b9dbde7e2d6cff8abc8f4 Mon Sep 17 00:00:00 2001 From: 648540858 <456panlinlin> Date: 星期五, 01 四月 2022 16:45:29 +0800 Subject: [PATCH] 支持国标移动位置订阅,收到新位置发送redis消息;支持通道redis消息拉起第三方推流;云台控制添加ControlPriority字段;处理sql的bug --- src/main/java/com/genersoft/iot/vmp/storager/IVideoManagerStorage.java | 963 ++++++++++++++++++++++++++++---------------------------- 1 files changed, 482 insertions(+), 481 deletions(-) diff --git a/src/main/java/com/genersoft/iot/vmp/storager/IVideoManagerStorager.java b/src/main/java/com/genersoft/iot/vmp/storager/IVideoManagerStorage.java similarity index 98% rename from src/main/java/com/genersoft/iot/vmp/storager/IVideoManagerStorager.java rename to src/main/java/com/genersoft/iot/vmp/storager/IVideoManagerStorage.java index abbe203..11d8b84 100644 --- a/src/main/java/com/genersoft/iot/vmp/storager/IVideoManagerStorager.java +++ b/src/main/java/com/genersoft/iot/vmp/storager/IVideoManagerStorage.java @@ -1,481 +1,482 @@ -package com.genersoft.iot.vmp.storager; - -import com.genersoft.iot.vmp.gb28181.bean.*; -import com.genersoft.iot.vmp.media.zlm.dto.MediaServerItem; -import com.genersoft.iot.vmp.media.zlm.dto.StreamProxyItem; -import com.genersoft.iot.vmp.media.zlm.dto.StreamPushItem; -import com.genersoft.iot.vmp.service.bean.GPSMsgInfo; -import com.genersoft.iot.vmp.storager.dao.dto.ChannelSourceInfo; -import com.genersoft.iot.vmp.vmanager.bean.DeviceChannelTree; -import com.genersoft.iot.vmp.vmanager.gb28181.platform.bean.ChannelReduce; -import com.github.pagehelper.PageInfo; - -import java.util.List; - -/** - * @description:瑙嗛璁惧鏁版嵁瀛樺偍鎺ュ彛 - * @author: swwheihei - * @date: 2020骞�5鏈�6鏃� 涓嬪崍2:14:31 - */ -@SuppressWarnings("rawtypes") -public interface IVideoManagerStorager { - - /** - * 鏍规嵁璁惧ID鍒ゆ柇璁惧鏄惁瀛樺湪 - * - * @param deviceId 璁惧ID - * @return true:瀛樺湪 false锛氫笉瀛樺湪 - */ - public boolean exists(String deviceId); - - /** - * 瑙嗛璁惧鍒涘缓 - * - * @param device 璁惧瀵硅薄 - * @return true锛氬垱寤烘垚鍔� false锛氬垱寤哄け璐� - */ - public boolean create(Device device); - - /** - * 瑙嗛璁惧鏇存柊 - * - * @param device 璁惧瀵硅薄 - * @return true锛氬垱寤烘垚鍔� false锛氬垱寤哄け璐� - */ - public boolean updateDevice(Device device); - - /** - * 娣诲姞璁惧閫氶亾 - * - * @param deviceId 璁惧id - * @param channel 閫氶亾 - */ - public void updateChannel(String deviceId, DeviceChannel channel); - - /** - * 鎵归噺娣诲姞璁惧閫氶亾 - * - * @param deviceId 璁惧id - * @param channels 澶氫釜閫氶亾 - */ - public int updateChannels(String deviceId, List<DeviceChannel> channels); - - /** - * 寮�濮嬫挱鏀� - * @param deviceId 璁惧id - * @param channelId 閫氶亾ID - * @param streamId 娴佸湴鍧� - */ - public void startPlay(String deviceId, String channelId, String streamId); - - /** - * 鍋滄鎾斁 - * @param deviceId 璁惧id - * @param channelId 閫氶亾ID - */ - public void stopPlay(String deviceId, String channelId); - - /** - * 鑾峰彇璁惧 - * - * @param deviceId 璁惧ID - * @return DShadow 璁惧瀵硅薄 - */ - public Device queryVideoDevice(String deviceId); - - /** - * 鑾峰彇鏌愪釜璁惧鐨勯�氶亾鍒楄〃 - * - * @param deviceId 璁惧ID - * @param page 鍒嗛〉 褰撳墠椤� - * @param count 姣忛〉鏁伴噺 - * @return - */ - public PageInfo queryChannelsByDeviceId(String deviceId, String query, Boolean hasSubChannel, Boolean online, int page, int count); - - public List<DeviceChannel> queryChannelsByDeviceIdWithStartAndLimit(String deviceId, String query, Boolean hasSubChannel, Boolean online, int start, int limit); - - /** - * 鑾峰彇鏌愪釜璁惧鐨勯�氶亾鏍� - * @param deviceId 璁惧ID - * @return - */ - List<DeviceChannelTree> tree(String deviceId); - - /** - * 鑾峰彇鏌愪釜璁惧鐨勯�氶亾鍒楄〃 - * - * @param deviceId 璁惧ID - * @return - */ - public List<DeviceChannel> queryChannelsByDeviceId(String deviceId); - public List<DeviceChannel> queryOnlineChannelsByDeviceId(String deviceId); - - /** - * 鑾峰彇鏌愪釜璁惧鐨勯�氶亾 - * @param deviceId 璁惧ID - * @param channelId 閫氶亾ID - */ - public DeviceChannel queryChannel(String deviceId, String channelId); - - /** - * 鍒犻櫎閫氶亾 - * @param deviceId 璁惧ID - * @param channelId 閫氶亾ID - */ - public int delChannel(String deviceId, String channelId); - - /** - * 鑾峰彇澶氫釜璁惧 - * @param page 褰撳墠椤垫暟 - * @param count 姣忛〉鏁伴噺 - * @return List<Device> 璁惧瀵硅薄鏁扮粍 - */ - public PageInfo<Device> queryVideoDeviceList(int page, int count); - - /** - * 鑾峰彇澶氫釜璁惧 - * - * @return List<Device> 璁惧瀵硅薄鏁扮粍 - */ - public List<Device> queryVideoDeviceList(); - - /** - * 鍒犻櫎璁惧 - * - * @param deviceId 璁惧ID - * @return true锛氬垹闄ゆ垚鍔� false锛氬垹闄ゅけ璐� - */ - public boolean delete(String deviceId); - - /** - * 鏇存柊璁惧鍦ㄧ嚎 - * - * @param deviceId 璁惧ID - * @return true锛氭洿鏂版垚鍔� false锛氭洿鏂板け璐� - */ - public boolean online(String deviceId); - - /** - * 鏇存柊璁惧绂荤嚎 - * - * @param deviceId 璁惧ID - * @return true锛氭洿鏂版垚鍔� false锛氭洿鏂板け璐� - */ - public boolean outline(String deviceId); - - /** - * 鏇存柊鎵�鏈夎澶囩绾� - * - * @return true锛氭洿鏂版垚鍔� false锛氭洿鏂板け璐� - */ - public boolean outlineForAll(); - - - /** - * 鏌ヨ瀛愯澶� - * - * @param deviceId - * @param channelId - * @param page - * @param count - * @return - */ - PageInfo querySubChannels(String deviceId, String channelId, String query, Boolean hasSubChannel, String online, int page, int count); - - - /** - * 娓呯┖閫氶亾 - * @param deviceId - */ - void cleanChannelsForDevice(String deviceId); - - - /** - * 鏇存柊涓婄骇骞冲彴 - * @param parentPlatform - */ - boolean updateParentPlatform(ParentPlatform parentPlatform); - - - /** - * 娣诲姞涓婄骇骞冲彴 - * @param parentPlatform - */ - boolean addParentPlatform(ParentPlatform parentPlatform); - - /** - * 鍒犻櫎涓婄骇骞冲彴 - * @param parentPlatform - */ - boolean deleteParentPlatform(ParentPlatform parentPlatform); - - - /** - * 鍒嗛〉鑾峰彇涓婄骇骞冲彴 - * @param page - * @param count - * @return - */ - PageInfo<ParentPlatform> queryParentPlatformList(int page, int count); - - /** - * 鑾峰彇鎵�鏈夊凡鍚敤鐨勫钩鍙� - * @return - */ - List<ParentPlatform> queryEnableParentPlatformList(boolean enable); - - /** - * 鑾峰彇涓婄骇骞冲彴 - * @param platformGbId - * @return - */ - ParentPlatform queryParentPlatByServerGBId(String platformGbId); - - /** - * 鎵�鏈夊钩鍙扮绾� - */ - void outlineForAllParentPlatform(); - - /** - * 鏌ヨ閫氶亾淇℃伅锛屼笉鍖哄垎璁惧(宸插叧鑱斿钩鍙版垨鍏ㄩ儴) - */ - PageInfo<ChannelReduce> queryAllChannelList(int page, int count, String query, Boolean online, Boolean channelType, String platformId, String catalogId); - - /** - * 鏌ヨ璁惧鐨勯�氶亾淇℃伅 - */ - List<DeviceChannelInPlatform> queryChannelListInParentPlatform(String platformId); - - - /** - * 鏇存柊涓婄骇骞冲彴鐨勯�氶亾淇℃伅 - * @param platformId - * @param channelReduces - * @return - */ - int updateChannelForGB(String platformId, List<ChannelReduce> channelReduces, String catalogId); - - /** - * 绉婚櫎涓婄骇骞冲彴鐨勯�氶亾淇℃伅 - * @param platformId - * @param channelReduces - * @return - */ - int delChannelForGB(String platformId, List<ChannelReduce> channelReduces); - - - DeviceChannel queryChannelInParentPlatform(String platformId, String channelId); - - List<PlatformCatalog> queryChannelInParentPlatformAndCatalog(String platformId, String catalogId); - List<PlatformCatalog> queryStreamInParentPlatformAndCatalog(String platformId, String catalogId); - - Device queryVideoDeviceByPlatformIdAndChannelId(String platformId, String channelId); - - - /** - * 娣诲姞Mobile Position璁惧绉诲姩浣嶇疆 - * @param mobilePosition - * @return - */ - public boolean insertMobilePosition(MobilePosition mobilePosition); - - /** - * 鏌ヨ绉诲姩浣嶇疆杞ㄨ抗 - * @param deviceId - * @param startTime - * @param endTime - */ - public List<MobilePosition> queryMobilePositions(String deviceId, String startTime, String endTime); - - /** - * 鏌ヨ鏈�鏂扮Щ鍔ㄤ綅缃� - * @param deviceId - */ - public MobilePosition queryLatestPosition(String deviceId); - - /** - * 鍒犻櫎鎸囧畾璁惧鐨勬墍鏈夌Щ鍔ㄤ綅缃� - * @param deviceId - */ - public int clearMobilePositionsByDeviceId(String deviceId); - - /** - * 鏂板浠g悊娴� - * @param streamProxyDto - * @return - */ - public boolean addStreamProxy(StreamProxyItem streamProxyDto); - - /** - * 鏇存柊浠g悊娴� - * @param streamProxyDto - * @return - */ - public boolean updateStreamProxy(StreamProxyItem streamProxyDto); - - /** - * 绉婚櫎浠g悊娴� - * @param app - * @param stream - * @return - */ - public int deleteStreamProxy(String app, String stream); - - /** - * 鎸夌収鏄惁鍚敤鑾峰彇浠g悊娴� - * @param enable - * @return - */ - public List<StreamProxyItem> getStreamProxyListForEnable(boolean enable); - - /** - * 鎸夌収鏄痑pp鍜宻tream鑾峰彇浠g悊娴� - * @param app - * @param stream - * @return - */ - public StreamProxyItem queryStreamProxy(String app, String stream); - - /** - * 鑾峰彇浠g悊娴� - * @param page - * @param count - * @return - */ - PageInfo<StreamProxyItem> queryStreamProxyList(Integer page, Integer count); - - /** - * 鏍规嵁鍥芥爣ID鑾峰彇骞冲彴鍏宠仈鐨勭洿鎾祦 - * @param platformId - * @param channelId - * @return - */ - GbStream queryStreamInParentPlatform(String platformId, String channelId); - - /** - * 鑾峰彇骞冲彴鍏宠仈鐨勭洿鎾祦 - * @param platformId - * @return - */ - List<GbStream> queryGbStreamListInPlatform(String platformId); - - /** - * 鎵归噺鏇存柊鎺ㄦ祦鍒楄〃 - * @param streamPushItems - */ - void updateMediaList(List<StreamPushItem> streamPushItems); - - /** - * 鏇存柊鍗曚釜鎺ㄦ祦 - * @param streamPushItem - */ - void updateMedia(StreamPushItem streamPushItem); - - /** - * 绉婚櫎鍗曚釜鎺ㄦ祦 - * @param app - * @param stream - */ - int removeMedia(String app, String stream); - - - /** - * 娓呯┖鎺ㄦ祦鍒楄〃 - */ - void clearMediaList(); - - /** - * 璁剧疆娴佺绾� - * @param app - * @param streamId - */ - int mediaOutline(String app, String streamId); - - /** - * 璁剧疆骞冲彴鍦ㄧ嚎/绂荤嚎 - * @param online - */ - void updateParentPlatformStatus(String platformGbID, boolean online); - - /** - * 鏍规嵁濯掍綋ID鑾峰彇鍚敤/涓嶅惎鐢ㄧ殑浠g悊鍒楄〃 - * @param id 濯掍綋ID - * @param enable 鍚敤/涓嶅惎鐢� - * @param status 鐘舵�� - * @return - */ - List<StreamProxyItem> getStreamProxyListForEnableInMediaServer(String id, boolean enable, boolean status); - - /** - * 鏍规嵁閫氶亾ID鑾峰彇鍏舵墍鍦ㄨ澶� - * @param channelId 閫氶亾ID - * @return - */ - Device queryVideoDeviceByChannelId(String channelId); - - /** - * 閫氶亾涓婄嚎 - * @param channelId 閫氶亾ID - */ - void deviceChannelOnline(String deviceId, String channelId); - - /** - * 閫氶亾绂荤嚎 - * @param channelId 閫氶亾ID - */ - void deviceChannelOffline(String deviceId, String channelId); - - /** - * 閫氳繃app涓巗tream鑾峰彇StreamProxy - * @param app - * @param streamId - * @return - */ - StreamProxyItem getStreamProxyByAppAndStream(String app, String streamId); - - /** - * catlog鏌ヨ缁撴潫鍚庡畬鍏ㄩ噸鍐欓�氶亾淇℃伅 - * @param deviceId - * @param deviceChannelList - */ - boolean resetChannels(String deviceId, List<DeviceChannel> deviceChannelList); - - /** - * 鑾峰彇鐩綍淇℃伅 - * @param platformId - * @param parentId - * @return - */ - List<PlatformCatalog> getChildrenCatalogByPlatform(String platformId, String parentId); - - int addCatalog(PlatformCatalog platformCatalog); - - PlatformCatalog getCatalog(String id); - - int delCatalog(String id); - - int updateCatalog(PlatformCatalog platformCatalog); - - int setDefaultCatalog(String platformId, String catalogId); - - List<PlatformCatalog> queryCatalogInPlatform(String serverGBId); - - int delRelation(PlatformCatalog platformCatalog); - - int updateStreamGPS(List<GPSMsgInfo> gpsMsgInfo); - - List<ParentPlatform> queryPlatFormListForGBWithGBId(String channelId, List<String> platforms); - - List<ParentPlatform> queryPlatFormListForStreamWithGBId(String app, String stream, List<String> platforms); - - GbStream getGbStream(String app, String streamId); - - void delCatalogByPlatformId(String serverGBId); - - void delRelationByPlatformId(String serverGBId); - - PlatformCatalog queryDefaultCatalogInPlatform(String platformId); - - List<ChannelSourceInfo> getChannelSource(String platformId, String gbId); -} +package com.genersoft.iot.vmp.storager; + +import com.genersoft.iot.vmp.gb28181.bean.*; +import com.genersoft.iot.vmp.media.zlm.dto.StreamProxyItem; +import com.genersoft.iot.vmp.media.zlm.dto.StreamPushItem; +import com.genersoft.iot.vmp.service.bean.GPSMsgInfo; +import com.genersoft.iot.vmp.storager.dao.dto.ChannelSourceInfo; +import com.genersoft.iot.vmp.vmanager.bean.DeviceChannelTree; +import com.genersoft.iot.vmp.vmanager.gb28181.platform.bean.ChannelReduce; +import com.github.pagehelper.PageInfo; + +import java.util.List; + +/** + * @description:瑙嗛璁惧鏁版嵁瀛樺偍鎺ュ彛 + * @author: swwheihei + * @date: 2020骞�5鏈�6鏃� 涓嬪崍2:14:31 + */ +@SuppressWarnings("rawtypes") +public interface IVideoManagerStorage { + + /** + * 鏍规嵁璁惧ID鍒ゆ柇璁惧鏄惁瀛樺湪 + * + * @param deviceId 璁惧ID + * @return true:瀛樺湪 false锛氫笉瀛樺湪 + */ + public boolean exists(String deviceId); + + /** + * 瑙嗛璁惧鍒涘缓 + * + * @param device 璁惧瀵硅薄 + * @return true锛氬垱寤烘垚鍔� false锛氬垱寤哄け璐� + */ + public boolean create(Device device); + + /** + * 瑙嗛璁惧鏇存柊 + * + * @param device 璁惧瀵硅薄 + * @return true锛氬垱寤烘垚鍔� false锛氬垱寤哄け璐� + */ + public boolean updateDevice(Device device); + + /** + * 娣诲姞璁惧閫氶亾 + * + * @param deviceId 璁惧id + * @param channel 閫氶亾 + */ + public void updateChannel(String deviceId, DeviceChannel channel); + + /** + * 鎵归噺娣诲姞璁惧閫氶亾 + * + * @param deviceId 璁惧id + * @param channels 澶氫釜閫氶亾 + */ + public int updateChannels(String deviceId, List<DeviceChannel> channels); + + /** + * 寮�濮嬫挱鏀� + * @param deviceId 璁惧id + * @param channelId 閫氶亾ID + * @param streamId 娴佸湴鍧� + */ + public void startPlay(String deviceId, String channelId, String streamId); + + /** + * 鍋滄鎾斁 + * @param deviceId 璁惧id + * @param channelId 閫氶亾ID + */ + public void stopPlay(String deviceId, String channelId); + + /** + * 鑾峰彇璁惧 + * + * @param deviceId 璁惧ID + * @return DShadow 璁惧瀵硅薄 + */ + public Device queryVideoDevice(String deviceId); + + /** + * 鑾峰彇鏌愪釜璁惧鐨勯�氶亾鍒楄〃 + * + * @param deviceId 璁惧ID + * @param page 鍒嗛〉 褰撳墠椤� + * @param count 姣忛〉鏁伴噺 + * @return + */ + public PageInfo queryChannelsByDeviceId(String deviceId, String query, Boolean hasSubChannel, Boolean online, int page, int count); + + public List<DeviceChannel> queryChannelsByDeviceIdWithStartAndLimit(String deviceId, String query, Boolean hasSubChannel, Boolean online, int start, int limit); + + /** + * 鑾峰彇鏌愪釜璁惧鐨勯�氶亾鏍� + * @param deviceId 璁惧ID + * @return + */ + List<DeviceChannelTree> tree(String deviceId); + + /** + * 鑾峰彇鏌愪釜璁惧鐨勯�氶亾鍒楄〃 + * + * @param deviceId 璁惧ID + * @return + */ + public List<DeviceChannel> queryChannelsByDeviceId(String deviceId); + public List<DeviceChannel> queryOnlineChannelsByDeviceId(String deviceId); + + /** + * 鑾峰彇鏌愪釜璁惧鐨勯�氶亾 + * @param deviceId 璁惧ID + * @param channelId 閫氶亾ID + */ + public DeviceChannel queryChannel(String deviceId, String channelId); + + /** + * 鍒犻櫎閫氶亾 + * @param deviceId 璁惧ID + * @param channelId 閫氶亾ID + */ + public int delChannel(String deviceId, String channelId); + + /** + * 鑾峰彇澶氫釜璁惧 + * @param page 褰撳墠椤垫暟 + * @param count 姣忛〉鏁伴噺 + * @return List<Device> 璁惧瀵硅薄鏁扮粍 + */ + public PageInfo<Device> queryVideoDeviceList(int page, int count); + + /** + * 鑾峰彇澶氫釜璁惧 + * + * @return List<Device> 璁惧瀵硅薄鏁扮粍 + */ + public List<Device> queryVideoDeviceList(); + + /** + * 鍒犻櫎璁惧 + * + * @param deviceId 璁惧ID + * @return true锛氬垹闄ゆ垚鍔� false锛氬垹闄ゅけ璐� + */ + public boolean delete(String deviceId); + + /** + * 鏇存柊璁惧鍦ㄧ嚎 + * + * @param deviceId 璁惧ID + * @return true锛氭洿鏂版垚鍔� false锛氭洿鏂板け璐� + */ + public boolean online(String deviceId); + + /** + * 鏇存柊璁惧绂荤嚎 + * + * @param deviceId 璁惧ID + * @return true锛氭洿鏂版垚鍔� false锛氭洿鏂板け璐� + */ + public boolean outline(String deviceId); + + /** + * 鏇存柊鎵�鏈夎澶囩绾� + * + * @return true锛氭洿鏂版垚鍔� false锛氭洿鏂板け璐� + */ + public boolean outlineForAll(); + + + /** + * 鏌ヨ瀛愯澶� + * + * @param deviceId + * @param channelId + * @param page + * @param count + * @return + */ + PageInfo querySubChannels(String deviceId, String channelId, String query, Boolean hasSubChannel, String online, int page, int count); + + + /** + * 娓呯┖閫氶亾 + * @param deviceId + */ + void cleanChannelsForDevice(String deviceId); + + + /** + * 鏇存柊涓婄骇骞冲彴 + * @param parentPlatform + */ + boolean updateParentPlatform(ParentPlatform parentPlatform); + + + /** + * 娣诲姞涓婄骇骞冲彴 + * @param parentPlatform + */ + boolean addParentPlatform(ParentPlatform parentPlatform); + + /** + * 鍒犻櫎涓婄骇骞冲彴 + * @param parentPlatform + */ + boolean deleteParentPlatform(ParentPlatform parentPlatform); + + + /** + * 鍒嗛〉鑾峰彇涓婄骇骞冲彴 + * @param page + * @param count + * @return + */ + PageInfo<ParentPlatform> queryParentPlatformList(int page, int count); + + /** + * 鑾峰彇鎵�鏈夊凡鍚敤鐨勫钩鍙� + * @return + */ + List<ParentPlatform> queryEnableParentPlatformList(boolean enable); + + /** + * 鑾峰彇涓婄骇骞冲彴 + * @param platformGbId + * @return + */ + ParentPlatform queryParentPlatByServerGBId(String platformGbId); + + /** + * 鎵�鏈夊钩鍙扮绾� + */ + void outlineForAllParentPlatform(); + + /** + * 鏌ヨ閫氶亾淇℃伅锛屼笉鍖哄垎璁惧(宸插叧鑱斿钩鍙版垨鍏ㄩ儴) + */ + PageInfo<ChannelReduce> queryAllChannelList(int page, int count, String query, Boolean online, Boolean channelType, String platformId, String catalogId); + + /** + * 鏌ヨ璁惧鐨勯�氶亾淇℃伅 + */ + List<DeviceChannelInPlatform> queryChannelListInParentPlatform(String platformId); + + + /** + * 鏇存柊涓婄骇骞冲彴鐨勯�氶亾淇℃伅 + * @param platformId + * @param channelReduces + * @return + */ + int updateChannelForGB(String platformId, List<ChannelReduce> channelReduces, String catalogId); + + /** + * 绉婚櫎涓婄骇骞冲彴鐨勯�氶亾淇℃伅 + * @param platformId + * @param channelReduces + * @return + */ + int delChannelForGB(String platformId, List<ChannelReduce> channelReduces); + + + DeviceChannel queryChannelInParentPlatform(String platformId, String channelId); + + List<PlatformCatalog> queryChannelInParentPlatformAndCatalog(String platformId, String catalogId); + List<PlatformCatalog> queryStreamInParentPlatformAndCatalog(String platformId, String catalogId); + + Device queryVideoDeviceByPlatformIdAndChannelId(String platformId, String channelId); + + + /** + * 娣诲姞Mobile Position璁惧绉诲姩浣嶇疆 + * @param mobilePosition + * @return + */ + public boolean insertMobilePosition(MobilePosition mobilePosition); + + /** + * 鏌ヨ绉诲姩浣嶇疆杞ㄨ抗 + * @param deviceId + * @param startTime + * @param endTime + */ + public List<MobilePosition> queryMobilePositions(String deviceId, String startTime, String endTime); + + /** + * 鏌ヨ鏈�鏂扮Щ鍔ㄤ綅缃� + * @param deviceId + */ + public MobilePosition queryLatestPosition(String deviceId); + + /** + * 鍒犻櫎鎸囧畾璁惧鐨勬墍鏈夌Щ鍔ㄤ綅缃� + * @param deviceId + */ + public int clearMobilePositionsByDeviceId(String deviceId); + + /** + * 鏂板浠g悊娴� + * @param streamProxyDto + * @return + */ + public boolean addStreamProxy(StreamProxyItem streamProxyDto); + + /** + * 鏇存柊浠g悊娴� + * @param streamProxyDto + * @return + */ + public boolean updateStreamProxy(StreamProxyItem streamProxyDto); + + /** + * 绉婚櫎浠g悊娴� + * @param app + * @param stream + * @return + */ + public int deleteStreamProxy(String app, String stream); + + /** + * 鎸夌収鏄惁鍚敤鑾峰彇浠g悊娴� + * @param enable + * @return + */ + public List<StreamProxyItem> getStreamProxyListForEnable(boolean enable); + + /** + * 鎸夌収鏄痑pp鍜宻tream鑾峰彇浠g悊娴� + * @param app + * @param stream + * @return + */ + public StreamProxyItem queryStreamProxy(String app, String stream); + + /** + * 鑾峰彇浠g悊娴� + * @param page + * @param count + * @return + */ + PageInfo<StreamProxyItem> queryStreamProxyList(Integer page, Integer count); + + /** + * 鏍规嵁鍥芥爣ID鑾峰彇骞冲彴鍏宠仈鐨勭洿鎾祦 + * @param platformId + * @param channelId + * @return + */ + GbStream queryStreamInParentPlatform(String platformId, String channelId); + + /** + * 鑾峰彇骞冲彴鍏宠仈鐨勭洿鎾祦 + * @param platformId + * @return + */ + List<GbStream> queryGbStreamListInPlatform(String platformId); + + /** + * 鎵归噺鏇存柊鎺ㄦ祦鍒楄〃 + * @param streamPushItems + */ + void updateMediaList(List<StreamPushItem> streamPushItems); + + /** + * 鏇存柊鍗曚釜鎺ㄦ祦 + * @param streamPushItem + */ + void updateMedia(StreamPushItem streamPushItem); + + /** + * 绉婚櫎鍗曚釜鎺ㄦ祦 + * @param app + * @param stream + */ + int removeMedia(String app, String stream); + + + /** + * 娓呯┖鎺ㄦ祦鍒楄〃 + */ + void clearMediaList(); + + /** + * 璁剧疆娴佺绾� + * @param app + * @param streamId + */ + int mediaOutline(String app, String streamId); + + /** + * 璁剧疆骞冲彴鍦ㄧ嚎/绂荤嚎 + * @param online + */ + void updateParentPlatformStatus(String platformGbID, boolean online); + + /** + * 鏍规嵁濯掍綋ID鑾峰彇鍚敤/涓嶅惎鐢ㄧ殑浠g悊鍒楄〃 + * @param id 濯掍綋ID + * @param enable 鍚敤/涓嶅惎鐢� + * @param status 鐘舵�� + * @return + */ + List<StreamProxyItem> getStreamProxyListForEnableInMediaServer(String id, boolean enable, boolean status); + + /** + * 鏍规嵁閫氶亾ID鑾峰彇鍏舵墍鍦ㄨ澶� + * @param channelId 閫氶亾ID + * @return + */ + Device queryVideoDeviceByChannelId(String channelId); + + /** + * 閫氶亾涓婄嚎 + * @param channelId 閫氶亾ID + */ + void deviceChannelOnline(String deviceId, String channelId); + + /** + * 閫氶亾绂荤嚎 + * @param channelId 閫氶亾ID + */ + void deviceChannelOffline(String deviceId, String channelId); + + /** + * 閫氳繃app涓巗tream鑾峰彇StreamProxy + * @param app + * @param streamId + * @return + */ + StreamProxyItem getStreamProxyByAppAndStream(String app, String streamId); + + /** + * catlog鏌ヨ缁撴潫鍚庡畬鍏ㄩ噸鍐欓�氶亾淇℃伅 + * @param deviceId + * @param deviceChannelList + */ + boolean resetChannels(String deviceId, List<DeviceChannel> deviceChannelList); + + /** + * 鑾峰彇鐩綍淇℃伅 + * @param platformId + * @param parentId + * @return + */ + List<PlatformCatalog> getChildrenCatalogByPlatform(String platformId, String parentId); + + int addCatalog(PlatformCatalog platformCatalog); + + PlatformCatalog getCatalog(String id); + + int delCatalog(String id); + + int updateCatalog(PlatformCatalog platformCatalog); + + int setDefaultCatalog(String platformId, String catalogId); + + List<PlatformCatalog> queryCatalogInPlatform(String serverGBId); + + int delRelation(PlatformCatalog platformCatalog); + + int updateStreamGPS(List<GPSMsgInfo> gpsMsgInfo); + + List<ParentPlatform> queryPlatFormListForGBWithGBId(String channelId, List<String> platforms); + + List<ParentPlatform> queryPlatFormListForStreamWithGBId(String app, String stream, List<String> platforms); + + GbStream getGbStream(String app, String streamId); + + void delCatalogByPlatformId(String serverGBId); + + void delRelationByPlatformId(String serverGBId); + + PlatformCatalog queryDefaultCatalogInPlatform(String platformId); + + List<ChannelSourceInfo> getChannelSource(String platformId, String gbId); + + void updateChannelPotion(String deviceId, String channelId, double longitude, double latitude); +} -- Gitblit v1.8.0