Package com.biglybt.core.disk.impl
Class DiskManagerUtil
java.lang.Object
com.biglybt.core.disk.impl.DiskManagerUtil
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescription(package private) static class
static interface
-
Field Summary
FieldsModifier and TypeFieldDescription(package private) static final AEMonitor
private static final LogIDs
protected static int
private static boolean
private static List<CoreOperationTask>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic boolean
checkBlockConsistencyForHint
(DiskManager dm, String originator, int pieceNumber, int offset, int length) static boolean
checkBlockConsistencyForRead
(DiskManager dm, String originator, boolean peer_request, int pieceNumber, int offset, int length) static String
convertCacheStorageTypeToString
(int cache_type) static int
static int
convertDMStorageTypeToCache
(int dm_type) static String
convertDMStorageTypeToString
(int dm_type) static void
doFileExistenceChecksAfterSkipChange
(DiskManagerFileInfoSet fileSet, boolean[] toCheck, boolean isSkipped, DownloadManager dm) static DiskManagerPiece[]
static DiskManagerFileInfoSet
getFileInfoSkeleton
(DownloadManager download_manager, DiskManagerListener listener) static boolean
protected static void
loadFileDownloaded
(DownloadManager download_manager, DiskManagerFileInfoHelper[] files) (package private) static void
loadFilePriorities
(DownloadManager download_manager, DiskManagerFileInfoSet fileSet) static void
runMoveTask
(DownloadManager download_manager, File destination, Runnable target, DiskManagerUtil.MoveTaskAapter adapter) (package private) static String
setFileLink
(DownloadManager download_manager, DiskManagerFileInfo[] info, DiskManagerFileInfo file_info, File from_file, File to_link, boolean dont_delete_existing, FileUtil.ProgressListener pl) protected static void
storeFilePriorities
(DownloadManager download_manager, DiskManagerFileInfo[] files)
-
Field Details
-
LOGID
-
max_read_block_size
protected static int max_read_block_size -
cache_read_mon
-
move_tasks
-
move_smallest_first
private static boolean move_smallest_first
-
-
Constructor Details
-
DiskManagerUtil
public DiskManagerUtil()
-
-
Method Details
-
checkBlockConsistencyForHint
public static boolean checkBlockConsistencyForHint(DiskManager dm, String originator, int pieceNumber, int offset, int length) -
checkBlockConsistencyForRead
public static boolean checkBlockConsistencyForRead(DiskManager dm, String originator, boolean peer_request, int pieceNumber, int offset, int length) -
doFileExistenceChecksAfterSkipChange
public static void doFileExistenceChecksAfterSkipChange(DiskManagerFileInfoSet fileSet, boolean[] toCheck, boolean isSkipped, DownloadManager dm) -
setFileLink
static String setFileLink(DownloadManager download_manager, DiskManagerFileInfo[] info, DiskManagerFileInfo file_info, File from_file, File to_link, boolean dont_delete_existing, FileUtil.ProgressListener pl) -
getFileInfoSkeleton
public static DiskManagerFileInfoSet getFileInfoSkeleton(DownloadManager download_manager, DiskManagerListener listener) -
convertDMStorageTypeFromString
-
convertDMStorageTypeToString
-
convertCacheStorageTypeToString
-
convertDMStorageTypeToCache
public static int convertDMStorageTypeToCache(int dm_type) -
storeFilePriorities
protected static void storeFilePriorities(DownloadManager download_manager, DiskManagerFileInfo[] files) -
loadFilePriorities
-
loadFileDownloaded
protected static void loadFileDownloaded(DownloadManager download_manager, DiskManagerFileInfoHelper[] files) -
isNoSpaceException
-
getDiskManagerPiecesSnapshot
-
runMoveTask
public static void runMoveTask(DownloadManager download_manager, File destination, Runnable target, DiskManagerUtil.MoveTaskAapter adapter) throws DownloadManagerException - Throws:
DownloadManagerException
-