congrats Icon
New! Tabnine Pro 14-day free trial
Start a free trial
Tabnine Logo
DiffCount.call
Code IndexAdd Tabnine to your IDE (free)

How to use
call
method
in
org.locationtech.geogig.plumbing.DiffCount

Best Java code snippets using org.locationtech.geogig.plumbing.DiffCount.call (Showing top 20 results out of 315)

origin: locationtech/geogig

/**
 * @param pathFilter if specified, only changes that match the filter will be returned
 * @return the number differences between STAGE_HEAD and HEAD based on the path filter.
 */
@Override
public DiffObjectCount countStaged(final @Nullable List<String> pathFilters) {
  DiffObjectCount count = context.command(DiffCount.class).setOldVersion(Ref.HEAD)
      .setNewVersion(Ref.STAGE_HEAD).setFilter(pathFilters).call();
  return count;
}
origin: locationtech/geogig

/**
 * @param pathFilter if specified, only changes that match the filter will be counted
 * @return the number differences between the work tree and the index based on the path filter.
 */
@Override
public DiffObjectCount countUnstaged(final @Nullable String pathFilter) {
  DiffObjectCount count = context.command(DiffCount.class).setOldVersion(Ref.STAGE_HEAD)
      .setNewVersion(Ref.WORK_HEAD).addFilter(pathFilter).call();
  return count;
}
origin: org.locationtech.geogig/geogig-core

/**
 * @param pathFilter if specified, only changes that match the filter will be counted
 * @return the number differences between the work tree and the index based on the path filter.
 */
@Override
public DiffObjectCount countUnstaged(final @Nullable String pathFilter) {
  DiffObjectCount count = context.command(DiffCount.class).setOldVersion(Ref.STAGE_HEAD)
      .setNewVersion(Ref.WORK_HEAD).addFilter(pathFilter).call();
  return count;
}
origin: org.locationtech.geogig/geogig-core

/**
 * @param pathFilter if specified, only changes that match the filter will be returned
 * @return the number differences between STAGE_HEAD and HEAD based on the path filter.
 */
@Override
public DiffObjectCount countStaged(final @Nullable List<String> pathFilters) {
  DiffObjectCount count = context.command(DiffCount.class).setOldVersion(Ref.HEAD)
      .setNewVersion(Ref.STAGE_HEAD).setFilter(pathFilters).call();
  return count;
}
origin: locationtech/geogig

private String composeDefaultCommitMessage() {
  final DiffObjectCount diffCount = this.geogigTx.command(DiffCount.class)
      .setOldVersion(Ref.HEAD).setNewVersion(Ref.STAGE_HEAD).call();
origin: locationtech/geogig

.call();
origin: org.locationtech.geogig/geogig-core

.call();
origin: org.locationtech.geogig/geogig-osm

.setNewTree(afterTreeId).call();
origin: locationtech/geogig

private CompletableFuture<LayerDiffSummary> run(final String path, final NodeRef left,
    final NodeRef right) {
  final ObjectId leftTreeId = left == null ? RevTree.EMPTY_TREE_ID : left.getObjectId();
  final ObjectId rightTreeId = right == null ? RevTree.EMPTY_TREE_ID : right.getObjectId();
  final RevTree leftTree = left == null ? RevTree.EMPTY : leftSource.getTree(leftTreeId);
  final RevTree rightTree = right == null ? RevTree.EMPTY : rightSource.getTree(rightTreeId);
  CompletableFuture<DiffObjectCount> diffCount = CompletableFuture.supplyAsync(() -> {
    DiffObjectCount count = command(DiffCount.class).setOldTree(leftTree)
        .setNewTree(rightTree).setLeftSource(leftSource).setRightSource(rightSource)
        .call();
    return count;
  });
  CompletableFuture<org.locationtech.geogig.plumbing.diff.DiffSummary<BoundingBox, BoundingBox>> diffBounds;
  diffBounds = CompletableFuture.supplyAsync(() -> {
    DiffSummary<BoundingBox, BoundingBox> boundsDiff;
    boundsDiff = command(DiffBounds.class).setOldVersion(leftTree).setNewVersion(rightTree)
        .setLeftSource(leftSource).setRightSource(rightSource).call();
    return boundsDiff;
  });
  return diffCount.thenCombine(diffBounds,
      (count, bounds) -> toSummary(path, leftTree, rightTree, count, bounds));
}
origin: org.locationtech.geogig/geogig-cli

    .setNewVersion(newTreeish).call();
long added = count.getFeaturesAdded();
long removed = count.getFeaturesRemoved();
origin: locationtech/geogig

    .setNewVersion(newTreeish).call();
long added = count.getFeaturesAdded();
long removed = count.getFeaturesRemoved();
origin: org.locationtech.geogig/geogig-cli-remoting

    .setNewVersion(newTreeish).call();
long added = count.getFeaturesAdded();
long removed = count.getFeaturesRemoved();
origin: locationtech/geogig

    .setNewVersion(newVersion);
cdiff.setFilter(paths);
DiffObjectCount count = cdiff.call();
Console console = cli.getConsole();
console.println(String.format("Trees: added %,d, changed %,d, removed %,d",
origin: org.locationtech.geogig/geogig-cli

    .setNewVersion(newVersion);
cdiff.setFilter(paths);
DiffObjectCount count = cdiff.call();
Console console = cli.getConsole();
console.println(String.format("Trees: added %,d, changed %,d, removed %,d",
origin: org.locationtech.geogig/geogig-cli-core

    .setNewVersion(newVersion);
cdiff.setFilter(paths);
DiffObjectCount count = cdiff.call();
Console console = cli.getConsole();
console.println(String.format("Trees: added %,d, changed %,d, removed %,d",
origin: org.locationtech.geogig/geogig-cli

String newSpec = commit.getId().toString();
DiffObjectCount diffCount = geogig.command(DiffCount.class).setOldVersion(oldSpec)
    .setNewVersion(newSpec).call();
origin: locationtech/geogig

String newSpec = commit.getId().toString();
DiffObjectCount diffCount = geogig.command(DiffCount.class).setOldVersion(oldSpec)
    .setNewVersion(newSpec).call();
origin: org.locationtech.geogig/geogig-cli-core

String newSpec = commit.getId().toString();
DiffObjectCount diffCount = geogig.command(DiffCount.class).setOldVersion(oldSpec)
    .setNewVersion(newSpec).call();
origin: locationtech/geogig

@Test
public void testReprojectToTargetBucketTree() throws Exception {
  final int leftCount = CanonicalNodeNameOrder.normalizedSizeLimit(0) * 2;
  final int rightCount = CanonicalNodeNameOrder.normalizedSizeLimit(0) * 3;
  WorkingTree workingTree = geogig.getRepository().workingTree();
  final String typeName = "newpoints";
  final DefaultProgressListener listener = new DefaultProgressListener();
  workingTree.insert(new TestFeatureIterator(typeName, leftCount), listener);
  geogig.command(AddOp.class).call();
  workingTree.insert(new TestFeatureIterator(typeName, rightCount), listener);
  {// sanity check
    long diffFeatures = geogig.command(DiffCount.class).setOldVersion("STAGE_HEAD")
        .setNewVersion("WORK_HEAD").call().featureCount();
    assertEquals(rightCount - leftCount, diffFeatures);
  }
  DiffBounds cmd = geogig.command(DiffBounds.class).setOldVersion("STAGE_HEAD")
      .setNewVersion("WORK_HEAD");
  final CoordinateReferenceSystem nativeCrs = CRS.decode("EPSG:3857");
  final DiffSummary<BoundingBox, BoundingBox> diffInNativeCrs = cmd.setCRS(nativeCrs).call();
  CoordinateReferenceSystem targetcrs = CRS.decode("EPSG:4326", true);
  cmd.setCRS(targetcrs);
  DiffSummary<BoundingBox, BoundingBox> reprojected = cmd.call();
  assertEquals(targetcrs, reprojected.getLeft().getCoordinateReferenceSystem());
  assertEquals(targetcrs, reprojected.getRight().getCoordinateReferenceSystem());
  assertEquals(targetcrs, reprojected.getMergedResult().get().getCoordinateReferenceSystem());
  ReferencedEnvelope e = new ReferencedEnvelope(diffInNativeCrs.getRight());
  ReferencedEnvelope expected = e.transform(targetcrs, true);
  BoundingBox actual = reprojected.getRight();
  assertEquals(expected, actual);
}
origin: org.locationtech.geogig/geogig-core

@Test
public void testReprojectToTargetBucketTree() throws Exception {
  final int leftCount = CanonicalNodeNameOrder.normalizedSizeLimit(0) * 2;
  final int rightCount = CanonicalNodeNameOrder.normalizedSizeLimit(0) * 3;
  WorkingTree workingTree = geogig.getRepository().workingTree();
  final String typeName = "newpoints";
  final DefaultProgressListener listener = new DefaultProgressListener();
  workingTree.insert(new TestFeatureIterator(typeName, leftCount), listener);
  geogig.command(AddOp.class).call();
  workingTree.insert(new TestFeatureIterator(typeName, rightCount), listener);
  {// sanity check
    long diffFeatures = geogig.command(DiffCount.class).setOldVersion("STAGE_HEAD")
        .setNewVersion("WORK_HEAD").call().featureCount();
    assertEquals(rightCount - leftCount, diffFeatures);
  }
  DiffBounds cmd = geogig.command(DiffBounds.class).setOldVersion("STAGE_HEAD")
      .setNewVersion("WORK_HEAD");
  final CoordinateReferenceSystem nativeCrs = CRS.decode("EPSG:3857");
  final DiffSummary<BoundingBox, BoundingBox> diffInNativeCrs = cmd.setCRS(nativeCrs).call();
  CoordinateReferenceSystem targetcrs = CRS.decode("EPSG:4326", true);
  cmd.setCRS(targetcrs);
  DiffSummary<BoundingBox, BoundingBox> reprojected = cmd.call();
  assertEquals(targetcrs, reprojected.getLeft().getCoordinateReferenceSystem());
  assertEquals(targetcrs, reprojected.getRight().getCoordinateReferenceSystem());
  assertEquals(targetcrs, reprojected.getMergedResult().get().getCoordinateReferenceSystem());
  ReferencedEnvelope e = new ReferencedEnvelope(diffInNativeCrs.getRight());
  ReferencedEnvelope expected = e.transform(targetcrs, true);
  BoundingBox actual = reprojected.getRight();
  assertEquals(expected, actual);
}
org.locationtech.geogig.plumbingDiffCountcall

Popular methods of DiffCount

  • setNewVersion
  • setOldVersion
  • setNewTree
  • setFilter
  • setOldTree
  • setProgressListener
  • addFilter
  • command
  • getTree
  • objectDatabase
  • setLeftSource
  • setRightSource
  • setLeftSource,
  • setRightSource

Popular in Java

  • Making http post requests using okhttp
  • runOnUiThread (Activity)
  • startActivity (Activity)
  • addToBackStack (FragmentTransaction)
  • PrintStream (java.io)
    Fake signature of an existing Java class.
  • Executor (java.util.concurrent)
    An object that executes submitted Runnable tasks. This interface provides a way of decoupling task s
  • Executors (java.util.concurrent)
    Factory and utility methods for Executor, ExecutorService, ScheduledExecutorService, ThreadFactory,
  • ZipFile (java.util.zip)
    This class provides random read access to a zip file. You pay more to read the zip file's central di
  • Project (org.apache.tools.ant)
    Central representation of an Ant project. This class defines an Ant project with all of its targets,
  • Reflections (org.reflections)
    Reflections one-stop-shop objectReflections scans your classpath, indexes the metadata, allows you t
  • PhpStorm for WordPress
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now