comparison src/org/tmatesoft/hg/core/ChangesetTransformer.java @ 628:6526d8adbc0f

Explicit HgRuntimeException to facilitate easy switch from runtime to checked exceptions
author Artem Tikhomirov <tikhomirov.artem@gmail.com>
date Wed, 22 May 2013 15:52:31 +0200
parents 1ee452f31187
children
comparison
equal deleted inserted replaced
627:5153eb73b18d 628:6526d8adbc0f
1 /* 1 /*
2 * Copyright (c) 2011-2012 TMate Software Ltd 2 * Copyright (c) 2011-2013 TMate Software Ltd
3 * 3 *
4 * This program is free software; you can redistribute it and/or modify 4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by 5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; version 2 of the License. 6 * the Free Software Foundation; version 2 of the License.
7 * 7 *
22 import org.tmatesoft.hg.internal.LifecycleBridge; 22 import org.tmatesoft.hg.internal.LifecycleBridge;
23 import org.tmatesoft.hg.internal.PathPool; 23 import org.tmatesoft.hg.internal.PathPool;
24 import org.tmatesoft.hg.repo.HgChangelog; 24 import org.tmatesoft.hg.repo.HgChangelog;
25 import org.tmatesoft.hg.repo.HgChangelog.RawChangeset; 25 import org.tmatesoft.hg.repo.HgChangelog.RawChangeset;
26 import org.tmatesoft.hg.repo.HgRepository; 26 import org.tmatesoft.hg.repo.HgRepository;
27 import org.tmatesoft.hg.repo.HgRuntimeException;
27 import org.tmatesoft.hg.repo.HgStatusCollector; 28 import org.tmatesoft.hg.repo.HgStatusCollector;
28 import org.tmatesoft.hg.repo.HgParentChildMap; 29 import org.tmatesoft.hg.repo.HgParentChildMap;
29 import org.tmatesoft.hg.util.Adaptable; 30 import org.tmatesoft.hg.util.Adaptable;
30 import org.tmatesoft.hg.util.CancelSupport; 31 import org.tmatesoft.hg.util.CancelSupport;
31 import org.tmatesoft.hg.util.CancelledException; 32 import org.tmatesoft.hg.util.CancelledException;
61 // lifecycleBridge takes care of progress and cancellation, plus 62 // lifecycleBridge takes care of progress and cancellation, plus
62 // gives us explicit way to stop iteration (once HgCallbackTargetException) comes. 63 // gives us explicit way to stop iteration (once HgCallbackTargetException) comes.
63 lifecycleBridge = new LifecycleBridge(ps, cs); 64 lifecycleBridge = new LifecycleBridge(ps, cs);
64 } 65 }
65 66
66 public void next(int revisionNumber, Nodeid nodeid, RawChangeset cset) { 67 public void next(int revisionNumber, Nodeid nodeid, RawChangeset cset) throws HgRuntimeException {
67 if (branches != null && !branches.contains(cset.branch())) { 68 if (branches != null && !branches.contains(cset.branch())) {
68 return; 69 return;
69 } 70 }
70 71
71 HgChangeset changeset = t.handle(revisionNumber, nodeid, cset); 72 HgChangeset changeset = t.handle(revisionNumber, nodeid, cset);