Cgw.Common.VideoPipeManage.GetVideoPipe C# (CSharp) Метод

GetVideoPipe() публичный Метод

查询管道
public GetVideoPipe ( string cameraNO ) : VideoPipe
cameraNO string 摄像机编码
Результат VideoPipe
        public VideoPipe GetVideoPipe(string cameraNO)
        {
            if (listVideoPipeOperateLock.TryEnterWriteLock(CgwConst.ENTER_PIPE_LOCK_WAIT_TIME))
            {
                try
                {
                    int index = listVideoPipe.FindIndex((x) => { return x.CameraNo == cameraNO ? true : false; });

                    if (index != -1)
                    {
                        VideoPipe videoPipe = listVideoPipe.Find((x) => { return x.CameraNo == cameraNO ? true : false; });
                        return videoPipe;
                    }
                }
                finally
                {
                    listVideoPipeOperateLock.ExitWriteLock();
                }
            }
            return null;
        }