Top Fields Constructors Methods
org.eclipse.jgit.internal.storage.file

pack-priv Class PackFileSnapshot

extends FileSnapshot
Class Inheritance
Imports
java.io.File, .IOException, .RandomAccessFile, org.eclipse.jgit.lib.AnyObjectId, .ObjectId, org.eclipse.jgit.util.Equality

Field Summary

Modifier and TypeField and Description
private AnyObjectId
private static final ObjectId
private boolean
Inherited from org.eclipse.jgit.internal.storage.file.FileSnapshot:
DIRTYMISSING_FILEUNKNOWN_SIZE

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
pack-priv boolean
public boolean
isModified(File
the path the snapshot describes.
packFile
)

Overrides org.eclipse.jgit.internal.storage.file.FileSnapshot.isModified.

Check if the path may have been modified since the snapshot was saved.

private AnyObjectId
readChecksum(File packFile)

public static PackFileSnapshot

Returns:

the snapshot.
save
(File
the path to later remember. The path's current status information is saved.
path
)

Hides org.eclipse.jgit.internal.storage.file.FileSnapshot.save.

Record a snapshot for a specific packfile path.

pack-priv void
public String
toString()

Overrides org.eclipse.jgit.internal.storage.file.FileSnapshot.toString.

Returns a string representation of the object.

pack-priv boolean
Inherited from org.eclipse.jgit.internal.storage.file.FileSnapshot:
equalsequalshashCodelastDeltalastModifiedInstantlastRacyThresholdsavesaveNoConfigsetCleansizewaitUntilNotRacywasFileKeyChangedwasLastModifiedChangedwasLastModifiedRacilyCleanwasSizeChanged

Field Detail

checksumback to summary
private AnyObjectId checksum
MISSING_CHECKSUMback to summary
private static final ObjectId MISSING_CHECKSUM
wasChecksumChangedback to summary
private boolean wasChecksumChanged

Constructor Detail

PackFileSnapshotback to summary
pack-priv PackFileSnapshot(File packFile)

Method Detail

isChecksumChangedback to summary
pack-priv boolean isChecksumChanged(File packFile)
isModifiedback to summary
public boolean isModified(File packFile)

Overrides org.eclipse.jgit.internal.storage.file.FileSnapshot.isModified.

Doc from org.eclipse.jgit.internal.storage.file.FileSnapshot.isModified.

Check if the path may have been modified since the snapshot was saved.

Parameters
packFile:File

the path the snapshot describes.

Returns:boolean

true if the path needs to be read again.

Annotations
@Override
readChecksumback to summary
private AnyObjectId readChecksum(File packFile)
saveback to summary
public static PackFileSnapshot save(File path)

Hides org.eclipse.jgit.internal.storage.file.FileSnapshot.save.

Record a snapshot for a specific packfile path.

This method should be invoked before the packfile is accessed.

Parameters
path:File

the path to later remember. The path's current status information is saved.

Returns:PackFileSnapshot

the snapshot.

setChecksumback to summary
pack-priv void setChecksum(AnyObjectId checksum)
toStringback to summary
public String toString()

Overrides org.eclipse.jgit.internal.storage.file.FileSnapshot.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object. Satisfying this method's contract implies a non-null result must be returned.

Returns:String

a string representation of the object

Annotations
@SuppressWarnings:nls
@Override
wasChecksumChangedback to summary
pack-priv boolean wasChecksumChanged()