public class RepoProject extends Object implements Comparable<RepoProject>
Modifier and Type | Class and Description |
---|---|
static class |
RepoProject.CopyFile
The representation of a copy file configuration.
|
Constructor and Description |
---|
RepoProject(String name,
String path,
String revision,
String remote,
String groups) |
Modifier and Type | Method and Description |
---|---|
void |
addCopyFile(RepoProject.CopyFile copyfile)
Add a copy file configuration.
|
void |
addCopyFiles(Collection<RepoProject.CopyFile> copyfiles)
Add a bunch of copyfile configurations.
|
void |
clearCopyFiles()
Clear all the copyfiles.
|
int |
compareTo(RepoProject that) |
boolean |
equals(Object o) |
List<RepoProject.CopyFile> |
getCopyFiles()
Getter for the copyfile configurations.
|
String |
getName()
Get the name (relative path to the
remote ) of this sub repo. |
String |
getPath()
Get the path (relative path to the super project) of this sub repo.
|
String |
getRemote()
Get the name of the remote definition of the sub repo.
|
String |
getRevision()
Get the revision of the sub repo.
|
String |
getUrl()
Get the url of the sub repo.
|
int |
hashCode() |
boolean |
inGroup(String group)
Test whether this sub repo belongs to a specified group.
|
boolean |
isAncestorOf(RepoProject that)
Check if this sub repo is the ancestor of given sub repo.
|
boolean |
isAncestorOf(String path)
Check if this sub repo is an ancestor of the given path.
|
RepoProject |
setDefaultRevision(String defaultRevision)
Set the default revision for the sub repo.
|
RepoProject |
setUrl(String url)
Set the url of the sub repo.
|
public RepoProject(String name, String path, String revision, String remote, String groups)
name
- the relative path to the remote
path
- the relative path to the super projectrevision
- a SHA-1 or branch name or tag nameremote
- name of the remote definitiongroups
- comma separated group listpublic RepoProject setUrl(String url)
url
- public RepoProject setDefaultRevision(String defaultRevision)
defaultRevision
- public String getName()
remote
) of this sub repo.name
public String getPath()
path
public String getRevision()
revision
if set, or defaultRevision
.public List<RepoProject.CopyFile> getCopyFiles()
copyfiles
public String getUrl()
url
public String getRemote()
remote
public boolean inGroup(String group)
group
- group
is present.public void addCopyFile(RepoProject.CopyFile copyfile)
copyfile
- public void addCopyFiles(Collection<RepoProject.CopyFile> copyfiles)
copyfiles
- public void clearCopyFiles()
public boolean isAncestorOf(RepoProject that)
that
- non nullpublic boolean isAncestorOf(String path)
path
- path to be checked to see if it is within this repositorypublic int compareTo(RepoProject that)
compareTo
in interface Comparable<RepoProject>
Copyright © 2016 Eclipse JGit Project. All rights reserved.