public class SubmoduleAddCommand extends TransportCommand<SubmoduleAddCommand,Repository>
Modifier and Type | Field and Description |
---|---|
private ProgressMonitor |
monitor |
private java.lang.String |
name |
private java.lang.String |
path |
private java.lang.String |
uri |
credentialsProvider, timeout, transportConfigCallback
repo
Constructor and Description |
---|
SubmoduleAddCommand(Repository repo)
Constructor for SubmoduleAddCommand.
|
Modifier and Type | Method and Description |
---|---|
Repository |
call() |
SubmoduleAddCommand |
setName(java.lang.String name)
Set the submodule name
|
SubmoduleAddCommand |
setPath(java.lang.String path)
Set repository-relative path of submodule
|
SubmoduleAddCommand |
setProgressMonitor(ProgressMonitor monitor)
The progress monitor associated with the clone operation.
|
SubmoduleAddCommand |
setURI(java.lang.String uri)
Set URI to clone submodule from
|
protected boolean |
submoduleExists()
Is the configured already a submodule in the index?
|
configure, configure, self, setCredentialsProvider, setTimeout, setTransportConfigCallback
checkCallable, getRepository, setCallable
private java.lang.String name
private java.lang.String path
private java.lang.String uri
private ProgressMonitor monitor
public SubmoduleAddCommand(Repository repo)
repo
- a Repository
object.public SubmoduleAddCommand setName(java.lang.String name)
name
- public SubmoduleAddCommand setPath(java.lang.String path)
path
- (with /
as separator)public SubmoduleAddCommand setURI(java.lang.String uri)
uri
- a String
object.public SubmoduleAddCommand setProgressMonitor(ProgressMonitor monitor)
NullProgressMonitor
monitor
- a ProgressMonitor
object.NullProgressMonitor
protected boolean submoduleExists() throws java.io.IOException
java.io.IOException
public Repository call() throws GitAPIException
Execute the command
Executes the SubmoduleAddCommand
The Repository
instance returned by this command needs to be
closed by the caller to free resources held by the Repository
instance. It is recommended to call this method as soon as you don't need
a reference to this Repository
instance anymore.
call
in interface java.util.concurrent.Callable<Repository>
call
in class GitCommand<Repository>
GitAPIException