Browse Source

Add isRebasing to RepositoryState

See EGit change Ic69f5c952a49f023c0949f04b3e976be1b267fbe where this
could be used.

Change-Id: I9ec8568fa1100d2e9c8d4ca0e347bf77ec6d8734
stable-3.0
Robin Stocker 12 years ago
parent
commit
9105e1c9af
  1. 48
      org.eclipse.jgit/src/org/eclipse/jgit/lib/RepositoryState.java

48
org.eclipse.jgit/src/org/eclipse/jgit/lib/RepositoryState.java

@ -69,6 +69,9 @@ public enum RepositoryState {
@Override
public boolean canAmend() { return false; }
@Override
public boolean isRebasing() { return false; }
@Override
public String getDescription() { return "Bare"; }
},
@ -89,6 +92,9 @@ public enum RepositoryState {
@Override
public boolean canAmend() { return true; }
@Override
public boolean isRebasing() { return false; }
@Override
public String getDescription() { return JGitText.get().repositoryState_normal; }
},
@ -108,6 +114,9 @@ public enum RepositoryState {
@Override
public boolean canAmend() { return false; }
@Override
public boolean isRebasing() { return false; }
@Override
public String getDescription() { return JGitText.get().repositoryState_conflicts; }
},
@ -129,6 +138,9 @@ public enum RepositoryState {
@Override
public boolean canAmend() { return false; }
@Override
public boolean isRebasing() { return false; }
@Override
public String getDescription() { return JGitText.get().repositoryState_merged; }
},
@ -148,6 +160,9 @@ public enum RepositoryState {
@Override
public boolean canAmend() { return false; }
@Override
public boolean isRebasing() { return false; }
@Override
public String getDescription() { return JGitText.get().repositoryState_conflicts; }
},
@ -169,6 +184,9 @@ public enum RepositoryState {
@Override
public boolean canAmend() { return false; }
@Override
public boolean isRebasing() { return false; }
@Override
public String getDescription() { return JGitText.get().repositoryState_merged; }
},
@ -188,6 +206,9 @@ public enum RepositoryState {
@Override
public boolean canAmend() { return false; }
@Override
public boolean isRebasing() { return false; }
@Override
public String getDescription() { return JGitText.get().repositoryState_conflicts; }
},
@ -209,6 +230,9 @@ public enum RepositoryState {
@Override
public boolean canAmend() { return false; }
@Override
public boolean isRebasing() { return false; }
@Override
public String getDescription() { return JGitText.get().repositoryState_merged; }
},
@ -229,6 +253,9 @@ public enum RepositoryState {
@Override
public boolean canAmend() { return true; }
@Override
public boolean isRebasing() { return true; }
@Override
public String getDescription() { return JGitText.get().repositoryState_rebaseOrApplyMailbox; }
},
@ -249,6 +276,9 @@ public enum RepositoryState {
@Override
public boolean canAmend() { return true; }
@Override
public boolean isRebasing() { return true; }
@Override
public String getDescription() { return JGitText.get().repositoryState_rebase; }
},
@ -269,6 +299,9 @@ public enum RepositoryState {
@Override
public boolean canAmend() { return true; }
@Override
public boolean isRebasing() { return false; }
@Override
public String getDescription() { return JGitText.get().repositoryState_applyMailbox; }
},
@ -289,6 +322,9 @@ public enum RepositoryState {
@Override
public boolean canAmend() { return true; }
@Override
public boolean isRebasing() { return true; }
@Override
public String getDescription() { return JGitText.get().repositoryState_rebaseWithMerge; }
},
@ -309,6 +345,9 @@ public enum RepositoryState {
@Override
public boolean canAmend() { return true; }
@Override
public boolean isRebasing() { return true; }
@Override
public String getDescription() { return JGitText.get().repositoryState_rebaseInteractive; }
},
@ -332,6 +371,9 @@ public enum RepositoryState {
@Override
public boolean canAmend() { return false; }
@Override
public boolean isRebasing() { return false; }
@Override
public String getDescription() { return JGitText.get().repositoryState_bisecting; }
};
@ -356,6 +398,12 @@ public enum RepositoryState {
*/
public abstract boolean canAmend();
/**
* @return true if the repository is currently in a rebase
* @since 2.4
*/
public abstract boolean isRebasing();
/**
* @return a human readable description of the state.
*/

Loading…
Cancel
Save