Class DfsBlock
java.lang.Object
org.eclipse.jgit.internal.storage.dfs.DfsBlock
A cached slice of a
BlockBasedFile
.-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final byte[]
(package private) final long
(package private) final long
(package private) final DfsStreamKey
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) void
(package private) boolean
contains
(DfsStreamKey want, long pos) (package private) int
copy
(int p, byte[] b, int o, int n) (package private) int
copy
(long pos, byte[] dstbuf, int dstoff, int cnt) (package private) void
(package private) int
(package private) int
size()
(package private) void
write
(PackOutputStream out, long pos, int cnt) (package private) ByteBuffer
zeroCopyByteBuffer
(int n)
-
Field Details
-
stream
-
start
final long start -
end
final long end -
block
private final byte[] block
-
-
Constructor Details
-
DfsBlock
DfsBlock(DfsStreamKey p, long pos, byte[] buf)
-
-
Method Details
-
size
int size() -
zeroCopyByteBuffer
-
contains
-
copy
int copy(long pos, byte[] dstbuf, int dstoff, int cnt) -
copy
int copy(int p, byte[] b, int o, int n) -
setInput
- Throws:
DataFormatException
-
crc32
-
write
- Throws:
IOException
-
check
- Throws:
DataFormatException
-