comparison src/org/tmatesoft/hg/repo/ext/MqManager.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 507602cb4fb3
children
comparison
equal deleted inserted replaced
627:5153eb73b18d 628:6526d8adbc0f
25 import java.util.HashMap; 25 import java.util.HashMap;
26 import java.util.LinkedList; 26 import java.util.LinkedList;
27 import java.util.List; 27 import java.util.List;
28 import java.util.Map; 28 import java.util.Map;
29 29
30 import org.tmatesoft.hg.core.HgIOException;
30 import org.tmatesoft.hg.core.Nodeid; 31 import org.tmatesoft.hg.core.Nodeid;
31 import org.tmatesoft.hg.internal.Internals; 32 import org.tmatesoft.hg.internal.Internals;
32 import org.tmatesoft.hg.internal.LineReader; 33 import org.tmatesoft.hg.internal.LineReader;
33 import org.tmatesoft.hg.repo.HgInvalidControlFileException; 34 import org.tmatesoft.hg.repo.HgInvalidControlFileException;
34 import org.tmatesoft.hg.repo.HgInvalidFileException;
35 import org.tmatesoft.hg.util.LogFacility; 35 import org.tmatesoft.hg.util.LogFacility;
36 import org.tmatesoft.hg.util.Path; 36 import org.tmatesoft.hg.util.Path;
37 37
38 /** 38 /**
39 * Mercurial Queues Support. 39 * Mercurial Queues Support.
134 pr = new PatchRecord(null, name, patchLocation.path(name)); 134 pr = new PatchRecord(null, name, patchLocation.path(name));
135 } 135 }
136 allKnown.add(pr); 136 allKnown.add(pr);
137 } 137 }
138 } 138 }
139 } catch (HgInvalidFileException ex) { 139 } catch (HgIOException ex) {
140 HgInvalidControlFileException th = new HgInvalidControlFileException(ex.getMessage(), ex.getCause(), ex.getFile()); 140 throw new HgInvalidControlFileException(ex, true);
141 th.setStackTrace(ex.getStackTrace());
142 throw th;
143 } 141 }
144 return this; 142 return this;
145 } 143 }
146 144
147 /** 145 /**