File tree Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -70,8 +70,6 @@ impl<'a> DownloadOptions<'a> {
70
70
data_type : & ' a str ,
71
71
paths : & ' a str ,
72
72
dst : & ' a str ,
73
- threads : usize ,
74
- max_retries : usize ,
75
73
numbered : bool ,
76
74
files_only : bool ,
77
75
progress : bool ,
@@ -86,13 +84,19 @@ impl<'a> DownloadOptions<'a> {
86
84
data_type,
87
85
paths : Path :: new ( paths) ,
88
86
dst : Path :: new ( dst) ,
89
- threads,
90
- max_retries,
87
+ threads : 10 ,
88
+ max_retries : 1000 ,
91
89
numbered,
92
90
files_only,
93
91
progress,
94
92
}
95
93
}
94
+ pub fn set_threads ( & mut self , threads : usize ) {
95
+ self . threads = threads;
96
+ }
97
+ pub fn set_max_retries ( & mut self , max_retries : usize ) {
98
+ self . max_retries = max_retries;
99
+ }
96
100
}
97
101
98
102
fn crawl_name_format ( crawl : & str ) -> Result < String , String > {
You can’t perform that action at this time.
0 commit comments