コード例 #1
0
        static Changeset ParseChangesetSpec(string csetSpec)
        {
            Match match = SPEC_REGEX.Match(csetSpec);

            if (!match.Success)
            {
                return(null);
            }

            return(new Changeset(
                       double.Parse(match.Groups["id"].Value),
                       match.Groups["brName"].Value,
                       match.Groups["repName"].Value,
                       match.Groups["repServer"].Value));
        }
コード例 #2
0
        public static Branch ParsePlasticBranchEnvironVar(
            string environVarValue)
        {
            if (string.IsNullOrEmpty(environVarValue))
            {
                return(null);
            }

            Match match = SPEC_REGEX.Match(environVarValue);

            if (!match.Success)
            {
                return(null);
            }

            return(new Branch(
                       match.Groups["brName"].Value,
                       match.Groups["repName"].Value,
                       match.Groups["serverName"].Value));
        }