Package org.eclipse.jgit.pgm
Class Branch
java.lang.Object
org.eclipse.jgit.pgm.TextBuiltin
org.eclipse.jgit.pgm.Branch
-
Nested Class Summary
Nested classes/interfaces inherited from class org.eclipse.jgit.pgm.TextBuiltin
TextBuiltin.TerminatedByHelpException
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate void
private void
addRefs
(Collection<Ref> refs, String prefix) void
createForce
(List<String> branchAndStartPoint) Forcefully create a list of branchesvoid
Delete branchesprivate void
void
deleteForce
(List<String> names) Forcefully delete branchesprivate void
list()
void
moveRename
(List<String> currentAndNew) Move or rename a branchprivate void
printHead
(ObjectReader reader, String ref, boolean isCurrent, Ref refObj) protected void
run()
Perform the actions of this command.Methods inherited from class org.eclipse.jgit.pgm.TextBuiltin
abbreviateRef, containsHelp, die, die, die, die, execute, getErrorWriter, getOutputWriter, getRepository, getResourceBundle, init, initRaw, parseArguments, printUsage, printUsageAndExit, printUsageAndExit, requiresRepository, resolve, setCommandName
-
Field Details
-
otherBranch
-
createForce
private boolean createForce -
rename
private boolean rename -
remote
private boolean remote -
all
private boolean all -
containsCommitish
-
delete
-
deleteForce
-
verbose
private boolean verbose -
branch
-
printRefs
-
rw
Only set for verbose branch listing at-the-moment -
maxNameLength
private int maxNameLength
-
-
Constructor Details
-
Branch
Branch()
-
-
Method Details
-
delete
Delete branches- Parameters:
names
- aList
of branch names.
-
deleteForce
Forcefully delete branches- Parameters:
names
- aList
of branch names.
-
createForce
Forcefully create a list of branches- Parameters:
branchAndStartPoint
- a branch name and a start point
-
moveRename
Move or rename a branch- Parameters:
currentAndNew
- the current and the new branch name
-
run
protected void run()Perform the actions of this command.This method should only be invoked by
TextBuiltin.execute(String[])
.- Specified by:
run
in classTextBuiltin
-
list
- Throws:
IOException
GitAPIException
-
addRefs
-
addRef
-
printHead
private void printHead(ObjectReader reader, String ref, boolean isCurrent, Ref refObj) throws IOException - Throws:
IOException
-
delete
- Throws:
IOException
-