Class CacheEntry
java.lang.Object
com.biglybt.core.diskmanager.cache.impl.CacheEntry
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final DirectByteBuffer
private final int
private final int
protected static final int
protected static final int
protected boolean
protected int
private final CacheFileWithCache
private final long
protected long
private final int
protected int
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
CacheEntry
(int _entry_type, CacheFileWithCache _file, DirectByteBuffer _buffer, long _file_position, int _size) (package private)
CacheEntry
(long _offset) Constructs a dummy cache entry used to search in a Set -
Method Summary
-
Field Details
-
CT_DATA_WRITE
protected static final int CT_DATA_WRITE- See Also:
-
CT_READ_AHEAD
protected static final int CT_READ_AHEAD- See Also:
-
file
-
buffer
-
file_position
private final long file_position -
size
private final int size -
buffer_pos
private final int buffer_pos -
buffer_limit
private final int buffer_limit -
dirty
protected boolean dirty -
last_used
protected long last_used -
entry_type
protected int entry_type -
usage_count
protected int usage_count
-
-
Constructor Details
-
CacheEntry
CacheEntry(long _offset) Constructs a dummy cache entry used to search in a Set- Parameters:
offset
-
-
CacheEntry
protected CacheEntry(int _entry_type, CacheFileWithCache _file, DirectByteBuffer _buffer, long _file_position, int _size)
-
-
Method Details
-
getFile
-
getFilePosition
public long getFilePosition() -
getLength
public int getLength() -
getBuffer
-
isDirty
public boolean isDirty() -
setClean
public void setClean() -
resetBufferPosition
protected void resetBufferPosition() -
used
protected void used() -
getLastUsed
protected long getLastUsed() -
getUsageCount
protected int getUsageCount() -
getType
protected int getType() -
getString
-