Introduce common interfaces IRepositoryCommit and IRepositoryObject
commitf38b428b8f5d8a05f8b8bc142315929c9514f561
authorThomas Wolf <thomas.wolf@paranor.ch>
Fri, 14 Jul 2017 11:01:14 +0000 (14 13:01 +0200)
committerThomas Wolf <thomas.wolf@paranor.ch>
Mon, 16 Oct 2017 21:09:30 +0000 (16 23:09 +0200)
treeaf7e7974477a8dbce4f81447c893f68751ccaada
parent103c682e03e143e3d970a9dbe37e6630ac46231f
Introduce common interfaces IRepositoryCommit and IRepositoryObject

Our command/action/handler architecture suffers from lots of
duplication. Basically each view has its own set of commands and
its own set of handlers that often end up doing similar things.
There are a few general commands at org.eclipse.ui.internal.commit,
but even those end up being duplicated in history.

This is all unnecessarily complicated, verbose, error-prone, and
honestly said, unmaintainable.

Let's start to clean this up by introducing common interfaces that
describe the logical objects. These interfaces can then be used in
plugin.xml in activation handlers, and handlers can be written against
selections of such objects. That will enable us to provide a single
set of commands for, say, RevCommits. If needed, these commands can
have different handlers with different activations.

Change-Id: I6a49d74ac1666c4ae00be8755c39e58ec3547504
Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
org.eclipse.egit.core/src/org/eclipse/egit/core/internal/IRepositoryCommit.java [new file with mode: 0644]
org.eclipse.egit.core/src/org/eclipse/egit/core/internal/IRepositoryObject.java [new file with mode: 0644]
org.eclipse.egit.core/src/org/eclipse/egit/core/internal/rebase/RebaseInteractivePlan.java
org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/commit/RepositoryCommit.java
org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/history/SWTCommit.java
org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/reflog/ReflogItem.java