Top Description Fields Constructors Methods
org.eclipse.jgit.internal.storage.dfs

public Class DfsReftableBatchRefUpdate

extends ReftableBatchRefUpdate
Class Inheritance
Imports
org.eclipse.jgit.internal.storage.dfs.DfsObjDatabase.PackSource, org.eclipse.jgit.internal.storage.io.BlockSource, org.eclipse.jgit.internal.storage.pack.PackExt, org.eclipse.jgit.internal.storage.reftable.ReftableBatchRefUpdate, .ReftableCompactor, .ReftableConfig, .ReftableReader, .ReftableWriter, org.eclipse.jgit.lib.Ref, org.eclipse.jgit.transport.ReceiveCommand, java.io.ByteArrayOutputStream, .IOException, .OutputStream, java.util.ArrayList, .Collections, .List, .Set

org.eclipse.jgit.lib.BatchRefUpdate for org.eclipse.jgit.internal.storage.dfs.DfsReftableDatabase.

Field Summary

Modifier and TypeField and Description
private static final int
private final DfsObjDatabase
private final DfsReftableDatabase

Constructor Summary

AccessConstructor and Description
protected
DfsReftableBatchRefUpdate(DfsReftableDatabase
database the update will modify.
refdb
,
DfsObjDatabase
object database to store the reftable.
odb
)

Initialize batch update.

Method Summary

Modifier and TypeMethod and Description
protected void
applyUpdates(List<Ref>
the new refs to create
newRefs
,
List<ReceiveCommand>
the pending receive commands to be executed
pending
)

Implements abstract org.eclipse.jgit.internal.storage.reftable.ReftableBatchRefUpdate.applyUpdates.

Implements the storage-specific part of the update.

private boolean
private ReftableWriter.Stats
compactTopOfStack(OutputStream out, ReftableConfig cfg, byte[] newTable)

private boolean
private Set<DfsPackDescription>
Inherited from org.eclipse.jgit.internal.storage.reftable.ReftableBatchRefUpdate:
executewrite

Field Detail

AVG_BYTESback to summary
private static final int AVG_BYTES
odbback to summary
private final DfsObjDatabase odb
refdbback to summary
private final DfsReftableDatabase refdb

Hides org.eclipse.jgit.lib.BatchRefUpdate.refdb.

Constructor Detail

DfsReftableBatchRefUpdateback to summary
protected DfsReftableBatchRefUpdate(DfsReftableDatabase refdb, DfsObjDatabase odb)

Initialize batch update.

Parameters
refdb:DfsReftableDatabase

database the update will modify.

odb:DfsObjDatabase

object database to store the reftable.

Method Detail

applyUpdatesback to summary
protected void applyUpdates(List<Ref> newRefs, List<ReceiveCommand> pending) throws IOException

Implements abstract org.eclipse.jgit.internal.storage.reftable.ReftableBatchRefUpdate.applyUpdates.

Doc from org.eclipse.jgit.internal.storage.reftable.ReftableBatchRefUpdate.applyUpdates.

Implements the storage-specific part of the update.

Parameters
newRefs:List<Ref>

the new refs to create

pending:List<ReceiveCommand>

the pending receive commands to be executed

Annotations
@Override
Exceptions
IOException:
if any of the writes fail.
canCompactTopOfStackback to summary
private boolean canCompactTopOfStack(ReftableConfig cfg) throws IOException
compactTopOfStackback to summary
private ReftableWriter.Stats compactTopOfStack(OutputStream out, ReftableConfig cfg, byte[] newTable) throws IOException
packOnlyContainsReftableback to summary
private boolean packOnlyContainsReftable(DfsPackDescription desc)
toPruneTopOfStackback to summary
private Set<DfsPackDescription> toPruneTopOfStack() throws IOException