示例#1
0
        private string GetScore(PSM currentPSM, string scoreColumnName, string alternativeName = "", string valueIfNotFound = "-1")
        {
            if (currentPSM.TryGetScore(scoreColumnName, out var value))
            {
                return(value);
            }

            if (!string.IsNullOrEmpty(alternativeName) && currentPSM.TryGetScore(alternativeName, out var alternativeValue))
            {
                return(alternativeValue);
            }

            return(valueIfNotFound);
        }
示例#2
0
        private static string GetScore(PSM psm, string strScoreName, string strValueIfMissing)
        {
            if (!psm.TryGetScore(strScoreName, out var strScoreValue))
            {
                strScoreValue = strValueIfMissing;
            }

            return(strScoreValue);
        }