pub struct AddTorrentArg {Show 16 fields
pub source: TorrentSource,
pub savepath: Option<String>,
pub cookie: Option<String>,
pub category: Option<String>,
pub tags: Option<String>,
pub skip_checking: Option<String>,
pub paused: Option<String>,
pub root_folder: Option<String>,
pub rename: Option<String>,
pub up_limit: Option<i64>,
pub download_limit: Option<i64>,
pub ratio_limit: Option<f64>,
pub seeding_time_limit: Option<i64>,
pub auto_torrent_management: Option<bool>,
pub sequential_download: Option<String>,
pub first_last_piece_priority: Option<String>,
}
Fields§
§source: TorrentSource
§savepath: Option<String>
Download folder
Cookie sent to download the .torrent file
category: Option<String>
Category for the torrent
Tags for the torrent, split by ‘,’
skip_checking: Option<String>
Skip hash checking. Possible values are true
, false
(default)
paused: Option<String>
Add torrents in the paused state. Possible values are true
, false
(default)
root_folder: Option<String>
Create the root folder. Possible values are true
, false
, unset
(default)
rename: Option<String>
Rename torrent
up_limit: Option<i64>
Set torrent upload speed limit. Unit in bytes/second
download_limit: Option<i64>
Set torrent download speed limit. Unit in bytes/second
ratio_limit: Option<f64>
Set torrent share ratio limit
seeding_time_limit: Option<i64>
Set torrent seeding time limit. Unit in minutes
auto_torrent_management: Option<bool>
Whether Automatic Torrent Management should be used
sequential_download: Option<String>
Enable sequential download. Possible values are true
, false
(default)
first_last_piece_priority: Option<String>
Prioritize download first last piece. Possible values are true
,
false
(default)
Implementations§
Source§impl AddTorrentArg
impl AddTorrentArg
Sourcepub fn builder() -> AddTorrentArgBuilder<((), (), (), (), (), (), (), (), (), (), (), (), (), (), (), ())>
pub fn builder() -> AddTorrentArgBuilder<((), (), (), (), (), (), (), (), (), (), (), (), (), (), (), ())>
Create a builder for building AddTorrentArg
.
On the builder, call .source(...)
, .savepath(...)
(optional), .cookie(...)
(optional), .category(...)
(optional), .tags(...)
(optional), .skip_checking(...)
(optional), .paused(...)
(optional), .root_folder(...)
(optional), .rename(...)
(optional), .up_limit(...)
(optional), .download_limit(...)
(optional), .ratio_limit(...)
(optional), .seeding_time_limit(...)
(optional), .auto_torrent_management(...)
(optional), .sequential_download(...)
(optional), .first_last_piece_priority(...)
(optional) to set the values of the fields.
Finally, call .build()
to create the instance of AddTorrentArg
.
Trait Implementations§
Source§impl Clone for AddTorrentArg
impl Clone for AddTorrentArg
Source§fn clone(&self) -> AddTorrentArg
fn clone(&self) -> AddTorrentArg
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for AddTorrentArg
impl Debug for AddTorrentArg
Source§impl Default for AddTorrentArg
impl Default for AddTorrentArg
Source§fn default() -> AddTorrentArg
fn default() -> AddTorrentArg
Source§impl PartialEq for AddTorrentArg
impl PartialEq for AddTorrentArg
Source§impl Serialize for AddTorrentArg
impl Serialize for AddTorrentArg
impl StructuralPartialEq for AddTorrentArg
Auto Trait Implementations§
impl Freeze for AddTorrentArg
impl RefUnwindSafe for AddTorrentArg
impl Send for AddTorrentArg
impl Sync for AddTorrentArg
impl Unpin for AddTorrentArg
impl UnwindSafe for AddTorrentArg
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> Pipe for Twhere
T: ?Sized,
impl<T> Pipe for Twhere
T: ?Sized,
Source§fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
Source§fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
self
and passes that borrow into the pipe function. Read moreSource§fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
self
and passes that borrow into the pipe function. Read moreSource§fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
Source§fn pipe_borrow_mut<'a, B, R>(
&'a mut self,
func: impl FnOnce(&'a mut B) -> R,
) -> R
fn pipe_borrow_mut<'a, B, R>( &'a mut self, func: impl FnOnce(&'a mut B) -> R, ) -> R
Source§fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
self
, then passes self.as_ref()
into the pipe function.Source§fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
self
, then passes self.as_mut()
into the pipe
function.Source§fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
self
, then passes self.deref()
into the pipe function.Source§impl<T> Tap for T
impl<T> Tap for T
Source§fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
Borrow<B>
of a value. Read moreSource§fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
BorrowMut<B>
of a value. Read moreSource§fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
AsRef<R>
view of a value. Read moreSource§fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
AsMut<R>
view of a value. Read moreSource§fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
Deref::Target
of a value. Read moreSource§fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
Deref::Target
of a value. Read moreSource§fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
.tap()
only in debug builds, and is erased in release builds.Source§fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
.tap_mut()
only in debug builds, and is erased in release
builds.Source§fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
.tap_borrow()
only in debug builds, and is erased in release
builds.Source§fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
.tap_borrow_mut()
only in debug builds, and is erased in release
builds.Source§fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
.tap_ref()
only in debug builds, and is erased in release
builds.Source§fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
.tap_ref_mut()
only in debug builds, and is erased in release
builds.Source§fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
.tap_deref()
only in debug builds, and is erased in release
builds.