|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.jgit.api.GitCommand<RebaseResult>
org.eclipse.jgit.api.RebaseCommand
public class RebaseCommand
A class used to execute a Rebase
command. It has setters for all
supported options and arguments of this command and a call()
method
to finally execute the command. Each instance of this class should only be
used for one invocation of the command (means: one call to call()
)
Nested Class Summary | |
---|---|
static class |
RebaseCommand.Action
Describes rebase actions |
static interface |
RebaseCommand.InteractiveHandler
Allows configure rebase interactive process and modify commit message |
static class |
RebaseCommand.Operation
The available operations |
static class |
RebaseCommand.Step
Describes single rebase step |
Field Summary | |
---|---|
static String |
REBASE_MERGE
The name of the "rebase-merge" folder |
static String |
STOPPED_SHA
The name of the "stopped-sha" file |
Fields inherited from class org.eclipse.jgit.api.GitCommand |
---|
repo |
Constructor Summary | |
---|---|
protected |
RebaseCommand(Repository repo)
|
Method Summary | |
---|---|
RebaseResult |
call()
Executes the Rebase command with all the options and parameters
collected by the setter methods of this class. |
RebaseCommand |
runInteractively(RebaseCommand.InteractiveHandler handler)
Enables interactive rebase |
RebaseCommand |
setOperation(RebaseCommand.Operation operation)
|
RebaseCommand |
setProgressMonitor(ProgressMonitor monitor)
|
RebaseCommand |
setUpstream(AnyObjectId upstream)
|
RebaseCommand |
setUpstream(RevCommit upstream)
|
RebaseCommand |
setUpstream(String upstream)
|
RebaseCommand |
setUpstreamName(String upstreamName)
Optionally override the name of the upstream. |
RevCommit |
tryFastForward(RevCommit newCommit)
checks if we can fast-forward and returns the new head if it is possible |
Methods inherited from class org.eclipse.jgit.api.GitCommand |
---|
checkCallable, getRepository, setCallable |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String REBASE_MERGE
public static final String STOPPED_SHA
Constructor Detail |
---|
protected RebaseCommand(Repository repo)
repo
- Method Detail |
---|
public RebaseResult call() throws GitAPIException, NoHeadException, RefNotFoundException, WrongRepositoryStateException
Rebase
command with all the options and parameters
collected by the setter methods of this class. Each instance of this
class should only be used for one invocation of the command. Don't call
this method twice on an instance.
call
in interface Callable<RebaseResult>
call
in class GitCommand<RebaseResult>
GitAPIException
WrongRepositoryStateException
NoHeadException
RefNotFoundException
public RevCommit tryFastForward(RevCommit newCommit) throws IOException, GitAPIException
newCommit
-
IOException
GitAPIException
public RebaseCommand setUpstream(RevCommit upstream)
upstream
- the upstream commit
this
public RebaseCommand setUpstream(AnyObjectId upstream)
upstream
- id of the upstream commit
this
public RebaseCommand setUpstream(String upstream) throws RefNotFoundException
upstream
- the upstream branch
this
RefNotFoundException
public RebaseCommand setUpstreamName(String upstreamName)
setUpstream(org.eclipse.jgit.revwalk.RevCommit)
call.
upstreamName
- the name which will be used to refer to upstream in conflicts
this
public RebaseCommand setOperation(RebaseCommand.Operation operation)
operation
- the operation to perform
this
public RebaseCommand setProgressMonitor(ProgressMonitor monitor)
monitor
- a progress monitor
public RebaseCommand runInteractively(RebaseCommand.InteractiveHandler handler)
handler
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |