This option truncates console readout to fit in a single line. This
is default. Give false value to this option to tell aria2 not to
truncate console readout.
This option specifies piece selection algorithm used in HTTP/FTP
download. Piece means fixed length segment which is downloaded in
parallel in segmented download. If 'default' is given, aria2 selects
piece so that it reduces the number of establishing connection. This
is reasonable default behaviour because establishing connection is an
expensive operation. If 'inorder' is given, aria2 selects piece which
has minimum index. Index=0 means first of the file. This will be
useful to view movie while downloading it. --enable-http-pipelining
option may be useful to reduce reconnection overhead. Please note
that aria2 honors --min-split-size option, so it will be necessary to
specify a reasonable value to --min-split-size option.
We use SetFilePointerEx and SetEndOfFile to allocate extents. This
only works with NTFS. To enable this feature, --file-allocation=falloc
must be given.
+ DownloadFailureException.
Throwing DownloadFailureException may stop download unexpectedly when
--reuse-uri is false. Using CreateRequestCommand with STATUS_INACTIVE,
they can be executed next iteration with
DownloadEngine::setRefreshInterval(0).
The delay is caused because some Commands are only called in certain
interval(called refreshInterval, default, 1000ms). In aria2 download
stops when all Commands associated to it are stopped. Since some
Commands are called in each 1000ms by default, as mentioned before, we
have to wait for them. To fix this issue, we call
DownloadEngine::setRefreshInterval(0) when pausing/stopping downloads.
DownloadEngine::setRefreshInterval(0) makes refreshInterval 0 in one
shot.
When all segments are ignored, now DownloadFailureException is thrown.
And stop the download immediately. As described earlier, we call
DownloadEngine::setRefreshInterval(0) in catch block of
DownloadFailureException to eliminate delay.
--metalink-uri option specifies base URI to resolve relative URI in
metalink file stored in local disk. If URI points to a directory, URI
must end with '/'.
It seems that we have to specify the full path to cmd.exe in the first
argument of CreateProcess() to run batch file in proper manner. We
first determine the full path to cmd.exe. To do this, we get windir
environment variable and concatenate it with "\system32\cmd.exe".
If relative URI is found in Metalink file, aria2 resolves its full URI
contatenating the URI from which Metalink file is retrieved and
relative URI in Metalink file. This feature is not available if
Metalink file in local disk is specified in command line.