Package org.eclipse.jgit.transport

Examples of org.eclipse.jgit.transport.IndexPack$DeltaChain


    id2.copyRawTo(pack);
    deflate(pack, delta3);

    digest(pack);
    final byte[] raw = pack.toByteArray();
    IndexPack ip = IndexPack.create(repo, new ByteArrayInputStream(raw));
    ip.setFixThin(true);
    ip.index(NullProgressMonitor.INSTANCE);
    ip.renameAndOpenPack();

    assertTrue("has blob", wc.has(id3));

    ObjectLoader ol = wc.open(id3);
    assertNotNull("created loader", ol);
View Full Code Here


    id2.copyRawTo(pack);
    deflate(pack, delta3);

    digest(pack);
    final byte[] raw = pack.toByteArray();
    IndexPack ip = IndexPack.create(repo, new ByteArrayInputStream(raw));
    ip.setFixThin(true);
    ip.index(NullProgressMonitor.INSTANCE);
    ip.renameAndOpenPack();

    assertTrue("has blob", wc.has(id3));

    ObjectLoader ol = wc.open(id3);
    assertNotNull("created loader", ol);
View Full Code Here

  }

  private void verifyOpenPack(final boolean thin) throws IOException {
    if (thin) {
      final InputStream is = new ByteArrayInputStream(os.toByteArray());
      final IndexPack indexer = new IndexPack(db, is, packBase);
      try {
        indexer.index(new TextProgressMonitor());
        fail("indexer should grumble about missing object");
      } catch (IOException x) {
        // expected
      }
    }
    final InputStream is = new ByteArrayInputStream(os.toByteArray());
    final IndexPack indexer = new IndexPack(db, is, packBase);
    indexer.setKeepEmpty(true);
    indexer.setFixThin(thin);
    indexer.setIndexVersion(2);
    indexer.index(new TextProgressMonitor());
    pack = new PackFile(indexFile, packFile);
  }
View Full Code Here

    id0.copyRawTo(pack);
    deflate(pack, delta3);

    digest(pack);
    final byte[] raw = pack.toByteArray();
    IndexPack ip = IndexPack.create(repo, new ByteArrayInputStream(raw));
    ip.setFixThin(true);
    ip.index(NullProgressMonitor.INSTANCE);
    ip.renameAndOpenPack();

    assertTrue("has blob", wc.has(id3));

    ObjectLoader ol = wc.open(id3);
    assertNotNull("created loader", ol);
View Full Code Here

TOP

Related Classes of org.eclipse.jgit.transport.IndexPack$DeltaChain

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.