From 8e4069704751193b6b915894a05f73cb367b2bd0 Mon Sep 17 00:00:00 2001 From: "Shawn O. Pearce" Date: Tue, 22 Jun 2010 16:45:26 -0700 Subject: [PATCH] Expose repository change event constructors Repository implementations outside of .lib need to be able to create these events and deliver them to listening application code. Expose and document the constructors so that they are visible when we move FileRepository into storage.file.FileRepository. Change-Id: I7fb6e8f4f5fdab683c5ebb5267673aa6d5b560bb Signed-off-by: Shawn O. Pearce --- .../src/org/eclipse/jgit/lib/IndexChangedEvent.java | 8 +++++++- .../src/org/eclipse/jgit/lib/RefsChangedEvent.java | 8 +++++++- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/lib/IndexChangedEvent.java b/org.eclipse.jgit/src/org/eclipse/jgit/lib/IndexChangedEvent.java index 3c41e92c40..c866db531e 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/lib/IndexChangedEvent.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/lib/IndexChangedEvent.java @@ -50,7 +50,13 @@ package org.eclipse.jgit.lib; * Currently only a reference to the repository is passed. */ public class IndexChangedEvent extends RepositoryChangedEvent { - IndexChangedEvent(final Repository repository) { + /** + * Create an event describing index changes in a repository. + * + * @param repository + * the repository whose index (DirCache) recently changed. + */ + public IndexChangedEvent(final Repository repository) { super(repository); } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/lib/RefsChangedEvent.java b/org.eclipse.jgit/src/org/eclipse/jgit/lib/RefsChangedEvent.java index 7a7d99cd23..705c6138e3 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/lib/RefsChangedEvent.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/lib/RefsChangedEvent.java @@ -50,7 +50,13 @@ package org.eclipse.jgit.lib; * Currently only a reference to the repository is passed. */ public class RefsChangedEvent extends RepositoryChangedEvent { - RefsChangedEvent(final Repository repository) { + /** + * Create an event describing reference changes in a repository. + * + * @param repository + * the repository whose references recently changed. + */ + public RefsChangedEvent(final Repository repository) { super(repository); } -- 2.39.5