コード例 #1
0
        public IEnumerable <GitCommit> IntersectWith(ListOfCommits commits)
        {
            var result = new HashSet <string>(_hashset);

            result.IntersectWith(commits._hashset);

            return(Commits.Where(commit => commits.Contains(commit.Sha)));
        }
コード例 #2
0
 public GitRepository(
     IReadOnlyCollection <GitBranch> branches,
     IReadOnlyCollection <GitCommit> commits,
     IReadOnlyCollection <GitTag> tags)
 {
     Branches      = branches;
     Master        = OriginMasterOrMasterCommits(branches);
     Develop       = OriginDevelopOrDevelopCommits(branches);
     CurrentBranch = new ListOfCommits(commits);
     Tags          = tags;
 }
コード例 #3
0
 public GitRepository(
     IReadOnlyCollection <GitBranch> branches,
     IReadOnlyCollection <GitCommit> commits,
     IReadOnlyCollection <GitTag> tags,
     bool isRepoDirty)
 {
     _commits      = commits;
     Branches      = branches;
     Master        = OriginMasterOrMasterCommits(branches);
     Develop       = OriginDevelopOrDevelopCommits(branches);
     CurrentBranch = new ListOfCommits(commits);
     Tags          = tags;
     IsDirty       = isRepoDirty;
 }
コード例 #4
0
 public IEnumerable <string> Except(ListOfCommits commits) => _hashset.Except(commits._hashset);
コード例 #5
0
 public bool SetEquals(ListOfCommits commits) => _hashset.SetEquals(commits._hashset);
コード例 #6
0
 public bool Overlaps(ListOfCommits commits) => _hashset.Overlaps(commits._hashset);