tikhomirov@93: /*
tikhomirov@93: * Copyright (c) 2010-2011 TMate Software Ltd
tikhomirov@93: *
tikhomirov@93: * This program is free software; you can redistribute it and/or modify
tikhomirov@93: * it under the terms of the GNU General Public License as published by
tikhomirov@93: * the Free Software Foundation; version 2 of the License.
tikhomirov@93: *
tikhomirov@93: * This program is distributed in the hope that it will be useful,
tikhomirov@93: * but WITHOUT ANY WARRANTY; without even the implied warranty of
tikhomirov@93: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
tikhomirov@93: * GNU General Public License for more details.
tikhomirov@93: *
tikhomirov@93: * For information on how to redistribute this software under
tikhomirov@93: * the terms of a license other than GNU General Public License
tikhomirov@102: * contact TMate Software at support@hg4j.com
tikhomirov@93: */
tikhomirov@93: package org.tmatesoft.hg.repo;
tikhomirov@93:
tikhomirov@133: import org.tmatesoft.hg.util.Path;
tikhomirov@93:
tikhomirov@93: /**
tikhomirov@93: * Callback to get file status information
tikhomirov@93: *
tikhomirov@93: * @author Artem Tikhomirov
tikhomirov@93: * @author TMate Software Ltd.
tikhomirov@93: */
tikhomirov@93: public interface HgStatusInspector {
tikhomirov@93: void modified(Path fname);
tikhomirov@93: void added(Path fname);
tikhomirov@316: /**
tikhomirov@316: * This method is invoked for files that we added as a result of a copy/move operation, and it's the sole
tikhomirov@316: * method invoked in this case, that is {@link #added(Path)} method is NOT invoked along with it.
tikhomirov@316: * If copied files of no interest, it is implementation responsibility to delegate to this.added(fnameAdded)
tikhomirov@316: */
tikhomirov@316: void copied(Path fnameOrigin, Path fnameAdded);
tikhomirov@93: void removed(Path fname);
tikhomirov@93: void clean(Path fname);
tikhomirov@360: /**
tikhomirov@360: * Reports file tracked by Mercurial, but not available in file system any more, aka deleted.
tikhomirov@360: */
tikhomirov@360: void missing(Path fname); //
tikhomirov@93: void unknown(Path fname); // not tracked
tikhomirov@93: void ignored(Path fname);
tikhomirov@360: /**
tikhomirov@360: * Reports a single file error during status collecting operation. It's up to client to treat the whole operation as successful or not.
tikhomirov@360: * The error reported is otherwise not critical for the status operation.
tikhomirov@360: *
tikhomirov@360: * @param fname origin of the error
tikhomirov@360: * @param ex describes an error occurred while accessing the file, never null
tikhomirov@360: */
tikhomirov@360: void invalid(Path fname, Exception ex);
tikhomirov@93: }