comparison src/org/tmatesoft/hg/core/HgFileRenameHandlerMixin.java @ 514:5dcb4581c8ef

Report renames when following file history tree with HgFileRenameHandlerMixin
author Artem Tikhomirov <tikhomirov.artem@gmail.com>
date Mon, 17 Dec 2012 19:06:07 +0100
parents
children 6526d8adbc0f
comparison
equal deleted inserted replaced
513:a41d955dc360 514:5dcb4581c8ef
1 /*
2 * Copyright (c) 2012 TMate Software Ltd
3 *
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
6 * the Free Software Foundation; version 2 of the License.
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * For information on how to redistribute this software under
14 * the terms of a license other than GNU General Public License
15 * contact TMate Software at support@hg4j.com
16 */
17 package org.tmatesoft.hg.core;
18
19 import org.tmatesoft.hg.util.Adaptable;
20
21 /**
22 * Addition to file history handlers (like {@link HgChangesetHandler} and {@link HgChangesetTreeHandler})
23 * to receive notification about rename in the history of the file being walked.
24 *
25 * This mix-in shall be available from the host handler through the {@link Adaptable} mechanism, see
26 * {@link Adaptable.Factory#getAdapter(Object, Class, Object)}. Hence, implementing
27 * this interface in addition to host's would be the easiest way to achieve that.
28 *
29 * @author Artem Tikhomirov
30 * @author TMate Software Ltd.
31 */
32 public interface HgFileRenameHandlerMixin {
33 // XXX perhaps, should distinguish copy from rename? And what about merged revisions and following them?
34
35 /**
36 * @throws HgCallbackTargetException wrapper object for any exception user code may produce
37 */
38 void copy(HgFileRevision from, HgFileRevision to) throws HgCallbackTargetException;
39 }