示例#1
0
        public ushort GuessAnRtpPortForSender(
            [FromHeader(Name = "AccessKey")] string AccessKey, string mediaServerId, ushort?min = 0, ushort?max = 0)
        {
            ResponseStruct rs;
            var            ret = AKStreamKeeperService.GuessAnRtpPortForSender(mediaServerId, out rs, min, max);

            if (!rs.Code.Equals(ErrorNumber.None))
            {
                throw new AkStreamException(rs);
            }

            return(ret);
        }
示例#2
0
        public bool ReleaseRtpPortForSender(
            [FromHeader(Name = "AccessKey")] string AccessKey, string mediaServerId, ushort port)
        {
            ResponseStruct rs;
            var            ret = AKStreamKeeperService.ReleaseRtpPortForSender(mediaServerId, port, out rs);

            if (!rs.Code.Equals(ErrorNumber.None))
            {
                throw new AkStreamException(rs);
            }

            return(ret);
        }
        public ResKeeperCheckMediaServerRunning CheckMediaServerRunning(
            [FromHeader(Name = "AccessKey")] string AccessKey, string mediaServerId)
        {
            ResponseStruct rs;
            var            ret = AKStreamKeeperService.CheckMediaServerRunning(mediaServerId, out rs);

            if (ret == null || !rs.Code.Equals(ErrorNumber.None))
            {
                throw new AkStreamException(rs);
            }

            return(ret);
        }
        public ResKeeperCutMergeTaskStatusResponseList GetBacklogTaskList(
            [FromHeader(Name = "AccessKey")] string AccessKey, string mediaServerId)
        {
            ResponseStruct rs;
            var            ret = AKStreamKeeperService.GetBacklogTaskList(mediaServerId, out rs);

            if (!rs.Code.Equals(ErrorNumber.None))
            {
                throw new AkStreamException(rs);
            }

            return(ret);
        }
        public bool ShutdownMediaServer(
            [FromHeader(Name = "AccessKey")] string AccessKey, string mediaServerId)
        {
            ResponseStruct rs;
            var            ret = AKStreamKeeperService.ShutdownMediaServer(mediaServerId, out rs);

            if (!rs.Code.Equals(ErrorNumber.None))
            {
                throw new AkStreamException(rs);
            }

            return(ret);
        }
        public ResKeeperCutMergeTaskResponse AddCutOrMergeTask(
            [FromHeader(Name = "AccessKey")] string AccessKey, string mediaServerId, ReqKeeperCutMergeTask reqKeeper)
        {
            ResponseStruct rs;
            var            ret = AKStreamKeeperService.AddCutOrMergeTask(mediaServerId, reqKeeper, out rs);

            if (!rs.Code.Equals(ErrorNumber.None))
            {
                throw new AkStreamException(rs);
            }

            return(ret);
        }
        public bool CleanUpEmptyDir(
            [FromHeader(Name = "AccessKey")] string AccessKey, string mediaServerId, string?filePath = "")
        {
            ResponseStruct rs;
            var            ret = AKStreamKeeperService.CleanUpEmptyDir(mediaServerId, out rs, filePath);

            if (!rs.Code.Equals(ErrorNumber.None))
            {
                throw new AkStreamException(rs);
            }

            return(ret);
        }
        public ResKeeperDeleteFileList DeleteFileList(
            [FromHeader(Name = "AccessKey")] string AccessKey, string mediaServerId, List <string> fileList)
        {
            ResponseStruct rs;
            var            ret = AKStreamKeeperService.DeleteFileList(mediaServerId, fileList, out rs);

            if (!rs.Code.Equals(ErrorNumber.None))
            {
                throw new AkStreamException(rs);
            }

            return(ret);
        }
        public bool FileExists(
            [FromHeader(Name = "AccessKey")] string AccessKey, string mediaServerId, string filePath)
        {
            ResponseStruct rs;
            var            ret = AKStreamKeeperService.FileExists(mediaServerId, filePath, out rs);

            if (!rs.Code.Equals(ErrorNumber.None))
            {
                throw new AkStreamException(rs);
            }

            return(ret);
        }
示例#10
0
        public bool DelFFmpegTemplate([FromHeader(Name = "AccessKey")] string AccessKey, string mediaServerId,
                                      string templateName)
        {
            ResponseStruct rs;
            var            ret = AKStreamKeeperService.DelFFmpegTemplate(mediaServerId, templateName, out rs);

            if (!rs.Code.Equals(ErrorNumber.None))
            {
                throw new AkStreamException(rs);
            }

            return(ret);
        }
示例#11
0
        public List <KeyValuePair <string, string> > GetFFmpegTemplateList(
            [FromHeader(Name = "AccessKey")] string AccessKey, string mediaServerId)
        {
            ResponseStruct rs;
            var            ret = AKStreamKeeperService.GetFFmpegTemplateList(mediaServerId, out rs);

            if (!rs.Code.Equals(ErrorNumber.None))
            {
                throw new AkStreamException(rs);
            }

            return(ret);
        }