本文整理了Java中org.locationtech.geogig.repository.Repository.graphDatabase
方法的一些代码示例,展示了Repository.graphDatabase
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Repository.graphDatabase
方法的具体详情如下:
包路径:org.locationtech.geogig.repository.Repository
类名称:Repository
方法名:graphDatabase
暂无
代码示例来源:origin: org.locationtech.geogig/geogig-remoting
/**
* Gets the depth of the given commit.
*
* @param commitId the commit id
* @return the depth, or 0 if the commit was not found
*/
@Override
public int getDepth(ObjectId commitId) {
return localRepository.graphDatabase().getDepth(commitId);
}
代码示例来源:origin: locationtech/geogig
/**
* Gets the depth of the given commit.
*
* @param commitId the commit id
* @return the depth, or 0 if the commit was not found
*/
@Override
public int getDepth(ObjectId commitId) {
return localRepository.graphDatabase().getDepth(commitId);
}
代码示例来源:origin: locationtech/geogig
@Override
protected boolean existsInDestination(ObjectId commitId) {
return destination.graphDatabase().exists(commitId);
}
代码示例来源:origin: org.locationtech.geogig/geogig-remoting
@Override
protected ImmutableList<ObjectId> getParentsInternal(ObjectId commitId) {
return source.graphDatabase().getParents(commitId);
}
代码示例来源:origin: locationtech/geogig
/**
* Gets the parents of the specified commit from the repository.
*
* @param commit the id of the commit whose parents to retrieve
* @return a list of parent ids for the commit
*/
@Override
public ImmutableList<ObjectId> getParents(ObjectId commitId) {
return localRepository.graphDatabase().getParents(commitId);
}
代码示例来源:origin: locationtech/geogig
@Override
protected ImmutableList<ObjectId> getParentsInternal(ObjectId commitId) {
return source.graphDatabase().getParents(commitId);
}
代码示例来源:origin: org.locationtech.geogig/geogig-web-api
public Integer getDepth(RepositoryProvider provider, String repoName, ObjectId commitId) {
Optional<Integer> depth = Optional.absent();
Repository repository = getRepository(provider, repoName);
if (repository != null) {
if (commitId != null) {
depth = Optional.of(repository.graphDatabase().getDepth(commitId));
} else {
depth = repository.getDepth();
}
}
return depth.orNull();
}
代码示例来源:origin: locationtech/geogig
@Override
protected Evaluation evaluate(CommitNode commitNode) {
if (destination.graphDatabase().exists(commitNode.getObjectId())) {
return Evaluation.EXCLUDE_AND_PRUNE;
}
return Evaluation.INCLUDE_AND_CONTINUE;
}
代码示例来源:origin: locationtech/geogig
@Override
protected boolean existsInDestination(ObjectId commitId) {
// If the commit has not been mapped, it hasn't been pushed to the remote yet
return !source.graphDatabase().getMapping(commitId).equals(ObjectId.NULL);
}
代码示例来源:origin: org.locationtech.geogig/geogig-remoting
@Override
protected boolean existsInDestination(ObjectId commitId) {
// If the commit has not been mapped, it hasn't been pushed to the remote yet
return !source.graphDatabase().getMapping(commitId).equals(ObjectId.NULL);
}
代码示例来源:origin: org.locationtech.geogig/geogig-remoting
@Override
protected Evaluation evaluate(CommitNode commitNode) {
if (destination.graphDatabase().exists(commitNode.getObjectId())) {
return Evaluation.EXCLUDE_AND_PRUNE;
}
return Evaluation.INCLUDE_AND_CONTINUE;
}
代码示例来源:origin: org.locationtech.geogig/geogig-remoting
@Override
protected Evaluation evaluate(CommitNode commitNode) {
if (!source.graphDatabase().getMapping(commitNode.getObjectId())
.equals(ObjectId.NULL)) {
return Evaluation.EXCLUDE_AND_PRUNE;
}
return Evaluation.INCLUDE_AND_CONTINUE;
}
代码示例来源:origin: locationtech/geogig
@Override
protected Evaluation evaluate(CommitNode commitNode) {
if (!source.graphDatabase().getMapping(commitNode.getObjectId())
.equals(ObjectId.NULL)) {
return Evaluation.EXCLUDE_AND_PRUNE;
}
return Evaluation.INCLUDE_AND_CONTINUE;
}
代码示例来源:origin: org.locationtech.geogig/geogig-web-api
public Parents getParents(RepositoryProvider provider, String repoName, ObjectId oid) {
Repository repository = getRepository(provider, repoName);
Parents parents = new Parents();
if (repository != null && oid != null) {
parents.setParents(repository.graphDatabase().getParents(oid));
}
return parents;
}
}
代码示例来源:origin: org.locationtech.geogig/geogig-web-api-functional-tests
@Given("^The graph database on the \"([^\"]*)\" repo has been truncated$")
public void Truncate_graph_database(String repoName) throws Throwable {
Repository repo = context.getRepo(repoName);
repo.graphDatabase().truncate();
// add the repo to the set so it can be closed
openedRepos.add(repoName);
}
代码示例来源:origin: locationtech/geogig
@Given("^the repository has a truncated graph database$")
public void the_repository_has_a_truncated_graph_database() throws Throwable {
Repository repository = localRepo.geogigCLI.getGeogig().getRepository();
repository.graphDatabase().truncate();
}
代码示例来源:origin: org.locationtech.geogig/geogig-cli-core
@Given("^the repository has a truncated graph database$")
public void the_repository_has_a_truncated_graph_database() throws Throwable {
Repository repository = localRepo.geogigCLI.getGeogig().getRepository();
repository.graphDatabase().truncate();
}
代码示例来源:origin: org.locationtech.geogig/geogig-cli
@Given("^the repository has a truncated graph database$")
public void the_repository_has_a_truncated_graph_database() throws Throwable {
Repository repository = localRepo.geogigCLI.getGeogig().getRepository();
repository.graphDatabase().truncate();
}
代码示例来源:origin: locationtech/geogig
@Override
protected void setUpInternal() throws Exception {
// These values should be used during a commit to set author/committer
// TODO: author/committer roles need to be defined better, but for
// now they are the same thing.
repo.command(ConfigOp.class).setAction(ConfigAction.CONFIG_SET).setName("user.name")
.setValue("groldan").call();
repo.command(ConfigOp.class).setAction(ConfigAction.CONFIG_SET).setName("user.email")
.setValue("groldan@boundlessgeo.com").call();
database = geogig.getRepository().graphDatabase();
}
代码示例来源:origin: org.locationtech.geogig/geogig-core
@Override
protected void setUpInternal() throws Exception {
// These values should be used during a commit to set author/committer
// TODO: author/committer roles need to be defined better, but for
// now they are the same thing.
repo.command(ConfigOp.class).setAction(ConfigAction.CONFIG_SET).setName("user.name")
.setValue("groldan").call();
repo.command(ConfigOp.class).setAction(ConfigAction.CONFIG_SET).setName("user.email")
.setValue("groldan@boundlessgeo.com").call();
database = geogig.getRepository().graphDatabase();
}
内容来源于网络,如有侵权,请联系作者删除!