Mercurial > hg4j
comparison src/org/tmatesoft/hg/core/ChangesetTransformer.java @ 205:ffc5f6d59f7e
HgLogCommand.Handler is used in few places, pull up to top-level class, HgChangesetHandler
author | Artem Tikhomirov <tikhomirov.artem@gmail.com> |
---|---|
date | Thu, 28 Apr 2011 02:00:42 +0200 |
parents | c9b305df0b89 |
children | 41a778e3fd31 |
comparison
equal
deleted
inserted
replaced
204:883f1efbcf27 | 205:ffc5f6d59f7e |
---|---|
17 package org.tmatesoft.hg.core; | 17 package org.tmatesoft.hg.core; |
18 | 18 |
19 import java.util.Set; | 19 import java.util.Set; |
20 | 20 |
21 import org.tmatesoft.hg.repo.HgChangelog; | 21 import org.tmatesoft.hg.repo.HgChangelog; |
22 import org.tmatesoft.hg.repo.HgChangelog.RawChangeset; | |
22 import org.tmatesoft.hg.repo.HgRepository; | 23 import org.tmatesoft.hg.repo.HgRepository; |
23 import org.tmatesoft.hg.repo.HgStatusCollector; | 24 import org.tmatesoft.hg.repo.HgStatusCollector; |
24 import org.tmatesoft.hg.repo.HgChangelog.RawChangeset; | |
25 import org.tmatesoft.hg.util.PathPool; | 25 import org.tmatesoft.hg.util.PathPool; |
26 import org.tmatesoft.hg.util.PathRewrite; | 26 import org.tmatesoft.hg.util.PathRewrite; |
27 | 27 |
28 /** | 28 /** |
29 * Bridges {@link HgChangelog.RawChangeset} with high-level {@link HgChangeset} API | 29 * Bridges {@link HgChangelog.RawChangeset} with high-level {@link HgChangeset} API |
30 * | 30 * |
31 * @author Artem Tikhomirov | 31 * @author Artem Tikhomirov |
32 * @author TMate Software Ltd. | 32 * @author TMate Software Ltd. |
33 */ | 33 */ |
34 /*package-local*/ class ChangesetTransformer implements HgChangelog.Inspector { | 34 /*package-local*/ class ChangesetTransformer implements HgChangelog.Inspector { |
35 private final HgLogCommand.Handler handler; | 35 private final HgChangesetHandler handler; |
36 private final HgChangeset changeset; | 36 private final HgChangeset changeset; |
37 private Set<String> branches; | 37 private Set<String> branches; |
38 | 38 |
39 // repo and delegate can't be null, parent walker can | 39 // repo and delegate can't be null, parent walker can |
40 public ChangesetTransformer(HgRepository hgRepo, HgLogCommand.Handler delegate, HgChangelog.ParentWalker pw) { | 40 public ChangesetTransformer(HgRepository hgRepo, HgChangesetHandler delegate, HgChangelog.ParentWalker pw) { |
41 if (hgRepo == null || delegate == null) { | 41 if (hgRepo == null || delegate == null) { |
42 throw new IllegalArgumentException(); | 42 throw new IllegalArgumentException(); |
43 } | 43 } |
44 HgStatusCollector statusCollector = new HgStatusCollector(hgRepo); | 44 HgStatusCollector statusCollector = new HgStatusCollector(hgRepo); |
45 // files listed in a changeset don't need their names to be rewritten (they are normalized already) | 45 // files listed in a changeset don't need their names to be rewritten (they are normalized already) |