ObjectLoader implementation that reads a media file from the LFS
storage.
| Modifier and Type | Field and Description |
|---|---|
| private BasicFileAttributes | |
| private byte[] | |
| private Path |
| Access | Constructor and Description |
|---|---|
| public | LfsBlobLoader(Path
path to the file mediaFile)Create a loader for the LFS media file at the given path. |
| Modifier and Type | Method and Description |
|---|---|
| public byte[] | getCachedBytes()
Implements abstract org. Obtain a reference to the (possibly cached) bytes of this object. |
| public long | |
| public int | |
| public ObjectStream | openStream()
Implements abstract org. Obtain an input stream to read this object's data. |
| attributes | back to summary |
|---|---|
| private BasicFileAttributes attributes | |
| cached | back to summary |
|---|---|
| private byte[] cached | |
| mediaFile | back to summary |
|---|---|
| private Path mediaFile | |
| LfsBlobLoader | back to summary |
|---|---|
| public LfsBlobLoader(Path mediaFile) throws IOException Create a loader for the LFS media file at the given path.
| |
| getCachedBytes | back to summary |
|---|---|
| public byte[] getCachedBytes() throws LargeObjectException Implements abstract org. Doc from org. Obtain a reference to the (possibly cached) bytes of this object. This method offers direct access to the internal caches, potentially saving on data copies between the internal cache and higher level code. Callers who receive this reference must not modify its contents. Changes (if made) will affect the cache but not the repository itself.
| |
| getSize | back to summary |
|---|---|
| public long getSize() Implements abstract org. Doc from org. Get size of object in bytes
| |
| getType | back to summary |
|---|---|
| public int getType() Implements abstract org. Doc from org. Get Git in pack object type
| |
| openStream | back to summary |
|---|---|
| public ObjectStream openStream() throws MissingObjectException, IOException Implements abstract org. Doc from org. Obtain an input stream to read this object's data.
| |