From 56996e2138bc6a50e716e66945c2773db02833f5 Mon Sep 17 00:00:00 2001 From: Lawrence <1934378145@qq.com> Date: Thu, 29 Oct 2020 10:16:39 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=AD=A3=E6=8B=BC=E5=86=99=E9=94=99?= =?UTF-8?q?=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../iot/vmp/gb28181/transmit/cmd/impl/SIPCommander.java | 2 +- .../genersoft/iot/vmp/storager/IVideoManagerStorager.java | 8 ++++---- .../vmp/storager/jdbc/VideoManagerJdbcStoragerImpl.java | 8 ++++---- .../vmp/storager/redis/VideoManagerRedisStoragerImpl.java | 8 ++++---- 4 files changed, 13 insertions(+), 13 deletions(-) diff --git a/src/main/java/com/genersoft/iot/vmp/gb28181/transmit/cmd/impl/SIPCommander.java b/src/main/java/com/genersoft/iot/vmp/gb28181/transmit/cmd/impl/SIPCommander.java index 047918cb..a33678c4 100644 --- a/src/main/java/com/genersoft/iot/vmp/gb28181/transmit/cmd/impl/SIPCommander.java +++ b/src/main/java/com/genersoft/iot/vmp/gb28181/transmit/cmd/impl/SIPCommander.java @@ -329,7 +329,7 @@ public class SIPCommander implements ISIPCommander { streamInfo.setSsrc(ssrc); streamInfo.setCahnnelId(channelId); streamInfo.setDeviceID(device.getDeviceId()); - boolean b = storager.startPlayBlack(streamInfo); + boolean b = storager.startPlayback(streamInfo); return streamInfo; } catch ( SipException | ParseException | InvalidArgumentException e) { diff --git a/src/main/java/com/genersoft/iot/vmp/storager/IVideoManagerStorager.java b/src/main/java/com/genersoft/iot/vmp/storager/IVideoManagerStorager.java index 26809220..fdf4bc33 100644 --- a/src/main/java/com/genersoft/iot/vmp/storager/IVideoManagerStorager.java +++ b/src/main/java/com/genersoft/iot/vmp/storager/IVideoManagerStorager.java @@ -184,11 +184,11 @@ public interface IVideoManagerStorager { Map queryPlayByDeviceId(String deviceId); - boolean startPlayBlack(StreamInfo streamInfo); + boolean startPlayback(StreamInfo streamInfo); - boolean stopPlayBlack(StreamInfo streamInfo); + boolean stopPlayback(StreamInfo streamInfo); - StreamInfo queryPlayBlackByDevice(String deviceId, String channelId); + StreamInfo queryPlaybackByDevice(String deviceId, String channelId); - StreamInfo queryPlayBlackBySSRC(String ssrc); + StreamInfo queryPlaybackBySSRC(String ssrc); } diff --git a/src/main/java/com/genersoft/iot/vmp/storager/jdbc/VideoManagerJdbcStoragerImpl.java b/src/main/java/com/genersoft/iot/vmp/storager/jdbc/VideoManagerJdbcStoragerImpl.java index de94f865..75b9c929 100644 --- a/src/main/java/com/genersoft/iot/vmp/storager/jdbc/VideoManagerJdbcStoragerImpl.java +++ b/src/main/java/com/genersoft/iot/vmp/storager/jdbc/VideoManagerJdbcStoragerImpl.java @@ -195,22 +195,22 @@ public class VideoManagerJdbcStoragerImpl implements IVideoManagerStorager { } @Override - public boolean startPlayBlack(StreamInfo streamInfo) { + public boolean startPlayback(StreamInfo streamInfo) { return false; } @Override - public boolean stopPlayBlack(StreamInfo streamInfo) { + public boolean stopPlayback(StreamInfo streamInfo) { return false; } @Override - public StreamInfo queryPlayBlackByDevice(String deviceId, String channelId) { + public StreamInfo queryPlaybackByDevice(String deviceId, String channelId) { return null; } @Override - public StreamInfo queryPlayBlackBySSRC(String ssrc) { + public StreamInfo queryPlaybackBySSRC(String ssrc) { return null; } } diff --git a/src/main/java/com/genersoft/iot/vmp/storager/redis/VideoManagerRedisStoragerImpl.java b/src/main/java/com/genersoft/iot/vmp/storager/redis/VideoManagerRedisStoragerImpl.java index e6a680b8..7c3a2fc8 100644 --- a/src/main/java/com/genersoft/iot/vmp/storager/redis/VideoManagerRedisStoragerImpl.java +++ b/src/main/java/com/genersoft/iot/vmp/storager/redis/VideoManagerRedisStoragerImpl.java @@ -409,7 +409,7 @@ public class VideoManagerRedisStoragerImpl implements IVideoManagerStorager { } @Override - public StreamInfo queryPlayBlackBySSRC(String ssrc) { + public StreamInfo queryPlaybackBySSRC(String ssrc) { // List playLeys = redis.keys(String.format("%S_%s_*", VideoManagerConstants.PLAYER_PREFIX, ssrc)); List playLeys = redis.scan(String.format("%S_%s_*", VideoManagerConstants.PLAY_BLACK_PREFIX, ssrc)); if (playLeys == null || playLeys.size() == 0) return null; @@ -505,14 +505,14 @@ public class VideoManagerRedisStoragerImpl implements IVideoManagerStorager { @Override - public boolean startPlayBlack(StreamInfo stream) { + public boolean startPlayback(StreamInfo stream) { return redis.set(String.format("%S_%s_%s_%s", VideoManagerConstants.PLAY_BLACK_PREFIX, stream.getSsrc(),stream.getDeviceID(), stream.getCahnnelId()), stream); } @Override - public boolean stopPlayBlack(StreamInfo streamInfo) { + public boolean stopPlayback(StreamInfo streamInfo) { if (streamInfo == null) return false; DeviceChannel deviceChannel = queryChannel(streamInfo.getDeviceID(), streamInfo.getCahnnelId()); if (deviceChannel != null) { @@ -527,7 +527,7 @@ public class VideoManagerRedisStoragerImpl implements IVideoManagerStorager { } @Override - public StreamInfo queryPlayBlackByDevice(String deviceId, String code) { + public StreamInfo queryPlaybackByDevice(String deviceId, String code) { String format = String.format("%S_*_%s_%s", VideoManagerConstants.PLAY_BLACK_PREFIX, deviceId, code);