Codota Logo
DhtRepository.getRepositoryKey
Code IndexAdd Codota to your IDE (free)

How to use
getRepositoryKey
method
in
org.eclipse.jgit.storage.dht.DhtRepository

Best Java code snippets using org.eclipse.jgit.storage.dht.DhtRepository.getRepositoryKey (Showing top 14 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
SimpleDateFormat s =
  • Codota IconString pattern;new SimpleDateFormat(pattern)
  • Codota IconString template;Locale locale;new SimpleDateFormat(template, locale)
  • Codota Iconnew SimpleDateFormat()
  • Smart code suggestions by Codota
}
origin: org.eclipse.jgit/org.eclipse.jgit.storage.dht

@Override
public boolean exists() {
  return repository.getRepositoryKey() != null;
}
origin: com.madgag/org.eclipse.jgit.storage.dht

@Override
public boolean exists() {
  return repository.getRepositoryKey() != null;
}
origin: org.eclipse.jgit/org.eclipse.jgit.storage.dht

private Set<Map.Entry<RefKey, RefData>> scan() throws DhtException,
    TimeoutException {
  // TODO(spearce) Do we need to perform READ_REPAIR here?
  RepositoryKey repo = repository.getRepositoryKey();
  return db.ref().getAll(Context.LOCAL, repo).entrySet();
}
origin: com.madgag/org.eclipse.jgit.storage.dht

private Set<Map.Entry<RefKey, RefData>> scan() throws DhtException,
    TimeoutException {
  // TODO(spearce) Do we need to perform READ_REPAIR here?
  RepositoryKey repo = repository.getRepositoryKey();
  return db.ref().getAll(Context.LOCAL, repo).entrySet();
}
origin: org.eclipse.jgit/org.eclipse.jgit.storage.dht

DhtInserter(DhtObjDatabase objdb) {
  this.objdb = objdb;
  this.repo = objdb.getRepository().getRepositoryKey();
  this.db = objdb.getDatabase();
  this.options = objdb.getInserterOptions();
}
origin: com.madgag/org.eclipse.jgit.storage.dht

DhtInserter(DhtObjDatabase objdb) {
  this.objdb = objdb;
  this.repo = objdb.getRepository().getRepositoryKey();
  this.db = objdb.getDatabase();
  this.options = objdb.getInserterOptions();
}
origin: com.madgag/org.eclipse.jgit.storage.dht

private void cachePeeledState(Ref oldLeaf, Ref newLeaf) {
  // TODO(spearce) Use an ExecutorService here
  try {
    RepositoryKey repo = repository.getRepositoryKey();
    RefKey key = RefKey.create(repo, newLeaf.getName());
    RefData oldData = ((DhtRef) oldLeaf).getRefData();
    RefData newData = ((DhtRef) newLeaf).getRefData();
    db.ref().compareAndPut(key, oldData, newData);
  } catch (TimeoutException e) {
    // Ignore a timeout here, we were only trying to update
    // a cached value to save peeling costs in the future.
  } catch (DhtException e) {
    // Ignore a database error, this was only an attempt to
    // fix a value that could be cached to save time later.
  }
}
origin: com.madgag/org.eclipse.jgit.storage.dht

this.repo = objdb.getRepository().getRepositoryKey();
this.db = objdb.getDatabase();
this.options = objdb.getInserterOptions();
origin: org.eclipse.jgit/org.eclipse.jgit.storage.dht

private void cachePeeledState(Ref oldLeaf, Ref newLeaf) {
  // TODO(spearce) Use an ExecutorService here
  try {
    RepositoryKey repo = repository.getRepositoryKey();
    RefKey key = RefKey.create(repo, newLeaf.getName());
    RefData oldData = ((DhtRef) oldLeaf).getRefData();
    RefData newData = ((DhtRef) newLeaf).getRefData();
    db.ref().compareAndPut(key, oldData, newData);
  } catch (TimeoutException e) {
    // Ignore a timeout here, we were only trying to update
    // a cached value to save peeling costs in the future.
  } catch (DhtException e) {
    // Ignore a database error, this was only an attempt to
    // fix a value that could be cached to save time later.
  }
}
origin: org.eclipse.jgit/org.eclipse.jgit.storage.dht

this.repo = objdb.getRepository().getRepositoryKey();
this.db = objdb.getDatabase();
this.options = objdb.getInserterOptions();
origin: org.eclipse.jgit/org.eclipse.jgit.storage.dht

DhtReader(DhtObjDatabase objdb) {
  this.repository = objdb.getRepository();
  this.repo = objdb.getRepository().getRepositoryKey();
  this.db = objdb.getDatabase();
  this.readerOptions = objdb.getReaderOptions();
  this.inserterOptions = objdb.getInserterOptions();
  this.stats = new Statistics();
  this.recentInfo = new RecentInfoCache(getOptions());
  this.recentChunks = new RecentChunks(this);
  this.deltaBaseCache = new DeltaBaseCache(this);
}
origin: com.madgag/org.eclipse.jgit.storage.dht

DhtReader(DhtObjDatabase objdb) {
  this.repository = objdb.getRepository();
  this.repo = objdb.getRepository().getRepositoryKey();
  this.db = objdb.getDatabase();
  this.readerOptions = objdb.getReaderOptions();
  this.inserterOptions = objdb.getInserterOptions();
  this.stats = new Statistics();
  this.recentInfo = new RecentInfoCache(getOptions());
  this.recentChunks = new RecentChunks(this);
  this.deltaBaseCache = new DeltaBaseCache(this);
}
origin: org.eclipse.jgit/org.eclipse.jgit.storage.dht

@Override
public DhtRefUpdate newUpdate(String refName, boolean detach)
    throws IOException {
  boolean detachingSymbolicRef = false;
  DhtRef ref = getOneRef(refName);
  if (ref == null)
    ref = new DhtObjectIdRef(refName, NONE);
  else
    detachingSymbolicRef = detach && ref.isSymbolic();
  if (detachingSymbolicRef) {
    RefData src = ((DhtRef) ref.getLeaf()).getRefData();
    RefData.Builder b = RefData.newBuilder(ref.getRefData());
    b.clearSymref();
    b.setTarget(src.getTarget());
    ref = new DhtObjectIdRef(refName, b.build());
  }
  RepositoryKey repo = repository.getRepositoryKey();
  DhtRefUpdate update = new DhtRefUpdate(this, repo, db, ref);
  if (detachingSymbolicRef)
    update.setDetachingSymbolicRef();
  return update;
}
origin: com.madgag/org.eclipse.jgit.storage.dht

@Override
public DhtRefUpdate newUpdate(String refName, boolean detach)
    throws IOException {
  boolean detachingSymbolicRef = false;
  DhtRef ref = getOneRef(refName);
  if (ref == null)
    ref = new DhtObjectIdRef(refName, NONE);
  else
    detachingSymbolicRef = detach && ref.isSymbolic();
  if (detachingSymbolicRef) {
    RefData src = ((DhtRef) ref.getLeaf()).getRefData();
    RefData.Builder b = RefData.newBuilder(ref.getRefData());
    b.clearSymref();
    b.setTarget(src.getTarget());
    ref = new DhtObjectIdRef(refName, b.build());
  }
  RepositoryKey repo = repository.getRepositoryKey();
  DhtRefUpdate update = new DhtRefUpdate(this, repo, db, ref);
  if (detachingSymbolicRef)
    update.setDetachingSymbolicRef();
  return update;
}
org.eclipse.jgit.storage.dhtDhtRepositorygetRepositoryKey

Popular methods of DhtRepository

  • <init>
    Initialize an in-memory representation of a DHT backed repository.
  • getObjectDatabase
  • getRefDatabase
  • updateRef

Popular in Java

  • Start an intent from android
  • putExtra (Intent)
  • getSupportFragmentManager (FragmentActivity)
    Return the FragmentManager for interacting with fragments associated with this activity.
  • getSharedPreferences (Context)
  • RandomAccessFile (java.io)
    Allows reading from and writing to a file in a random-access manner. This is different from the uni-
  • Hashtable (java.util)
    Hashtable is a synchronized implementation of Map. All optional operations are supported.Neither key
  • Timer (java.util)
    A facility for threads to schedule tasks for future execution in a background thread. Tasks may be s
  • Pattern (java.util.regex)
    A compiled representation of a regular expression. A regular expression, specified as a string, must
  • IOUtils (org.apache.commons.io)
    General IO stream manipulation utilities. This class provides static utility methods for input/outpu
  • Get (org.apache.hadoop.hbase.client)
    Used to perform Get operations on a single row. To get everything for a row, instantiate a Get objec
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now