comparison src/org/tmatesoft/hg/core/HgChangesetHandler.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 5dcb4581c8ef
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 *
15 * contact TMate Software at support@hg4j.com 15 * contact TMate Software at support@hg4j.com
16 */ 16 */
17 package org.tmatesoft.hg.core; 17 package org.tmatesoft.hg.core;
18 18
19 import org.tmatesoft.hg.internal.Callback; 19 import org.tmatesoft.hg.internal.Callback;
20 import org.tmatesoft.hg.repo.HgRuntimeException;
20 import org.tmatesoft.hg.util.Adaptable; 21 import org.tmatesoft.hg.util.Adaptable;
21 import org.tmatesoft.hg.util.Path; 22 import org.tmatesoft.hg.util.Path;
22 23
23 /** 24 /**
24 * Callback to process {@link HgChangeset changesets}. 25 * Callback to process {@link HgChangeset changesets}.
30 public interface HgChangesetHandler { 31 public interface HgChangesetHandler {
31 32
32 /** 33 /**
33 * @param changeset descriptor of a change, not necessarily a distinct instance each time, {@link HgChangeset#clone() clone()} if need a copy. 34 * @param changeset descriptor of a change, not necessarily a distinct instance each time, {@link HgChangeset#clone() clone()} if need a copy.
34 * @throws HgCallbackTargetException wrapper for any exception user code may produce 35 * @throws HgCallbackTargetException wrapper for any exception user code may produce
36 * @throws HgRuntimeException propagates library issues. <em>Runtime exception</em>
35 */ 37 */
36 void cset(HgChangeset changeset) throws HgCallbackTargetException; 38 void cset(HgChangeset changeset) throws HgCallbackTargetException, HgRuntimeException;
37 39
38 40
39 /** 41 /**
40 * When {@link HgLogCommand} is executed against file, handler passed to {@link HgLogCommand#execute(HgChangesetHandler)} may optionally 42 * When {@link HgLogCommand} is executed against file, handler passed to {@link HgLogCommand#execute(HgChangesetHandler)} may optionally
41 * implement this interface (or make it available through {@link Adaptable#getAdapter(Class)} to get information about file renames. 43 * implement this interface (or make it available through {@link Adaptable#getAdapter(Class)} to get information about file renames.