Rockbox open source high quality audio player as a Music Player Daemon
mpris rockbox mpd libadwaita audio rust zig deno
2
fork

Configure Feed

Select the types of activity you want to include in your feed.

Add tracing and FIFO PCM sink support

Initialize tracing_subscriber in CLI components and replace
println!/eprintln! calls with tracing macros across crates. Add
tracing/tracing-subscriber to workspace deps. Introduce sys bindings
and helpers (pcm_switch_sink, pcm_fifo_set_path) and NewGlobalSettings
fields (audio_output, fifo_path). Wire settings to switch to a FIFO
PCM sink on startup, expose FIFO sink in firmware headers, and include
hosted pcm-fifo.c in the build.

+5423 -2657
+103 -8
Cargo.lock
··· 1214 1214 "bitflags 2.6.0", 1215 1215 "cexpr", 1216 1216 "clang-sys", 1217 - "itertools 0.10.5", 1217 + "itertools 0.12.1", 1218 1218 "lazy_static", 1219 1219 "lazycell", 1220 1220 "log", ··· 1416 1416 checksum = "40723b8fb387abc38f4f4a37c09073622e41dd12327033091ef8950659e6dc0c" 1417 1417 dependencies = [ 1418 1418 "memchr", 1419 - "regex-automata", 1419 + "regex-automata 0.4.8", 1420 1420 "serde", 1421 1421 ] 1422 1422 ··· 4579 4579 dependencies = [ 4580 4580 "chrono", 4581 4581 "log", 4582 - "nu-ansi-term", 4582 + "nu-ansi-term 0.50.1", 4583 4583 "regex", 4584 4584 "thiserror 2.0.18", 4585 4585 ] ··· 5087 5087 "aho-corasick", 5088 5088 "bstr", 5089 5089 "log", 5090 - "regex-automata", 5091 - "regex-syntax", 5090 + "regex-automata 0.4.8", 5091 + "regex-syntax 0.8.5", 5092 5092 ] 5093 5093 5094 5094 [[package]] ··· 6815 6815 checksum = "ffbee8634e0d45d258acb448e7eaab3fce7a0a467395d4d9f228e3c1f01fb2e4" 6816 6816 6817 6817 [[package]] 6818 + name = "matchers" 6819 + version = "0.1.0" 6820 + source = "registry+https://github.com/rust-lang/crates.io-index" 6821 + checksum = "8263075bb86c5a1b1427b5ae862e8889656f126e9f77c484496e8b47cf5c5558" 6822 + dependencies = [ 6823 + "regex-automata 0.1.10", 6824 + ] 6825 + 6826 + [[package]] 6818 6827 name = "matchit" 6819 6828 version = "0.7.3" 6820 6829 source = "registry+https://github.com/rust-lang/crates.io-index" ··· 7194 7203 "mockito", 7195 7204 "once_cell", 7196 7205 "reqwest", 7206 + "tracing", 7197 7207 ] 7198 7208 7199 7209 [[package]] ··· 7321 7331 7322 7332 [[package]] 7323 7333 name = "nu-ansi-term" 7334 + version = "0.46.0" 7335 + source = "registry+https://github.com/rust-lang/crates.io-index" 7336 + checksum = "77a8165726e8236064dbb45459242600304b42a5ea24ee2948e18e023bf7ba84" 7337 + dependencies = [ 7338 + "overload", 7339 + "winapi", 7340 + ] 7341 + 7342 + [[package]] 7343 + name = "nu-ansi-term" 7324 7344 version = "0.50.1" 7325 7345 source = "registry+https://github.com/rust-lang/crates.io-index" 7326 7346 checksum = "d4a28e057d01f97e61255210fcff094d74ed0466038633e95017f5beb68e4399" ··· 7691 7711 version = "0.5.1" 7692 7712 source = "registry+https://github.com/rust-lang/crates.io-index" 7693 7713 checksum = "4030760ffd992bef45b0ae3f10ce1aba99e33464c90d14dd7c039884963ddc7a" 7714 + 7715 + [[package]] 7716 + name = "overload" 7717 + version = "0.1.1" 7718 + source = "registry+https://github.com/rust-lang/crates.io-index" 7719 + checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" 7694 7720 7695 7721 [[package]] 7696 7722 name = "owo-colors" ··· 8839 8865 dependencies = [ 8840 8866 "aho-corasick", 8841 8867 "memchr", 8842 - "regex-automata", 8843 - "regex-syntax", 8868 + "regex-automata 0.4.8", 8869 + "regex-syntax 0.8.5", 8870 + ] 8871 + 8872 + [[package]] 8873 + name = "regex-automata" 8874 + version = "0.1.10" 8875 + source = "registry+https://github.com/rust-lang/crates.io-index" 8876 + checksum = "6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132" 8877 + dependencies = [ 8878 + "regex-syntax 0.6.29", 8844 8879 ] 8845 8880 8846 8881 [[package]] ··· 8851 8886 dependencies = [ 8852 8887 "aho-corasick", 8853 8888 "memchr", 8854 - "regex-syntax", 8889 + "regex-syntax 0.8.5", 8855 8890 ] 8856 8891 8857 8892 [[package]] ··· 8862 8897 8863 8898 [[package]] 8864 8899 name = "regex-syntax" 8900 + version = "0.6.29" 8901 + source = "registry+https://github.com/rust-lang/crates.io-index" 8902 + checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" 8903 + 8904 + [[package]] 8905 + name = "regex-syntax" 8865 8906 version = "0.8.5" 8866 8907 source = "registry+https://github.com/rust-lang/crates.io-index" 8867 8908 checksum = "2b15c43186be67a4fd63bee50d0303afffcef381492ebe2c5d87f324e1b8815c" ··· 9032 9073 "tonic-build", 9033 9074 "tonic-reflection", 9034 9075 "tonic-web", 9076 + "tracing", 9077 + "tracing-subscriber", 9035 9078 "warp", 9036 9079 "zip", 9037 9080 ] ··· 9068 9111 "rockbox-settings", 9069 9112 "rockbox-typesense", 9070 9113 "tokio", 9114 + "tracing", 9115 + "tracing-subscriber", 9071 9116 "uuid", 9072 9117 ] 9073 9118 ··· 9152 9197 "serde_json", 9153 9198 "sqlx", 9154 9199 "tokio", 9200 + "tracing", 9155 9201 ] 9156 9202 9157 9203 [[package]] ··· 9173 9219 "tokio", 9174 9220 "tokio-stream", 9175 9221 "tonic", 9222 + "tracing", 9176 9223 ] 9177 9224 9178 9225 [[package]] ··· 9186 9233 "rockbox-library", 9187 9234 "rockbox-rpc", 9188 9235 "tokio", 9236 + "tracing", 9189 9237 "urlencoding", 9190 9238 ] 9191 9239 ··· 9291 9339 "sqlx", 9292 9340 "threadpool", 9293 9341 "tokio", 9342 + "tracing", 9294 9343 "url", 9295 9344 "urlencoding", 9296 9345 ] ··· 9352 9401 "rockbox-library", 9353 9402 "serde", 9354 9403 "serde_json", 9404 + "tracing", 9355 9405 "uuid", 9356 9406 ] 9357 9407 ··· 10044 10094 dependencies = [ 10045 10095 "digest 0.10.7", 10046 10096 "keccak", 10097 + ] 10098 + 10099 + [[package]] 10100 + name = "sharded-slab" 10101 + version = "0.1.7" 10102 + source = "registry+https://github.com/rust-lang/crates.io-index" 10103 + checksum = "f40ca3c46823713e0d4209592e8d6e826aa57e928f09752619fc696c499637f6" 10104 + dependencies = [ 10105 + "lazy_static", 10047 10106 ] 10048 10107 10049 10108 [[package]] ··· 11877 11936 checksum = "c06d3da6113f116aaee68e4d601191614c9053067f9ab7f6edbcb161237daa54" 11878 11937 dependencies = [ 11879 11938 "once_cell", 11939 + "valuable", 11940 + ] 11941 + 11942 + [[package]] 11943 + name = "tracing-log" 11944 + version = "0.2.0" 11945 + source = "registry+https://github.com/rust-lang/crates.io-index" 11946 + checksum = "ee855f1f400bd0e5c02d150ae5de3840039a3f54b025156404e34c23c03f47c3" 11947 + dependencies = [ 11948 + "log", 11949 + "once_cell", 11950 + "tracing-core", 11951 + ] 11952 + 11953 + [[package]] 11954 + name = "tracing-subscriber" 11955 + version = "0.3.18" 11956 + source = "registry+https://github.com/rust-lang/crates.io-index" 11957 + checksum = "ad0f048c97dbd9faa9b7df56362b8ebcaa52adb06b498c050d2f4e32f90a7a8b" 11958 + dependencies = [ 11959 + "matchers", 11960 + "nu-ansi-term 0.46.0", 11961 + "once_cell", 11962 + "regex", 11963 + "sharded-slab", 11964 + "smallvec", 11965 + "thread_local", 11966 + "tracing", 11967 + "tracing-core", 11968 + "tracing-log", 11880 11969 ] 11881 11970 11882 11971 [[package]] ··· 12250 12339 version = "0.15.8" 12251 12340 source = "registry+https://github.com/rust-lang/crates.io-index" 12252 12341 checksum = "4e8257fbc510f0a46eb602c10215901938b5c2a7d5e70fc11483b1d3c9b5b18c" 12342 + 12343 + [[package]] 12344 + name = "valuable" 12345 + version = "0.1.1" 12346 + source = "registry+https://github.com/rust-lang/crates.io-index" 12347 + checksum = "ba73ea9cf16a25df0c8caa16c51acb937d5712a8429db78a3ee29d5dcacd3a65" 12253 12348 12254 12349 [[package]] 12255 12350 name = "value-bag"
+2
Cargo.toml
··· 161 161 "proposed", 162 162 ] } 163 163 tower-service = "0.3.2" 164 + tracing = "0.1" 165 + tracing-subscriber = { version = "0.3", features = ["env-filter"] } 164 166 twox-hash = "=1.6.3" 165 167 url = { version = "2.5", features = ["serde", "expose_internals"] } 166 168 uuid = { version = "1.3.0", features = ["v4"] }
+2
cli/Cargo.toml
··· 33 33 warp = "0.3.7" 34 34 dirs = "6.0.0" 35 35 rockbox-typesense = { path = "../crates/typesense" } 36 + tracing = { workspace = true } 37 + tracing-subscriber = { workspace = true } 36 38 37 39 [build-dependencies] 38 40 tonic-build = "0.12.3"
+8
cli/src/main.rs
··· 98 98 99 99 #[tokio::main] 100 100 async fn main() -> Result<(), Error> { 101 + tracing_subscriber::fmt() 102 + .with_writer(std::io::stderr) 103 + .with_env_filter( 104 + tracing_subscriber::EnvFilter::try_from_default_env() 105 + .unwrap_or_else(|_| tracing_subscriber::EnvFilter::new("info")), 106 + ) 107 + .init(); 108 + 101 109 let args = std::env::args().collect::<Vec<String>>(); 102 110 if args.len() > 1 && args[1] == "run" { 103 111 let _args = args
+2
crates/cli/Cargo.toml
··· 18 18 dirs = "6.0.0" 19 19 uuid.workspace = true 20 20 libc.workspace = true 21 + tracing = { workspace = true } 22 + tracing-subscriber = { workspace = true }
+25 -31
crates/cli/src/lib.rs
··· 11 11 use std::time::Duration; 12 12 use std::{env, ffi::CStr}; 13 13 use std::{fs, thread}; 14 + use tracing::{error, info, warn}; 14 15 15 16 /// PID of the spawned typesense-server child, or -1 if not yet started. 16 17 static TYPESENSE_PID: AtomicI32 = AtomicI32::new(-1); ··· 32 33 33 34 #[no_mangle] 34 35 pub extern "C" fn parse_args(argc: usize, argv: *const *const u8) -> i32 { 36 + tracing_subscriber::fmt() 37 + .with_writer(std::io::stderr) 38 + .with_env_filter( 39 + tracing_subscriber::EnvFilter::try_from_default_env() 40 + .unwrap_or_else(|_| tracing_subscriber::EnvFilter::new("info")), 41 + ) 42 + .init(); 43 + 35 44 let string_array = unsafe { std::slice::from_raw_parts(argv, argc) }; 36 45 let args: Vec<&str> = string_array 37 46 .iter() ··· 78 87 match fs::create_dir_all(format!("{}/Music", home)) { 79 88 Ok(_) => {} 80 89 Err(e) => { 81 - eprintln!("Failed to create Music directory: {}", e); 90 + error!("Failed to create Music directory: {}", e); 82 91 } 83 92 } 84 93 ··· 98 107 let tracks = repo::track::all(pool.clone()).await?; 99 108 if tracks.is_empty() || update_library { 100 109 match scan_audio_files(pool.clone(), path.into()).await { 101 - Ok(_) => println!("Finished scanning audio files"), 102 - Err(e) => eprintln!("Failed to scan audio files: {}", e), 110 + Ok(_) => info!("Finished scanning audio files"), 111 + Err(e) => error!("Failed to scan audio files: {}", e), 103 112 } 104 113 let tracks = repo::track::all(pool.clone()).await?; 105 114 let albums = repo::album::all(pool.clone()).await?; ··· 120 129 thread::spawn(move || { 121 130 sleep(Duration::from_secs(5)); 122 131 match rockbox_rocksky::register_rockbox() { 123 - Ok(_) => println!("Successfully registered Rockbox with Rocksky server"), 124 - Err(e) => eprintln!("Failed to register Rockbox with Rocksky server: {}", e), 132 + Ok(_) => info!("Successfully registered Rockbox with Rocksky server"), 133 + Err(e) => error!("Failed to register Rockbox with Rocksky server: {}", e), 125 134 }; 126 135 }); 127 136 ··· 139 148 let port = std::env::var("ROCKBOX_TCP_PORT").unwrap_or_else(|_| "6063".to_string()); 140 149 let addr = format!("0.0.0.0:{}", port); 141 150 142 - println!( 143 - "{} server is running on {}", 144 - "Rockbox TCP".bright_purple(), 145 - addr.bright_green() 146 - ); 151 + info!("Rockbox TCP server is running on {}", addr); 147 152 148 153 let graphql_port = env::var("ROCKBOX_GRAPHQL_PORT").unwrap_or("6062".to_string()); 149 154 let addr = format!("{}:{}", "0.0.0.0", graphql_port); 150 155 151 - println!( 152 - "{} server is running on {}", 153 - "Rockbox GraphQL".bright_purple(), 154 - addr.bright_green() 155 - ); 156 + info!("Rockbox GraphQL server is running on {}", addr); 156 157 157 158 let rockbox_port: u16 = std::env::var("ROCKBOX_PORT") 158 159 .unwrap_or_else(|_| "6061".to_string()) ··· 161 162 162 163 let host_and_port = format!("0.0.0.0:{}", rockbox_port); 163 164 164 - println!( 165 - "{} server is running on {}", 166 - "Rockbox gRPC".bright_purple(), 167 - host_and_port.bright_green() 168 - ); 165 + info!("Rockbox gRPC server is running on {}", host_and_port); 169 166 170 - println!( 171 - "Rockbox Web UI is running on {} ⚡", 172 - "http://localhost:6062".bright_green() 173 - ); 167 + info!("Rockbox Web UI is running on http://localhost:6062"); 174 168 }); 175 169 176 170 thread::spawn(move || { ··· 179 173 let api_key = uuid::Uuid::new_v4().to_string(); 180 174 let api_key = std::env::var("RB_TYPESENSE_API_KEY").unwrap_or(api_key); 181 175 std::env::set_var("RB_TYPESENSE_API_KEY", &api_key); 182 - println!("Using Typesense API key: {}", api_key); 176 + info!("Using Typesense API key: {}", api_key); 183 177 184 178 let port = std::env::var("RB_TYPESENSE_PORT").unwrap_or_else(|_| "8109".to_string()); 185 179 std::env::set_var("RB_TYPESENSE_PORT", &port); ··· 227 221 loop { 228 222 match child.try_wait() { 229 223 Ok(Some(status)) => { 230 - eprintln!("typesense-server exited: {status}"); 224 + warn!("typesense-server exited: {status}"); 231 225 break; 232 226 } 233 227 Ok(None) => sleep(Duration::from_millis(500)), 234 228 Err(e) => { 235 - eprintln!("typesense-server monitor error: {e}"); 229 + error!("typesense-server monitor error: {e}"); 236 230 break; 237 231 } 238 232 } ··· 246 240 #[no_mangle] 247 241 pub extern "C" fn save_remote_track_metadata(url: *const std::ffi::c_char) -> i32 { 248 242 if url.is_null() { 249 - eprintln!("save_remote_track_metadata: null url"); 243 + warn!("save_remote_track_metadata: null url"); 250 244 return -1; 251 245 } 252 246 ··· 254 248 let url = match url.to_str() { 255 249 Ok(url) => url, 256 250 Err(e) => { 257 - eprintln!("save_remote_track_metadata: invalid utf-8: {}", e); 251 + warn!("save_remote_track_metadata: invalid utf-8: {}", e); 258 252 return -1; 259 253 } 260 254 }; ··· 262 256 let rt = match tokio::runtime::Runtime::new() { 263 257 Ok(rt) => rt, 264 258 Err(e) => { 265 - eprintln!( 259 + error!( 266 260 "save_remote_track_metadata: failed to create runtime: {}", 267 261 e 268 262 ); ··· 276 270 }) { 277 271 Ok(()) => 0, 278 272 Err(e) => { 279 - eprintln!("save_remote_track_metadata: {}", e); 273 + error!("save_remote_track_metadata: {}", e); 280 274 -1 281 275 } 282 276 }
+1
crates/library/Cargo.toml
··· 20 20 serde_json = "1.0.128" 21 21 sqlx = {version = "0.8.2", features = ["runtime-tokio", "tls-rustls", "sqlite", "chrono", "derive", "macros"]} 22 22 tokio = {version = "1.36.0", features = ["full"]} 23 + tracing = { workspace = true }
+5 -4
crates/library/src/repo/album.rs
··· 1 1 use crate::entity::album::Album; 2 2 use sqlx::{Pool, Sqlite}; 3 + use tracing::warn; 3 4 4 5 pub async fn save(pool: Pool<Sqlite>, album: Album) -> Result<String, sqlx::Error> { 5 6 match sqlx::query( ··· 68 69 { 69 70 Ok(album) => Ok(album), 70 71 Err(e) => { 71 - eprintln!("Error finding album: {:?}", e); 72 + warn!("Error finding album: {:?}", e); 72 73 Err(e) 73 74 } 74 75 } ··· 89 90 { 90 91 Ok(albums) => Ok(albums), 91 92 Err(e) => { 92 - eprintln!("Error finding albums: {:?}", e); 93 + warn!("Error finding albums: {:?}", e); 93 94 Err(e) 94 95 } 95 96 } ··· 107 108 { 108 109 Ok(album) => Ok(album), 109 110 Err(e) => { 110 - eprintln!("Error finding album: {:?}", e); 111 + warn!("Error finding album: {:?}", e); 111 112 Err(e) 112 113 } 113 114 } ··· 124 125 { 125 126 Ok(albums) => Ok(albums), 126 127 Err(e) => { 127 - eprintln!("Error finding albums: {:?}", e); 128 + warn!("Error finding albums: {:?}", e); 128 129 Err(e) 129 130 } 130 131 }
+1
crates/mpd/Cargo.toml
··· 19 19 tokio = {version = "1.36.0", features = ["full"]} 20 20 tokio-stream = "0.1" 21 21 tonic = "0.12.2" 22 + tracing = { workspace = true }
+3 -2
crates/mpd/src/handlers/playback.rs
··· 1 1 use anyhow::Error; 2 + use tracing::warn; 2 3 use rockbox_rpc::api::rockbox::v1alpha1::{ 3 4 AdjustVolumeRequest, NextRequest, PauseRequest, PlayRequest, PreviousRequest, ResumeRequest, 4 5 SaveSettingsRequest, StartRequest, ··· 253 254 tx: Sender<String>, 254 255 ) -> Result<String, Error> { 255 256 // TODO: Implement seek 256 - println!("{}", request); 257 + warn!("handle_seek not implemented: {}", request); 257 258 258 259 if !ctx.batch { 259 260 tx.send("OK\n".to_string()).await?; ··· 268 269 tx: Sender<String>, 269 270 ) -> Result<String, Error> { 270 271 // TODO: Implement seekid 271 - println!("{}", request); 272 + warn!("handle_seekid not implemented: {}", request); 272 273 273 274 if !ctx.batch { 274 275 tx.send("OK\n".to_string()).await?;
+1
crates/mpris/Cargo.toml
··· 12 12 rockbox-library = {path= "../library"} 13 13 tokio = {version = "1.36.0", features = ["full"]} 14 14 urlencoding = "2.1.3" 15 + tracing = { workspace = true }
+6 -5
crates/mpris/src/lib.rs
··· 1 1 use std::{env, future, sync::Arc}; 2 2 3 3 use anyhow::Error; 4 + use tracing::warn; 4 5 use async_std::stream::StreamExt; 5 6 use mpris_server::{LoopStatus, Metadata, PlaybackStatus, Player, Time, TrackId}; 6 7 use rockbox_graphql::{ ··· 94 95 1 => match player.set_playback_status(PlaybackStatus::Playing).await { 95 96 Ok(_) => {} 96 97 Err(e) => { 97 - eprintln!("Error: {}", e); 98 + warn!("Error: {}", e); 98 99 } 99 100 }, 100 101 3 => match player.set_playback_status(PlaybackStatus::Paused).await { 101 102 Ok(_) => {} 102 103 Err(e) => { 103 - eprintln!("Error: {}", e); 104 + warn!("Error: {}", e); 104 105 } 105 106 }, 106 107 _ => match player.set_playback_status(PlaybackStatus::Stopped).await { 107 108 Ok(_) => {} 108 109 Err(e) => { 109 - eprintln!("Error: {}", e); 110 + warn!("Error: {}", e); 110 111 } 111 112 }, 112 113 } ··· 146 147 match player.set_metadata(metadata).await { 147 148 Ok(_) => {} 148 149 Err(e) => { 149 - eprintln!("Error: {}", e); 150 + warn!("Error: {}", e); 150 151 } 151 152 } 152 153 ··· 154 155 match player.seeked(Time::from_millis(track.elapsed as i64)).await { 155 156 Ok(_) => {} 156 157 Err(e) => { 157 - eprintln!("Error: {}", e); 158 + warn!("Error: {}", e); 158 159 } 159 160 } 160 161 }
+8 -8
crates/mpris/src/macros.rs
··· 12 12 }) { 13 13 Ok(_) => {} 14 14 Err(e) => { 15 - eprintln!("Error: {}", e); 15 + tracing::warn!("Error: {}", e); 16 16 } 17 17 } 18 18 }); ··· 38 38 }) { 39 39 Ok(_) => {} 40 40 Err(e) => { 41 - eprintln!("Error: {}", e); 41 + tracing::warn!("Error: {}", e); 42 42 } 43 43 } 44 44 }); ··· 64 64 }) { 65 65 Ok(_) => {} 66 66 Err(e) => { 67 - eprintln!("Error: {}", e); 67 + tracing::warn!("Error: {}", e); 68 68 } 69 69 } 70 70 }); ··· 92 92 }) { 93 93 Ok(_) => {} 94 94 Err(e) => { 95 - eprintln!("Error: {}", e); 95 + tracing::warn!("Error: {}", e); 96 96 } 97 97 } 98 98 }); ··· 114 114 { 115 115 Ok(response) => response.into_inner().volume, 116 116 Err(e) => { 117 - eprintln!("Error: {}", e); 117 + tracing::warn!("Error: {}", e); 118 118 0 119 119 } 120 120 }; ··· 132 132 }) { 133 133 Ok(_) => {} 134 134 Err(e) => { 135 - eprintln!("Error: {}", e); 135 + tracing::warn!("Error: {}", e); 136 136 } 137 137 } 138 138 }); ··· 158 158 }) { 159 159 Ok(_) => {} 160 160 Err(e) => { 161 - eprintln!("Error: {}", e); 161 + tracing::warn!("Error: {}", e); 162 162 } 163 163 } 164 164 }); ··· 189 189 }) { 190 190 Ok(_) => {} 191 191 Err(e) => { 192 - eprintln!("Error: {}", e); 192 + tracing::warn!("Error: {}", e); 193 193 } 194 194 } 195 195 });
+1
crates/netstream/Cargo.toml
··· 11 11 reqwest = { version = "0.12.5", features = ["blocking", "rustls-tls"], default-features = false } 12 12 once_cell = "1.17.1" 13 13 libc = "0.2.168" 14 + tracing = "0.1" 14 15 15 16 [dev-dependencies] 16 17 mockito = "1.7.2"
+11 -10
crates/netstream/src/lib.rs
··· 5 5 use std::os::raw::c_char; 6 6 use std::sync::atomic::{AtomicI32, Ordering}; 7 7 use std::sync::{Arc, Mutex}; 8 + use tracing::{debug, warn}; 8 9 9 10 /// Sentinel handle ID returned on error. 10 11 const INVALID_HANDLE: i32 = -1; ··· 186 187 187 188 let state = match StreamState::new(url_str.clone()) { 188 189 Some(s) => { 189 - eprintln!( 190 + debug!( 190 191 "[netstream] rb_net_open: url={} content_length={:?} content_type={:?}", 191 192 url_str, s.content_length, s.content_type 192 193 ); 193 194 s 194 195 } 195 196 None => { 196 - eprintln!("[netstream] rb_net_open: FAILED url={}", url_str); 197 + warn!("[netstream] rb_net_open: FAILED url={}", url_str); 197 198 return INVALID_HANDLE; 198 199 } 199 200 }; ··· 203 204 .lock() 204 205 .unwrap() 205 206 .insert(handle, Arc::new(Mutex::new(state))); 206 - eprintln!( 207 + debug!( 207 208 "[netstream] rb_net_open: url={} -> handle={}", 208 209 url_str, handle 209 210 ); ··· 239 240 match read_as_file(resp, buf) { 240 241 Ok(bytes_read) => { 241 242 state.pos += bytes_read as u64; 242 - eprintln!( 243 + tracing::trace!( 243 244 "[netstream] rb_net_read: h={} n={} pos_before={} -> read={} pos_after={}", 244 245 h, n, pos_before, bytes_read, state.pos 245 246 ); 246 247 bytes_read as i64 247 248 } 248 249 Err(e) => { 249 - eprintln!( 250 + warn!( 250 251 "[netstream] rb_net_read: h={} n={} pos={} -> ERROR {:?}", 251 252 h, n, pos_before, e 252 253 ); ··· 312 313 313 314 // Fast-path: already there (no need to restart the request). 314 315 if new_pos == state.pos { 315 - eprintln!( 316 + debug!( 316 317 "[netstream] rb_net_lseek: h={} off={} whence={} -> already at pos={} (no-op)", 317 318 h, off, whence, state.pos 318 319 ); ··· 321 322 322 323 let old_pos = state.pos; 323 324 if state.seek_to(new_pos) { 324 - eprintln!( 325 + debug!( 325 326 "[netstream] rb_net_lseek: h={} off={} whence={} old_pos={} -> new_pos={}", 326 327 h, off, whence, old_pos, state.pos 327 328 ); 328 329 state.pos as i64 329 330 } else { 330 - eprintln!( 331 + warn!( 331 332 "[netstream] rb_net_lseek: h={} off={} whence={} old_pos={} -> FAILED", 332 333 h, off, whence, old_pos 333 334 ); ··· 351 352 .content_length 352 353 .map(|l| l as i64) 353 354 .unwrap_or(-1); 354 - eprintln!("[netstream] rb_net_len: h={} -> {}", h, len); 355 + debug!("[netstream] rb_net_len: h={} -> {}", h, len); 355 356 len 356 357 } 357 358 ··· 388 389 /// Close stream `h` and release its resources. 389 390 #[no_mangle] 390 391 pub extern "C" fn rb_net_close(h: i32) { 391 - eprintln!("[netstream] rb_net_close: h={}", h); 392 + debug!("[netstream] rb_net_close: h={}", h); 392 393 STREAMS.lock().unwrap().remove(&h); 393 394 } 394 395
+2506 -1240
crates/rocksky/src/api/rockbox.v1alpha1.rs
··· 43 43 dead_code, 44 44 missing_docs, 45 45 clippy::wildcard_imports, 46 - clippy::let_unit_value 46 + clippy::let_unit_value, 47 47 )] 48 - use tonic::codegen::http::Uri; 49 48 use tonic::codegen::*; 49 + use tonic::codegen::http::Uri; 50 50 #[derive(Debug, Clone)] 51 51 pub struct BrowseServiceClient<T> { 52 52 inner: tonic::client::Grpc<T>, ··· 90 90 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody, 91 91 >, 92 92 >, 93 - <T as tonic::codegen::Service<http::Request<tonic::body::BoxBody>>>::Error: 94 - Into<StdError> + std::marker::Send + std::marker::Sync, 93 + <T as tonic::codegen::Service< 94 + http::Request<tonic::body::BoxBody>, 95 + >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync, 95 96 { 96 97 BrowseServiceClient::new(InterceptedService::new(inner, interceptor)) 97 98 } ··· 129 130 pub async fn tree_get_entries( 130 131 &mut self, 131 132 request: impl tonic::IntoRequest<super::TreeGetEntriesRequest>, 132 - ) -> std::result::Result<tonic::Response<super::TreeGetEntriesResponse>, tonic::Status> 133 - { 134 - self.inner.ready().await.map_err(|e| { 135 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 136 - })?; 133 + ) -> std::result::Result< 134 + tonic::Response<super::TreeGetEntriesResponse>, 135 + tonic::Status, 136 + > { 137 + self.inner 138 + .ready() 139 + .await 140 + .map_err(|e| { 141 + tonic::Status::unknown( 142 + format!("Service was not ready: {}", e.into()), 143 + ) 144 + })?; 137 145 let codec = tonic::codec::ProstCodec::default(); 138 146 let path = http::uri::PathAndQuery::from_static( 139 147 "/rockbox.v1alpha1.BrowseService/TreeGetEntries", 140 148 ); 141 149 let mut req = request.into_request(); 142 - req.extensions_mut().insert(GrpcMethod::new( 143 - "rockbox.v1alpha1.BrowseService", 144 - "TreeGetEntries", 145 - )); 150 + req.extensions_mut() 151 + .insert( 152 + GrpcMethod::new("rockbox.v1alpha1.BrowseService", "TreeGetEntries"), 153 + ); 146 154 self.inner.unary(req, path, codec).await 147 155 } 148 156 } ··· 154 162 dead_code, 155 163 missing_docs, 156 164 clippy::wildcard_imports, 157 - clippy::let_unit_value 165 + clippy::let_unit_value, 158 166 )] 159 167 use tonic::codegen::*; 160 168 /// Generated trait containing gRPC methods that should be implemented for use with BrowseServiceServer. ··· 163 171 async fn tree_get_entries( 164 172 &self, 165 173 request: tonic::Request<super::TreeGetEntriesRequest>, 166 - ) -> std::result::Result<tonic::Response<super::TreeGetEntriesResponse>, tonic::Status>; 174 + ) -> std::result::Result< 175 + tonic::Response<super::TreeGetEntriesResponse>, 176 + tonic::Status, 177 + >; 167 178 } 168 179 #[derive(Debug)] 169 180 pub struct BrowseServiceServer<T> { ··· 186 197 max_encoding_message_size: None, 187 198 } 188 199 } 189 - pub fn with_interceptor<F>(inner: T, interceptor: F) -> InterceptedService<Self, F> 200 + pub fn with_interceptor<F>( 201 + inner: T, 202 + interceptor: F, 203 + ) -> InterceptedService<Self, F> 190 204 where 191 205 F: tonic::service::Interceptor, 192 206 { ··· 241 255 "/rockbox.v1alpha1.BrowseService/TreeGetEntries" => { 242 256 #[allow(non_camel_case_types)] 243 257 struct TreeGetEntriesSvc<T: BrowseService>(pub Arc<T>); 244 - impl<T: BrowseService> tonic::server::UnaryService<super::TreeGetEntriesRequest> 245 - for TreeGetEntriesSvc<T> 246 - { 258 + impl< 259 + T: BrowseService, 260 + > tonic::server::UnaryService<super::TreeGetEntriesRequest> 261 + for TreeGetEntriesSvc<T> { 247 262 type Response = super::TreeGetEntriesResponse; 248 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 263 + type Future = BoxFuture< 264 + tonic::Response<Self::Response>, 265 + tonic::Status, 266 + >; 249 267 fn call( 250 268 &mut self, 251 269 request: tonic::Request<super::TreeGetEntriesRequest>, 252 270 ) -> Self::Future { 253 271 let inner = Arc::clone(&self.0); 254 272 let fut = async move { 255 - <T as BrowseService>::tree_get_entries(&inner, request).await 273 + <T as BrowseService>::tree_get_entries(&inner, request) 274 + .await 256 275 }; 257 276 Box::pin(fut) 258 277 } ··· 279 298 }; 280 299 Box::pin(fut) 281 300 } 282 - _ => Box::pin(async move { 283 - let mut response = http::Response::new(empty_body()); 284 - let headers = response.headers_mut(); 285 - headers.insert( 286 - tonic::Status::GRPC_STATUS, 287 - (tonic::Code::Unimplemented as i32).into(), 288 - ); 289 - headers.insert( 290 - http::header::CONTENT_TYPE, 291 - tonic::metadata::GRPC_CONTENT_TYPE, 292 - ); 293 - Ok(response) 294 - }), 301 + _ => { 302 + Box::pin(async move { 303 + let mut response = http::Response::new(empty_body()); 304 + let headers = response.headers_mut(); 305 + headers 306 + .insert( 307 + tonic::Status::GRPC_STATUS, 308 + (tonic::Code::Unimplemented as i32).into(), 309 + ); 310 + headers 311 + .insert( 312 + http::header::CONTENT_TYPE, 313 + tonic::metadata::GRPC_CONTENT_TYPE, 314 + ); 315 + Ok(response) 316 + }) 317 + } 295 318 } 296 319 } 297 320 } ··· 527 550 dead_code, 528 551 missing_docs, 529 552 clippy::wildcard_imports, 530 - clippy::let_unit_value 553 + clippy::let_unit_value, 531 554 )] 532 - use tonic::codegen::http::Uri; 533 555 use tonic::codegen::*; 556 + use tonic::codegen::http::Uri; 534 557 #[derive(Debug, Clone)] 535 558 pub struct LibraryServiceClient<T> { 536 559 inner: tonic::client::Grpc<T>, ··· 574 597 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody, 575 598 >, 576 599 >, 577 - <T as tonic::codegen::Service<http::Request<tonic::body::BoxBody>>>::Error: 578 - Into<StdError> + std::marker::Send + std::marker::Sync, 600 + <T as tonic::codegen::Service< 601 + http::Request<tonic::body::BoxBody>, 602 + >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync, 579 603 { 580 604 LibraryServiceClient::new(InterceptedService::new(inner, interceptor)) 581 605 } ··· 613 637 pub async fn get_albums( 614 638 &mut self, 615 639 request: impl tonic::IntoRequest<super::GetAlbumsRequest>, 616 - ) -> std::result::Result<tonic::Response<super::GetAlbumsResponse>, tonic::Status> { 617 - self.inner.ready().await.map_err(|e| { 618 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 619 - })?; 640 + ) -> std::result::Result< 641 + tonic::Response<super::GetAlbumsResponse>, 642 + tonic::Status, 643 + > { 644 + self.inner 645 + .ready() 646 + .await 647 + .map_err(|e| { 648 + tonic::Status::unknown( 649 + format!("Service was not ready: {}", e.into()), 650 + ) 651 + })?; 620 652 let codec = tonic::codec::ProstCodec::default(); 621 - let path = 622 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.LibraryService/GetAlbums"); 653 + let path = http::uri::PathAndQuery::from_static( 654 + "/rockbox.v1alpha1.LibraryService/GetAlbums", 655 + ); 623 656 let mut req = request.into_request(); 624 - req.extensions_mut().insert(GrpcMethod::new( 625 - "rockbox.v1alpha1.LibraryService", 626 - "GetAlbums", 627 - )); 657 + req.extensions_mut() 658 + .insert(GrpcMethod::new("rockbox.v1alpha1.LibraryService", "GetAlbums")); 628 659 self.inner.unary(req, path, codec).await 629 660 } 630 661 pub async fn get_artists( 631 662 &mut self, 632 663 request: impl tonic::IntoRequest<super::GetArtistsRequest>, 633 - ) -> std::result::Result<tonic::Response<super::GetArtistsResponse>, tonic::Status> 634 - { 635 - self.inner.ready().await.map_err(|e| { 636 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 637 - })?; 664 + ) -> std::result::Result< 665 + tonic::Response<super::GetArtistsResponse>, 666 + tonic::Status, 667 + > { 668 + self.inner 669 + .ready() 670 + .await 671 + .map_err(|e| { 672 + tonic::Status::unknown( 673 + format!("Service was not ready: {}", e.into()), 674 + ) 675 + })?; 638 676 let codec = tonic::codec::ProstCodec::default(); 639 - let path = 640 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.LibraryService/GetArtists"); 677 + let path = http::uri::PathAndQuery::from_static( 678 + "/rockbox.v1alpha1.LibraryService/GetArtists", 679 + ); 641 680 let mut req = request.into_request(); 642 - req.extensions_mut().insert(GrpcMethod::new( 643 - "rockbox.v1alpha1.LibraryService", 644 - "GetArtists", 645 - )); 681 + req.extensions_mut() 682 + .insert( 683 + GrpcMethod::new("rockbox.v1alpha1.LibraryService", "GetArtists"), 684 + ); 646 685 self.inner.unary(req, path, codec).await 647 686 } 648 687 pub async fn get_tracks( 649 688 &mut self, 650 689 request: impl tonic::IntoRequest<super::GetTracksRequest>, 651 - ) -> std::result::Result<tonic::Response<super::GetTracksResponse>, tonic::Status> { 652 - self.inner.ready().await.map_err(|e| { 653 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 654 - })?; 690 + ) -> std::result::Result< 691 + tonic::Response<super::GetTracksResponse>, 692 + tonic::Status, 693 + > { 694 + self.inner 695 + .ready() 696 + .await 697 + .map_err(|e| { 698 + tonic::Status::unknown( 699 + format!("Service was not ready: {}", e.into()), 700 + ) 701 + })?; 655 702 let codec = tonic::codec::ProstCodec::default(); 656 - let path = 657 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.LibraryService/GetTracks"); 703 + let path = http::uri::PathAndQuery::from_static( 704 + "/rockbox.v1alpha1.LibraryService/GetTracks", 705 + ); 658 706 let mut req = request.into_request(); 659 - req.extensions_mut().insert(GrpcMethod::new( 660 - "rockbox.v1alpha1.LibraryService", 661 - "GetTracks", 662 - )); 707 + req.extensions_mut() 708 + .insert(GrpcMethod::new("rockbox.v1alpha1.LibraryService", "GetTracks")); 663 709 self.inner.unary(req, path, codec).await 664 710 } 665 711 pub async fn get_album( 666 712 &mut self, 667 713 request: impl tonic::IntoRequest<super::GetAlbumRequest>, 668 - ) -> std::result::Result<tonic::Response<super::GetAlbumResponse>, tonic::Status> { 669 - self.inner.ready().await.map_err(|e| { 670 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 671 - })?; 714 + ) -> std::result::Result< 715 + tonic::Response<super::GetAlbumResponse>, 716 + tonic::Status, 717 + > { 718 + self.inner 719 + .ready() 720 + .await 721 + .map_err(|e| { 722 + tonic::Status::unknown( 723 + format!("Service was not ready: {}", e.into()), 724 + ) 725 + })?; 672 726 let codec = tonic::codec::ProstCodec::default(); 673 - let path = 674 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.LibraryService/GetAlbum"); 727 + let path = http::uri::PathAndQuery::from_static( 728 + "/rockbox.v1alpha1.LibraryService/GetAlbum", 729 + ); 675 730 let mut req = request.into_request(); 676 - req.extensions_mut().insert(GrpcMethod::new( 677 - "rockbox.v1alpha1.LibraryService", 678 - "GetAlbum", 679 - )); 731 + req.extensions_mut() 732 + .insert(GrpcMethod::new("rockbox.v1alpha1.LibraryService", "GetAlbum")); 680 733 self.inner.unary(req, path, codec).await 681 734 } 682 735 pub async fn get_artist( 683 736 &mut self, 684 737 request: impl tonic::IntoRequest<super::GetArtistRequest>, 685 - ) -> std::result::Result<tonic::Response<super::GetArtistResponse>, tonic::Status> { 686 - self.inner.ready().await.map_err(|e| { 687 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 688 - })?; 738 + ) -> std::result::Result< 739 + tonic::Response<super::GetArtistResponse>, 740 + tonic::Status, 741 + > { 742 + self.inner 743 + .ready() 744 + .await 745 + .map_err(|e| { 746 + tonic::Status::unknown( 747 + format!("Service was not ready: {}", e.into()), 748 + ) 749 + })?; 689 750 let codec = tonic::codec::ProstCodec::default(); 690 - let path = 691 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.LibraryService/GetArtist"); 751 + let path = http::uri::PathAndQuery::from_static( 752 + "/rockbox.v1alpha1.LibraryService/GetArtist", 753 + ); 692 754 let mut req = request.into_request(); 693 - req.extensions_mut().insert(GrpcMethod::new( 694 - "rockbox.v1alpha1.LibraryService", 695 - "GetArtist", 696 - )); 755 + req.extensions_mut() 756 + .insert(GrpcMethod::new("rockbox.v1alpha1.LibraryService", "GetArtist")); 697 757 self.inner.unary(req, path, codec).await 698 758 } 699 759 pub async fn get_track( 700 760 &mut self, 701 761 request: impl tonic::IntoRequest<super::GetTrackRequest>, 702 - ) -> std::result::Result<tonic::Response<super::GetTrackResponse>, tonic::Status> { 703 - self.inner.ready().await.map_err(|e| { 704 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 705 - })?; 762 + ) -> std::result::Result< 763 + tonic::Response<super::GetTrackResponse>, 764 + tonic::Status, 765 + > { 766 + self.inner 767 + .ready() 768 + .await 769 + .map_err(|e| { 770 + tonic::Status::unknown( 771 + format!("Service was not ready: {}", e.into()), 772 + ) 773 + })?; 706 774 let codec = tonic::codec::ProstCodec::default(); 707 - let path = 708 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.LibraryService/GetTrack"); 775 + let path = http::uri::PathAndQuery::from_static( 776 + "/rockbox.v1alpha1.LibraryService/GetTrack", 777 + ); 709 778 let mut req = request.into_request(); 710 - req.extensions_mut().insert(GrpcMethod::new( 711 - "rockbox.v1alpha1.LibraryService", 712 - "GetTrack", 713 - )); 779 + req.extensions_mut() 780 + .insert(GrpcMethod::new("rockbox.v1alpha1.LibraryService", "GetTrack")); 714 781 self.inner.unary(req, path, codec).await 715 782 } 716 783 pub async fn like_track( 717 784 &mut self, 718 785 request: impl tonic::IntoRequest<super::LikeTrackRequest>, 719 - ) -> std::result::Result<tonic::Response<super::LikeTrackResponse>, tonic::Status> { 720 - self.inner.ready().await.map_err(|e| { 721 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 722 - })?; 786 + ) -> std::result::Result< 787 + tonic::Response<super::LikeTrackResponse>, 788 + tonic::Status, 789 + > { 790 + self.inner 791 + .ready() 792 + .await 793 + .map_err(|e| { 794 + tonic::Status::unknown( 795 + format!("Service was not ready: {}", e.into()), 796 + ) 797 + })?; 723 798 let codec = tonic::codec::ProstCodec::default(); 724 - let path = 725 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.LibraryService/LikeTrack"); 799 + let path = http::uri::PathAndQuery::from_static( 800 + "/rockbox.v1alpha1.LibraryService/LikeTrack", 801 + ); 726 802 let mut req = request.into_request(); 727 - req.extensions_mut().insert(GrpcMethod::new( 728 - "rockbox.v1alpha1.LibraryService", 729 - "LikeTrack", 730 - )); 803 + req.extensions_mut() 804 + .insert(GrpcMethod::new("rockbox.v1alpha1.LibraryService", "LikeTrack")); 731 805 self.inner.unary(req, path, codec).await 732 806 } 733 807 pub async fn unlike_track( 734 808 &mut self, 735 809 request: impl tonic::IntoRequest<super::UnlikeTrackRequest>, 736 - ) -> std::result::Result<tonic::Response<super::UnlikeTrackResponse>, tonic::Status> 737 - { 738 - self.inner.ready().await.map_err(|e| { 739 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 740 - })?; 810 + ) -> std::result::Result< 811 + tonic::Response<super::UnlikeTrackResponse>, 812 + tonic::Status, 813 + > { 814 + self.inner 815 + .ready() 816 + .await 817 + .map_err(|e| { 818 + tonic::Status::unknown( 819 + format!("Service was not ready: {}", e.into()), 820 + ) 821 + })?; 741 822 let codec = tonic::codec::ProstCodec::default(); 742 823 let path = http::uri::PathAndQuery::from_static( 743 824 "/rockbox.v1alpha1.LibraryService/UnlikeTrack", 744 825 ); 745 826 let mut req = request.into_request(); 746 - req.extensions_mut().insert(GrpcMethod::new( 747 - "rockbox.v1alpha1.LibraryService", 748 - "UnlikeTrack", 749 - )); 827 + req.extensions_mut() 828 + .insert( 829 + GrpcMethod::new("rockbox.v1alpha1.LibraryService", "UnlikeTrack"), 830 + ); 750 831 self.inner.unary(req, path, codec).await 751 832 } 752 833 pub async fn like_album( 753 834 &mut self, 754 835 request: impl tonic::IntoRequest<super::LikeAlbumRequest>, 755 - ) -> std::result::Result<tonic::Response<super::LikeAlbumResponse>, tonic::Status> { 756 - self.inner.ready().await.map_err(|e| { 757 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 758 - })?; 836 + ) -> std::result::Result< 837 + tonic::Response<super::LikeAlbumResponse>, 838 + tonic::Status, 839 + > { 840 + self.inner 841 + .ready() 842 + .await 843 + .map_err(|e| { 844 + tonic::Status::unknown( 845 + format!("Service was not ready: {}", e.into()), 846 + ) 847 + })?; 759 848 let codec = tonic::codec::ProstCodec::default(); 760 - let path = 761 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.LibraryService/LikeAlbum"); 849 + let path = http::uri::PathAndQuery::from_static( 850 + "/rockbox.v1alpha1.LibraryService/LikeAlbum", 851 + ); 762 852 let mut req = request.into_request(); 763 - req.extensions_mut().insert(GrpcMethod::new( 764 - "rockbox.v1alpha1.LibraryService", 765 - "LikeAlbum", 766 - )); 853 + req.extensions_mut() 854 + .insert(GrpcMethod::new("rockbox.v1alpha1.LibraryService", "LikeAlbum")); 767 855 self.inner.unary(req, path, codec).await 768 856 } 769 857 pub async fn unlike_album( 770 858 &mut self, 771 859 request: impl tonic::IntoRequest<super::UnlikeAlbumRequest>, 772 - ) -> std::result::Result<tonic::Response<super::UnlikeAlbumResponse>, tonic::Status> 773 - { 774 - self.inner.ready().await.map_err(|e| { 775 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 776 - })?; 860 + ) -> std::result::Result< 861 + tonic::Response<super::UnlikeAlbumResponse>, 862 + tonic::Status, 863 + > { 864 + self.inner 865 + .ready() 866 + .await 867 + .map_err(|e| { 868 + tonic::Status::unknown( 869 + format!("Service was not ready: {}", e.into()), 870 + ) 871 + })?; 777 872 let codec = tonic::codec::ProstCodec::default(); 778 873 let path = http::uri::PathAndQuery::from_static( 779 874 "/rockbox.v1alpha1.LibraryService/UnlikeAlbum", 780 875 ); 781 876 let mut req = request.into_request(); 782 - req.extensions_mut().insert(GrpcMethod::new( 783 - "rockbox.v1alpha1.LibraryService", 784 - "UnlikeAlbum", 785 - )); 877 + req.extensions_mut() 878 + .insert( 879 + GrpcMethod::new("rockbox.v1alpha1.LibraryService", "UnlikeAlbum"), 880 + ); 786 881 self.inner.unary(req, path, codec).await 787 882 } 788 883 pub async fn get_liked_tracks( 789 884 &mut self, 790 885 request: impl tonic::IntoRequest<super::GetLikedTracksRequest>, 791 - ) -> std::result::Result<tonic::Response<super::GetLikedTracksResponse>, tonic::Status> 792 - { 793 - self.inner.ready().await.map_err(|e| { 794 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 795 - })?; 886 + ) -> std::result::Result< 887 + tonic::Response<super::GetLikedTracksResponse>, 888 + tonic::Status, 889 + > { 890 + self.inner 891 + .ready() 892 + .await 893 + .map_err(|e| { 894 + tonic::Status::unknown( 895 + format!("Service was not ready: {}", e.into()), 896 + ) 897 + })?; 796 898 let codec = tonic::codec::ProstCodec::default(); 797 899 let path = http::uri::PathAndQuery::from_static( 798 900 "/rockbox.v1alpha1.LibraryService/GetLikedTracks", 799 901 ); 800 902 let mut req = request.into_request(); 801 - req.extensions_mut().insert(GrpcMethod::new( 802 - "rockbox.v1alpha1.LibraryService", 803 - "GetLikedTracks", 804 - )); 903 + req.extensions_mut() 904 + .insert( 905 + GrpcMethod::new("rockbox.v1alpha1.LibraryService", "GetLikedTracks"), 906 + ); 805 907 self.inner.unary(req, path, codec).await 806 908 } 807 909 pub async fn get_liked_albums( 808 910 &mut self, 809 911 request: impl tonic::IntoRequest<super::GetLikedAlbumsRequest>, 810 - ) -> std::result::Result<tonic::Response<super::GetLikedAlbumsResponse>, tonic::Status> 811 - { 812 - self.inner.ready().await.map_err(|e| { 813 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 814 - })?; 912 + ) -> std::result::Result< 913 + tonic::Response<super::GetLikedAlbumsResponse>, 914 + tonic::Status, 915 + > { 916 + self.inner 917 + .ready() 918 + .await 919 + .map_err(|e| { 920 + tonic::Status::unknown( 921 + format!("Service was not ready: {}", e.into()), 922 + ) 923 + })?; 815 924 let codec = tonic::codec::ProstCodec::default(); 816 925 let path = http::uri::PathAndQuery::from_static( 817 926 "/rockbox.v1alpha1.LibraryService/GetLikedAlbums", 818 927 ); 819 928 let mut req = request.into_request(); 820 - req.extensions_mut().insert(GrpcMethod::new( 821 - "rockbox.v1alpha1.LibraryService", 822 - "GetLikedAlbums", 823 - )); 929 + req.extensions_mut() 930 + .insert( 931 + GrpcMethod::new("rockbox.v1alpha1.LibraryService", "GetLikedAlbums"), 932 + ); 824 933 self.inner.unary(req, path, codec).await 825 934 } 826 935 pub async fn scan_library( 827 936 &mut self, 828 937 request: impl tonic::IntoRequest<super::ScanLibraryRequest>, 829 - ) -> std::result::Result<tonic::Response<super::ScanLibraryResponse>, tonic::Status> 830 - { 831 - self.inner.ready().await.map_err(|e| { 832 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 833 - })?; 938 + ) -> std::result::Result< 939 + tonic::Response<super::ScanLibraryResponse>, 940 + tonic::Status, 941 + > { 942 + self.inner 943 + .ready() 944 + .await 945 + .map_err(|e| { 946 + tonic::Status::unknown( 947 + format!("Service was not ready: {}", e.into()), 948 + ) 949 + })?; 834 950 let codec = tonic::codec::ProstCodec::default(); 835 951 let path = http::uri::PathAndQuery::from_static( 836 952 "/rockbox.v1alpha1.LibraryService/ScanLibrary", 837 953 ); 838 954 let mut req = request.into_request(); 839 - req.extensions_mut().insert(GrpcMethod::new( 840 - "rockbox.v1alpha1.LibraryService", 841 - "ScanLibrary", 842 - )); 955 + req.extensions_mut() 956 + .insert( 957 + GrpcMethod::new("rockbox.v1alpha1.LibraryService", "ScanLibrary"), 958 + ); 843 959 self.inner.unary(req, path, codec).await 844 960 } 845 961 pub async fn search( 846 962 &mut self, 847 963 request: impl tonic::IntoRequest<super::SearchRequest>, 848 964 ) -> std::result::Result<tonic::Response<super::SearchResponse>, tonic::Status> { 849 - self.inner.ready().await.map_err(|e| { 850 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 851 - })?; 965 + self.inner 966 + .ready() 967 + .await 968 + .map_err(|e| { 969 + tonic::Status::unknown( 970 + format!("Service was not ready: {}", e.into()), 971 + ) 972 + })?; 852 973 let codec = tonic::codec::ProstCodec::default(); 853 - let path = 854 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.LibraryService/Search"); 974 + let path = http::uri::PathAndQuery::from_static( 975 + "/rockbox.v1alpha1.LibraryService/Search", 976 + ); 855 977 let mut req = request.into_request(); 856 978 req.extensions_mut() 857 979 .insert(GrpcMethod::new("rockbox.v1alpha1.LibraryService", "Search")); ··· 866 988 dead_code, 867 989 missing_docs, 868 990 clippy::wildcard_imports, 869 - clippy::let_unit_value 991 + clippy::let_unit_value, 870 992 )] 871 993 use tonic::codegen::*; 872 994 /// Generated trait containing gRPC methods that should be implemented for use with LibraryServiceServer. ··· 875 997 async fn get_albums( 876 998 &self, 877 999 request: tonic::Request<super::GetAlbumsRequest>, 878 - ) -> std::result::Result<tonic::Response<super::GetAlbumsResponse>, tonic::Status>; 1000 + ) -> std::result::Result< 1001 + tonic::Response<super::GetAlbumsResponse>, 1002 + tonic::Status, 1003 + >; 879 1004 async fn get_artists( 880 1005 &self, 881 1006 request: tonic::Request<super::GetArtistsRequest>, 882 - ) -> std::result::Result<tonic::Response<super::GetArtistsResponse>, tonic::Status>; 1007 + ) -> std::result::Result< 1008 + tonic::Response<super::GetArtistsResponse>, 1009 + tonic::Status, 1010 + >; 883 1011 async fn get_tracks( 884 1012 &self, 885 1013 request: tonic::Request<super::GetTracksRequest>, 886 - ) -> std::result::Result<tonic::Response<super::GetTracksResponse>, tonic::Status>; 1014 + ) -> std::result::Result< 1015 + tonic::Response<super::GetTracksResponse>, 1016 + tonic::Status, 1017 + >; 887 1018 async fn get_album( 888 1019 &self, 889 1020 request: tonic::Request<super::GetAlbumRequest>, 890 - ) -> std::result::Result<tonic::Response<super::GetAlbumResponse>, tonic::Status>; 1021 + ) -> std::result::Result< 1022 + tonic::Response<super::GetAlbumResponse>, 1023 + tonic::Status, 1024 + >; 891 1025 async fn get_artist( 892 1026 &self, 893 1027 request: tonic::Request<super::GetArtistRequest>, 894 - ) -> std::result::Result<tonic::Response<super::GetArtistResponse>, tonic::Status>; 1028 + ) -> std::result::Result< 1029 + tonic::Response<super::GetArtistResponse>, 1030 + tonic::Status, 1031 + >; 895 1032 async fn get_track( 896 1033 &self, 897 1034 request: tonic::Request<super::GetTrackRequest>, 898 - ) -> std::result::Result<tonic::Response<super::GetTrackResponse>, tonic::Status>; 1035 + ) -> std::result::Result< 1036 + tonic::Response<super::GetTrackResponse>, 1037 + tonic::Status, 1038 + >; 899 1039 async fn like_track( 900 1040 &self, 901 1041 request: tonic::Request<super::LikeTrackRequest>, 902 - ) -> std::result::Result<tonic::Response<super::LikeTrackResponse>, tonic::Status>; 1042 + ) -> std::result::Result< 1043 + tonic::Response<super::LikeTrackResponse>, 1044 + tonic::Status, 1045 + >; 903 1046 async fn unlike_track( 904 1047 &self, 905 1048 request: tonic::Request<super::UnlikeTrackRequest>, 906 - ) -> std::result::Result<tonic::Response<super::UnlikeTrackResponse>, tonic::Status>; 1049 + ) -> std::result::Result< 1050 + tonic::Response<super::UnlikeTrackResponse>, 1051 + tonic::Status, 1052 + >; 907 1053 async fn like_album( 908 1054 &self, 909 1055 request: tonic::Request<super::LikeAlbumRequest>, 910 - ) -> std::result::Result<tonic::Response<super::LikeAlbumResponse>, tonic::Status>; 1056 + ) -> std::result::Result< 1057 + tonic::Response<super::LikeAlbumResponse>, 1058 + tonic::Status, 1059 + >; 911 1060 async fn unlike_album( 912 1061 &self, 913 1062 request: tonic::Request<super::UnlikeAlbumRequest>, 914 - ) -> std::result::Result<tonic::Response<super::UnlikeAlbumResponse>, tonic::Status>; 1063 + ) -> std::result::Result< 1064 + tonic::Response<super::UnlikeAlbumResponse>, 1065 + tonic::Status, 1066 + >; 915 1067 async fn get_liked_tracks( 916 1068 &self, 917 1069 request: tonic::Request<super::GetLikedTracksRequest>, 918 - ) -> std::result::Result<tonic::Response<super::GetLikedTracksResponse>, tonic::Status>; 1070 + ) -> std::result::Result< 1071 + tonic::Response<super::GetLikedTracksResponse>, 1072 + tonic::Status, 1073 + >; 919 1074 async fn get_liked_albums( 920 1075 &self, 921 1076 request: tonic::Request<super::GetLikedAlbumsRequest>, 922 - ) -> std::result::Result<tonic::Response<super::GetLikedAlbumsResponse>, tonic::Status>; 1077 + ) -> std::result::Result< 1078 + tonic::Response<super::GetLikedAlbumsResponse>, 1079 + tonic::Status, 1080 + >; 923 1081 async fn scan_library( 924 1082 &self, 925 1083 request: tonic::Request<super::ScanLibraryRequest>, 926 - ) -> std::result::Result<tonic::Response<super::ScanLibraryResponse>, tonic::Status>; 1084 + ) -> std::result::Result< 1085 + tonic::Response<super::ScanLibraryResponse>, 1086 + tonic::Status, 1087 + >; 927 1088 async fn search( 928 1089 &self, 929 1090 request: tonic::Request<super::SearchRequest>, ··· 950 1111 max_encoding_message_size: None, 951 1112 } 952 1113 } 953 - pub fn with_interceptor<F>(inner: T, interceptor: F) -> InterceptedService<Self, F> 1114 + pub fn with_interceptor<F>( 1115 + inner: T, 1116 + interceptor: F, 1117 + ) -> InterceptedService<Self, F> 954 1118 where 955 1119 F: tonic::service::Interceptor, 956 1120 { ··· 1005 1169 "/rockbox.v1alpha1.LibraryService/GetAlbums" => { 1006 1170 #[allow(non_camel_case_types)] 1007 1171 struct GetAlbumsSvc<T: LibraryService>(pub Arc<T>); 1008 - impl<T: LibraryService> tonic::server::UnaryService<super::GetAlbumsRequest> for GetAlbumsSvc<T> { 1172 + impl< 1173 + T: LibraryService, 1174 + > tonic::server::UnaryService<super::GetAlbumsRequest> 1175 + for GetAlbumsSvc<T> { 1009 1176 type Response = super::GetAlbumsResponse; 1010 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1177 + type Future = BoxFuture< 1178 + tonic::Response<Self::Response>, 1179 + tonic::Status, 1180 + >; 1011 1181 fn call( 1012 1182 &mut self, 1013 1183 request: tonic::Request<super::GetAlbumsRequest>, ··· 1044 1214 "/rockbox.v1alpha1.LibraryService/GetArtists" => { 1045 1215 #[allow(non_camel_case_types)] 1046 1216 struct GetArtistsSvc<T: LibraryService>(pub Arc<T>); 1047 - impl<T: LibraryService> tonic::server::UnaryService<super::GetArtistsRequest> for GetArtistsSvc<T> { 1217 + impl< 1218 + T: LibraryService, 1219 + > tonic::server::UnaryService<super::GetArtistsRequest> 1220 + for GetArtistsSvc<T> { 1048 1221 type Response = super::GetArtistsResponse; 1049 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1222 + type Future = BoxFuture< 1223 + tonic::Response<Self::Response>, 1224 + tonic::Status, 1225 + >; 1050 1226 fn call( 1051 1227 &mut self, 1052 1228 request: tonic::Request<super::GetArtistsRequest>, ··· 1083 1259 "/rockbox.v1alpha1.LibraryService/GetTracks" => { 1084 1260 #[allow(non_camel_case_types)] 1085 1261 struct GetTracksSvc<T: LibraryService>(pub Arc<T>); 1086 - impl<T: LibraryService> tonic::server::UnaryService<super::GetTracksRequest> for GetTracksSvc<T> { 1262 + impl< 1263 + T: LibraryService, 1264 + > tonic::server::UnaryService<super::GetTracksRequest> 1265 + for GetTracksSvc<T> { 1087 1266 type Response = super::GetTracksResponse; 1088 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1267 + type Future = BoxFuture< 1268 + tonic::Response<Self::Response>, 1269 + tonic::Status, 1270 + >; 1089 1271 fn call( 1090 1272 &mut self, 1091 1273 request: tonic::Request<super::GetTracksRequest>, ··· 1122 1304 "/rockbox.v1alpha1.LibraryService/GetAlbum" => { 1123 1305 #[allow(non_camel_case_types)] 1124 1306 struct GetAlbumSvc<T: LibraryService>(pub Arc<T>); 1125 - impl<T: LibraryService> tonic::server::UnaryService<super::GetAlbumRequest> for GetAlbumSvc<T> { 1307 + impl< 1308 + T: LibraryService, 1309 + > tonic::server::UnaryService<super::GetAlbumRequest> 1310 + for GetAlbumSvc<T> { 1126 1311 type Response = super::GetAlbumResponse; 1127 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1312 + type Future = BoxFuture< 1313 + tonic::Response<Self::Response>, 1314 + tonic::Status, 1315 + >; 1128 1316 fn call( 1129 1317 &mut self, 1130 1318 request: tonic::Request<super::GetAlbumRequest>, ··· 1161 1349 "/rockbox.v1alpha1.LibraryService/GetArtist" => { 1162 1350 #[allow(non_camel_case_types)] 1163 1351 struct GetArtistSvc<T: LibraryService>(pub Arc<T>); 1164 - impl<T: LibraryService> tonic::server::UnaryService<super::GetArtistRequest> for GetArtistSvc<T> { 1352 + impl< 1353 + T: LibraryService, 1354 + > tonic::server::UnaryService<super::GetArtistRequest> 1355 + for GetArtistSvc<T> { 1165 1356 type Response = super::GetArtistResponse; 1166 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1357 + type Future = BoxFuture< 1358 + tonic::Response<Self::Response>, 1359 + tonic::Status, 1360 + >; 1167 1361 fn call( 1168 1362 &mut self, 1169 1363 request: tonic::Request<super::GetArtistRequest>, ··· 1200 1394 "/rockbox.v1alpha1.LibraryService/GetTrack" => { 1201 1395 #[allow(non_camel_case_types)] 1202 1396 struct GetTrackSvc<T: LibraryService>(pub Arc<T>); 1203 - impl<T: LibraryService> tonic::server::UnaryService<super::GetTrackRequest> for GetTrackSvc<T> { 1397 + impl< 1398 + T: LibraryService, 1399 + > tonic::server::UnaryService<super::GetTrackRequest> 1400 + for GetTrackSvc<T> { 1204 1401 type Response = super::GetTrackResponse; 1205 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1402 + type Future = BoxFuture< 1403 + tonic::Response<Self::Response>, 1404 + tonic::Status, 1405 + >; 1206 1406 fn call( 1207 1407 &mut self, 1208 1408 request: tonic::Request<super::GetTrackRequest>, ··· 1239 1439 "/rockbox.v1alpha1.LibraryService/LikeTrack" => { 1240 1440 #[allow(non_camel_case_types)] 1241 1441 struct LikeTrackSvc<T: LibraryService>(pub Arc<T>); 1242 - impl<T: LibraryService> tonic::server::UnaryService<super::LikeTrackRequest> for LikeTrackSvc<T> { 1442 + impl< 1443 + T: LibraryService, 1444 + > tonic::server::UnaryService<super::LikeTrackRequest> 1445 + for LikeTrackSvc<T> { 1243 1446 type Response = super::LikeTrackResponse; 1244 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1447 + type Future = BoxFuture< 1448 + tonic::Response<Self::Response>, 1449 + tonic::Status, 1450 + >; 1245 1451 fn call( 1246 1452 &mut self, 1247 1453 request: tonic::Request<super::LikeTrackRequest>, ··· 1278 1484 "/rockbox.v1alpha1.LibraryService/UnlikeTrack" => { 1279 1485 #[allow(non_camel_case_types)] 1280 1486 struct UnlikeTrackSvc<T: LibraryService>(pub Arc<T>); 1281 - impl<T: LibraryService> tonic::server::UnaryService<super::UnlikeTrackRequest> 1282 - for UnlikeTrackSvc<T> 1283 - { 1487 + impl< 1488 + T: LibraryService, 1489 + > tonic::server::UnaryService<super::UnlikeTrackRequest> 1490 + for UnlikeTrackSvc<T> { 1284 1491 type Response = super::UnlikeTrackResponse; 1285 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1492 + type Future = BoxFuture< 1493 + tonic::Response<Self::Response>, 1494 + tonic::Status, 1495 + >; 1286 1496 fn call( 1287 1497 &mut self, 1288 1498 request: tonic::Request<super::UnlikeTrackRequest>, ··· 1319 1529 "/rockbox.v1alpha1.LibraryService/LikeAlbum" => { 1320 1530 #[allow(non_camel_case_types)] 1321 1531 struct LikeAlbumSvc<T: LibraryService>(pub Arc<T>); 1322 - impl<T: LibraryService> tonic::server::UnaryService<super::LikeAlbumRequest> for LikeAlbumSvc<T> { 1532 + impl< 1533 + T: LibraryService, 1534 + > tonic::server::UnaryService<super::LikeAlbumRequest> 1535 + for LikeAlbumSvc<T> { 1323 1536 type Response = super::LikeAlbumResponse; 1324 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1537 + type Future = BoxFuture< 1538 + tonic::Response<Self::Response>, 1539 + tonic::Status, 1540 + >; 1325 1541 fn call( 1326 1542 &mut self, 1327 1543 request: tonic::Request<super::LikeAlbumRequest>, ··· 1358 1574 "/rockbox.v1alpha1.LibraryService/UnlikeAlbum" => { 1359 1575 #[allow(non_camel_case_types)] 1360 1576 struct UnlikeAlbumSvc<T: LibraryService>(pub Arc<T>); 1361 - impl<T: LibraryService> tonic::server::UnaryService<super::UnlikeAlbumRequest> 1362 - for UnlikeAlbumSvc<T> 1363 - { 1577 + impl< 1578 + T: LibraryService, 1579 + > tonic::server::UnaryService<super::UnlikeAlbumRequest> 1580 + for UnlikeAlbumSvc<T> { 1364 1581 type Response = super::UnlikeAlbumResponse; 1365 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1582 + type Future = BoxFuture< 1583 + tonic::Response<Self::Response>, 1584 + tonic::Status, 1585 + >; 1366 1586 fn call( 1367 1587 &mut self, 1368 1588 request: tonic::Request<super::UnlikeAlbumRequest>, ··· 1399 1619 "/rockbox.v1alpha1.LibraryService/GetLikedTracks" => { 1400 1620 #[allow(non_camel_case_types)] 1401 1621 struct GetLikedTracksSvc<T: LibraryService>(pub Arc<T>); 1402 - impl<T: LibraryService> 1403 - tonic::server::UnaryService<super::GetLikedTracksRequest> 1404 - for GetLikedTracksSvc<T> 1405 - { 1622 + impl< 1623 + T: LibraryService, 1624 + > tonic::server::UnaryService<super::GetLikedTracksRequest> 1625 + for GetLikedTracksSvc<T> { 1406 1626 type Response = super::GetLikedTracksResponse; 1407 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1627 + type Future = BoxFuture< 1628 + tonic::Response<Self::Response>, 1629 + tonic::Status, 1630 + >; 1408 1631 fn call( 1409 1632 &mut self, 1410 1633 request: tonic::Request<super::GetLikedTracksRequest>, 1411 1634 ) -> Self::Future { 1412 1635 let inner = Arc::clone(&self.0); 1413 1636 let fut = async move { 1414 - <T as LibraryService>::get_liked_tracks(&inner, request).await 1637 + <T as LibraryService>::get_liked_tracks(&inner, request) 1638 + .await 1415 1639 }; 1416 1640 Box::pin(fut) 1417 1641 } ··· 1441 1665 "/rockbox.v1alpha1.LibraryService/GetLikedAlbums" => { 1442 1666 #[allow(non_camel_case_types)] 1443 1667 struct GetLikedAlbumsSvc<T: LibraryService>(pub Arc<T>); 1444 - impl<T: LibraryService> 1445 - tonic::server::UnaryService<super::GetLikedAlbumsRequest> 1446 - for GetLikedAlbumsSvc<T> 1447 - { 1668 + impl< 1669 + T: LibraryService, 1670 + > tonic::server::UnaryService<super::GetLikedAlbumsRequest> 1671 + for GetLikedAlbumsSvc<T> { 1448 1672 type Response = super::GetLikedAlbumsResponse; 1449 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1673 + type Future = BoxFuture< 1674 + tonic::Response<Self::Response>, 1675 + tonic::Status, 1676 + >; 1450 1677 fn call( 1451 1678 &mut self, 1452 1679 request: tonic::Request<super::GetLikedAlbumsRequest>, 1453 1680 ) -> Self::Future { 1454 1681 let inner = Arc::clone(&self.0); 1455 1682 let fut = async move { 1456 - <T as LibraryService>::get_liked_albums(&inner, request).await 1683 + <T as LibraryService>::get_liked_albums(&inner, request) 1684 + .await 1457 1685 }; 1458 1686 Box::pin(fut) 1459 1687 } ··· 1483 1711 "/rockbox.v1alpha1.LibraryService/ScanLibrary" => { 1484 1712 #[allow(non_camel_case_types)] 1485 1713 struct ScanLibrarySvc<T: LibraryService>(pub Arc<T>); 1486 - impl<T: LibraryService> tonic::server::UnaryService<super::ScanLibraryRequest> 1487 - for ScanLibrarySvc<T> 1488 - { 1714 + impl< 1715 + T: LibraryService, 1716 + > tonic::server::UnaryService<super::ScanLibraryRequest> 1717 + for ScanLibrarySvc<T> { 1489 1718 type Response = super::ScanLibraryResponse; 1490 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1719 + type Future = BoxFuture< 1720 + tonic::Response<Self::Response>, 1721 + tonic::Status, 1722 + >; 1491 1723 fn call( 1492 1724 &mut self, 1493 1725 request: tonic::Request<super::ScanLibraryRequest>, ··· 1524 1756 "/rockbox.v1alpha1.LibraryService/Search" => { 1525 1757 #[allow(non_camel_case_types)] 1526 1758 struct SearchSvc<T: LibraryService>(pub Arc<T>); 1527 - impl<T: LibraryService> tonic::server::UnaryService<super::SearchRequest> for SearchSvc<T> { 1759 + impl< 1760 + T: LibraryService, 1761 + > tonic::server::UnaryService<super::SearchRequest> 1762 + for SearchSvc<T> { 1528 1763 type Response = super::SearchResponse; 1529 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1764 + type Future = BoxFuture< 1765 + tonic::Response<Self::Response>, 1766 + tonic::Status, 1767 + >; 1530 1768 fn call( 1531 1769 &mut self, 1532 1770 request: tonic::Request<super::SearchRequest>, 1533 1771 ) -> Self::Future { 1534 1772 let inner = Arc::clone(&self.0); 1535 - let fut = 1536 - async move { <T as LibraryService>::search(&inner, request).await }; 1773 + let fut = async move { 1774 + <T as LibraryService>::search(&inner, request).await 1775 + }; 1537 1776 Box::pin(fut) 1538 1777 } 1539 1778 } ··· 1559 1798 }; 1560 1799 Box::pin(fut) 1561 1800 } 1562 - _ => Box::pin(async move { 1563 - let mut response = http::Response::new(empty_body()); 1564 - let headers = response.headers_mut(); 1565 - headers.insert( 1566 - tonic::Status::GRPC_STATUS, 1567 - (tonic::Code::Unimplemented as i32).into(), 1568 - ); 1569 - headers.insert( 1570 - http::header::CONTENT_TYPE, 1571 - tonic::metadata::GRPC_CONTENT_TYPE, 1572 - ); 1573 - Ok(response) 1574 - }), 1801 + _ => { 1802 + Box::pin(async move { 1803 + let mut response = http::Response::new(empty_body()); 1804 + let headers = response.headers_mut(); 1805 + headers 1806 + .insert( 1807 + tonic::Status::GRPC_STATUS, 1808 + (tonic::Code::Unimplemented as i32).into(), 1809 + ); 1810 + headers 1811 + .insert( 1812 + http::header::CONTENT_TYPE, 1813 + tonic::metadata::GRPC_CONTENT_TYPE, 1814 + ); 1815 + Ok(response) 1816 + }) 1817 + } 1575 1818 } 1576 1819 } 1577 1820 } ··· 1600 1843 dead_code, 1601 1844 missing_docs, 1602 1845 clippy::wildcard_imports, 1603 - clippy::let_unit_value 1846 + clippy::let_unit_value, 1604 1847 )] 1605 - use tonic::codegen::http::Uri; 1606 1848 use tonic::codegen::*; 1849 + use tonic::codegen::http::Uri; 1607 1850 #[derive(Debug, Clone)] 1608 1851 pub struct MetadataServiceClient<T> { 1609 1852 inner: tonic::client::Grpc<T>, ··· 1647 1890 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody, 1648 1891 >, 1649 1892 >, 1650 - <T as tonic::codegen::Service<http::Request<tonic::body::BoxBody>>>::Error: 1651 - Into<StdError> + std::marker::Send + std::marker::Sync, 1893 + <T as tonic::codegen::Service< 1894 + http::Request<tonic::body::BoxBody>, 1895 + >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync, 1652 1896 { 1653 1897 MetadataServiceClient::new(InterceptedService::new(inner, interceptor)) 1654 1898 } ··· 1692 1936 dead_code, 1693 1937 missing_docs, 1694 1938 clippy::wildcard_imports, 1695 - clippy::let_unit_value 1939 + clippy::let_unit_value, 1696 1940 )] 1697 1941 use tonic::codegen::*; 1698 1942 /// Generated trait containing gRPC methods that should be implemented for use with MetadataServiceServer. ··· 1719 1963 max_encoding_message_size: None, 1720 1964 } 1721 1965 } 1722 - pub fn with_interceptor<F>(inner: T, interceptor: F) -> InterceptedService<Self, F> 1966 + pub fn with_interceptor<F>( 1967 + inner: T, 1968 + interceptor: F, 1969 + ) -> InterceptedService<Self, F> 1723 1970 where 1724 1971 F: tonic::service::Interceptor, 1725 1972 { ··· 1771 2018 } 1772 2019 fn call(&mut self, req: http::Request<B>) -> Self::Future { 1773 2020 match req.uri().path() { 1774 - _ => Box::pin(async move { 1775 - let mut response = http::Response::new(empty_body()); 1776 - let headers = response.headers_mut(); 1777 - headers.insert( 1778 - tonic::Status::GRPC_STATUS, 1779 - (tonic::Code::Unimplemented as i32).into(), 1780 - ); 1781 - headers.insert( 1782 - http::header::CONTENT_TYPE, 1783 - tonic::metadata::GRPC_CONTENT_TYPE, 1784 - ); 1785 - Ok(response) 1786 - }), 2021 + _ => { 2022 + Box::pin(async move { 2023 + let mut response = http::Response::new(empty_body()); 2024 + let headers = response.headers_mut(); 2025 + headers 2026 + .insert( 2027 + tonic::Status::GRPC_STATUS, 2028 + (tonic::Code::Unimplemented as i32).into(), 2029 + ); 2030 + headers 2031 + .insert( 2032 + http::header::CONTENT_TYPE, 2033 + tonic::metadata::GRPC_CONTENT_TYPE, 2034 + ); 2035 + Ok(response) 2036 + }) 2037 + } 1787 2038 } 1788 2039 } 1789 2040 } ··· 2067 2318 dead_code, 2068 2319 missing_docs, 2069 2320 clippy::wildcard_imports, 2070 - clippy::let_unit_value 2321 + clippy::let_unit_value, 2071 2322 )] 2072 - use tonic::codegen::http::Uri; 2073 2323 use tonic::codegen::*; 2324 + use tonic::codegen::http::Uri; 2074 2325 #[derive(Debug, Clone)] 2075 2326 pub struct PlaybackServiceClient<T> { 2076 2327 inner: tonic::client::Grpc<T>, ··· 2114 2365 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody, 2115 2366 >, 2116 2367 >, 2117 - <T as tonic::codegen::Service<http::Request<tonic::body::BoxBody>>>::Error: 2118 - Into<StdError> + std::marker::Send + std::marker::Sync, 2368 + <T as tonic::codegen::Service< 2369 + http::Request<tonic::body::BoxBody>, 2370 + >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync, 2119 2371 { 2120 2372 PlaybackServiceClient::new(InterceptedService::new(inner, interceptor)) 2121 2373 } ··· 2154 2406 &mut self, 2155 2407 request: impl tonic::IntoRequest<super::PlayRequest>, 2156 2408 ) -> std::result::Result<tonic::Response<super::PlayResponse>, tonic::Status> { 2157 - self.inner.ready().await.map_err(|e| { 2158 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2159 - })?; 2409 + self.inner 2410 + .ready() 2411 + .await 2412 + .map_err(|e| { 2413 + tonic::Status::unknown( 2414 + format!("Service was not ready: {}", e.into()), 2415 + ) 2416 + })?; 2160 2417 let codec = tonic::codec::ProstCodec::default(); 2161 - let path = 2162 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/Play"); 2418 + let path = http::uri::PathAndQuery::from_static( 2419 + "/rockbox.v1alpha1.PlaybackService/Play", 2420 + ); 2163 2421 let mut req = request.into_request(); 2164 2422 req.extensions_mut() 2165 2423 .insert(GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "Play")); ··· 2169 2427 &mut self, 2170 2428 request: impl tonic::IntoRequest<super::PauseRequest>, 2171 2429 ) -> std::result::Result<tonic::Response<super::PauseResponse>, tonic::Status> { 2172 - self.inner.ready().await.map_err(|e| { 2173 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2174 - })?; 2430 + self.inner 2431 + .ready() 2432 + .await 2433 + .map_err(|e| { 2434 + tonic::Status::unknown( 2435 + format!("Service was not ready: {}", e.into()), 2436 + ) 2437 + })?; 2175 2438 let codec = tonic::codec::ProstCodec::default(); 2176 - let path = 2177 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/Pause"); 2439 + let path = http::uri::PathAndQuery::from_static( 2440 + "/rockbox.v1alpha1.PlaybackService/Pause", 2441 + ); 2178 2442 let mut req = request.into_request(); 2179 2443 req.extensions_mut() 2180 2444 .insert(GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "Pause")); ··· 2183 2447 pub async fn play_or_pause( 2184 2448 &mut self, 2185 2449 request: impl tonic::IntoRequest<super::PlayOrPauseRequest>, 2186 - ) -> std::result::Result<tonic::Response<super::PlayOrPauseResponse>, tonic::Status> 2187 - { 2188 - self.inner.ready().await.map_err(|e| { 2189 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2190 - })?; 2450 + ) -> std::result::Result< 2451 + tonic::Response<super::PlayOrPauseResponse>, 2452 + tonic::Status, 2453 + > { 2454 + self.inner 2455 + .ready() 2456 + .await 2457 + .map_err(|e| { 2458 + tonic::Status::unknown( 2459 + format!("Service was not ready: {}", e.into()), 2460 + ) 2461 + })?; 2191 2462 let codec = tonic::codec::ProstCodec::default(); 2192 2463 let path = http::uri::PathAndQuery::from_static( 2193 2464 "/rockbox.v1alpha1.PlaybackService/PlayOrPause", 2194 2465 ); 2195 2466 let mut req = request.into_request(); 2196 - req.extensions_mut().insert(GrpcMethod::new( 2197 - "rockbox.v1alpha1.PlaybackService", 2198 - "PlayOrPause", 2199 - )); 2467 + req.extensions_mut() 2468 + .insert( 2469 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "PlayOrPause"), 2470 + ); 2200 2471 self.inner.unary(req, path, codec).await 2201 2472 } 2202 2473 pub async fn resume( 2203 2474 &mut self, 2204 2475 request: impl tonic::IntoRequest<super::ResumeRequest>, 2205 2476 ) -> std::result::Result<tonic::Response<super::ResumeResponse>, tonic::Status> { 2206 - self.inner.ready().await.map_err(|e| { 2207 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2208 - })?; 2477 + self.inner 2478 + .ready() 2479 + .await 2480 + .map_err(|e| { 2481 + tonic::Status::unknown( 2482 + format!("Service was not ready: {}", e.into()), 2483 + ) 2484 + })?; 2209 2485 let codec = tonic::codec::ProstCodec::default(); 2210 - let path = 2211 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/Resume"); 2486 + let path = http::uri::PathAndQuery::from_static( 2487 + "/rockbox.v1alpha1.PlaybackService/Resume", 2488 + ); 2212 2489 let mut req = request.into_request(); 2213 - req.extensions_mut().insert(GrpcMethod::new( 2214 - "rockbox.v1alpha1.PlaybackService", 2215 - "Resume", 2216 - )); 2490 + req.extensions_mut() 2491 + .insert(GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "Resume")); 2217 2492 self.inner.unary(req, path, codec).await 2218 2493 } 2219 2494 pub async fn next( 2220 2495 &mut self, 2221 2496 request: impl tonic::IntoRequest<super::NextRequest>, 2222 2497 ) -> std::result::Result<tonic::Response<super::NextResponse>, tonic::Status> { 2223 - self.inner.ready().await.map_err(|e| { 2224 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2225 - })?; 2498 + self.inner 2499 + .ready() 2500 + .await 2501 + .map_err(|e| { 2502 + tonic::Status::unknown( 2503 + format!("Service was not ready: {}", e.into()), 2504 + ) 2505 + })?; 2226 2506 let codec = tonic::codec::ProstCodec::default(); 2227 - let path = 2228 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/Next"); 2507 + let path = http::uri::PathAndQuery::from_static( 2508 + "/rockbox.v1alpha1.PlaybackService/Next", 2509 + ); 2229 2510 let mut req = request.into_request(); 2230 2511 req.extensions_mut() 2231 2512 .insert(GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "Next")); ··· 2234 2515 pub async fn previous( 2235 2516 &mut self, 2236 2517 request: impl tonic::IntoRequest<super::PreviousRequest>, 2237 - ) -> std::result::Result<tonic::Response<super::PreviousResponse>, tonic::Status> { 2238 - self.inner.ready().await.map_err(|e| { 2239 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2240 - })?; 2518 + ) -> std::result::Result< 2519 + tonic::Response<super::PreviousResponse>, 2520 + tonic::Status, 2521 + > { 2522 + self.inner 2523 + .ready() 2524 + .await 2525 + .map_err(|e| { 2526 + tonic::Status::unknown( 2527 + format!("Service was not ready: {}", e.into()), 2528 + ) 2529 + })?; 2241 2530 let codec = tonic::codec::ProstCodec::default(); 2242 - let path = 2243 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/Previous"); 2531 + let path = http::uri::PathAndQuery::from_static( 2532 + "/rockbox.v1alpha1.PlaybackService/Previous", 2533 + ); 2244 2534 let mut req = request.into_request(); 2245 - req.extensions_mut().insert(GrpcMethod::new( 2246 - "rockbox.v1alpha1.PlaybackService", 2247 - "Previous", 2248 - )); 2535 + req.extensions_mut() 2536 + .insert(GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "Previous")); 2249 2537 self.inner.unary(req, path, codec).await 2250 2538 } 2251 2539 pub async fn fast_forward_rewind( 2252 2540 &mut self, 2253 2541 request: impl tonic::IntoRequest<super::FastForwardRewindRequest>, 2254 - ) -> std::result::Result<tonic::Response<super::FastForwardRewindResponse>, tonic::Status> 2255 - { 2256 - self.inner.ready().await.map_err(|e| { 2257 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2258 - })?; 2542 + ) -> std::result::Result< 2543 + tonic::Response<super::FastForwardRewindResponse>, 2544 + tonic::Status, 2545 + > { 2546 + self.inner 2547 + .ready() 2548 + .await 2549 + .map_err(|e| { 2550 + tonic::Status::unknown( 2551 + format!("Service was not ready: {}", e.into()), 2552 + ) 2553 + })?; 2259 2554 let codec = tonic::codec::ProstCodec::default(); 2260 2555 let path = http::uri::PathAndQuery::from_static( 2261 2556 "/rockbox.v1alpha1.PlaybackService/FastForwardRewind", 2262 2557 ); 2263 2558 let mut req = request.into_request(); 2264 - req.extensions_mut().insert(GrpcMethod::new( 2265 - "rockbox.v1alpha1.PlaybackService", 2266 - "FastForwardRewind", 2267 - )); 2559 + req.extensions_mut() 2560 + .insert( 2561 + GrpcMethod::new( 2562 + "rockbox.v1alpha1.PlaybackService", 2563 + "FastForwardRewind", 2564 + ), 2565 + ); 2268 2566 self.inner.unary(req, path, codec).await 2269 2567 } 2270 2568 pub async fn status( 2271 2569 &mut self, 2272 2570 request: impl tonic::IntoRequest<super::StatusRequest>, 2273 2571 ) -> std::result::Result<tonic::Response<super::StatusResponse>, tonic::Status> { 2274 - self.inner.ready().await.map_err(|e| { 2275 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2276 - })?; 2572 + self.inner 2573 + .ready() 2574 + .await 2575 + .map_err(|e| { 2576 + tonic::Status::unknown( 2577 + format!("Service was not ready: {}", e.into()), 2578 + ) 2579 + })?; 2277 2580 let codec = tonic::codec::ProstCodec::default(); 2278 - let path = 2279 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/Status"); 2581 + let path = http::uri::PathAndQuery::from_static( 2582 + "/rockbox.v1alpha1.PlaybackService/Status", 2583 + ); 2280 2584 let mut req = request.into_request(); 2281 - req.extensions_mut().insert(GrpcMethod::new( 2282 - "rockbox.v1alpha1.PlaybackService", 2283 - "Status", 2284 - )); 2585 + req.extensions_mut() 2586 + .insert(GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "Status")); 2285 2587 self.inner.unary(req, path, codec).await 2286 2588 } 2287 2589 pub async fn current_track( 2288 2590 &mut self, 2289 2591 request: impl tonic::IntoRequest<super::CurrentTrackRequest>, 2290 - ) -> std::result::Result<tonic::Response<super::CurrentTrackResponse>, tonic::Status> 2291 - { 2292 - self.inner.ready().await.map_err(|e| { 2293 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2294 - })?; 2592 + ) -> std::result::Result< 2593 + tonic::Response<super::CurrentTrackResponse>, 2594 + tonic::Status, 2595 + > { 2596 + self.inner 2597 + .ready() 2598 + .await 2599 + .map_err(|e| { 2600 + tonic::Status::unknown( 2601 + format!("Service was not ready: {}", e.into()), 2602 + ) 2603 + })?; 2295 2604 let codec = tonic::codec::ProstCodec::default(); 2296 2605 let path = http::uri::PathAndQuery::from_static( 2297 2606 "/rockbox.v1alpha1.PlaybackService/CurrentTrack", 2298 2607 ); 2299 2608 let mut req = request.into_request(); 2300 - req.extensions_mut().insert(GrpcMethod::new( 2301 - "rockbox.v1alpha1.PlaybackService", 2302 - "CurrentTrack", 2303 - )); 2609 + req.extensions_mut() 2610 + .insert( 2611 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "CurrentTrack"), 2612 + ); 2304 2613 self.inner.unary(req, path, codec).await 2305 2614 } 2306 2615 pub async fn next_track( 2307 2616 &mut self, 2308 2617 request: impl tonic::IntoRequest<super::NextTrackRequest>, 2309 - ) -> std::result::Result<tonic::Response<super::NextTrackResponse>, tonic::Status> { 2310 - self.inner.ready().await.map_err(|e| { 2311 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2312 - })?; 2618 + ) -> std::result::Result< 2619 + tonic::Response<super::NextTrackResponse>, 2620 + tonic::Status, 2621 + > { 2622 + self.inner 2623 + .ready() 2624 + .await 2625 + .map_err(|e| { 2626 + tonic::Status::unknown( 2627 + format!("Service was not ready: {}", e.into()), 2628 + ) 2629 + })?; 2313 2630 let codec = tonic::codec::ProstCodec::default(); 2314 - let path = 2315 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/NextTrack"); 2631 + let path = http::uri::PathAndQuery::from_static( 2632 + "/rockbox.v1alpha1.PlaybackService/NextTrack", 2633 + ); 2316 2634 let mut req = request.into_request(); 2317 - req.extensions_mut().insert(GrpcMethod::new( 2318 - "rockbox.v1alpha1.PlaybackService", 2319 - "NextTrack", 2320 - )); 2635 + req.extensions_mut() 2636 + .insert( 2637 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "NextTrack"), 2638 + ); 2321 2639 self.inner.unary(req, path, codec).await 2322 2640 } 2323 2641 pub async fn flush_and_reload_tracks( 2324 2642 &mut self, 2325 2643 request: impl tonic::IntoRequest<super::FlushAndReloadTracksRequest>, 2326 - ) -> std::result::Result<tonic::Response<super::FlushAndReloadTracksResponse>, tonic::Status> 2327 - { 2328 - self.inner.ready().await.map_err(|e| { 2329 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2330 - })?; 2644 + ) -> std::result::Result< 2645 + tonic::Response<super::FlushAndReloadTracksResponse>, 2646 + tonic::Status, 2647 + > { 2648 + self.inner 2649 + .ready() 2650 + .await 2651 + .map_err(|e| { 2652 + tonic::Status::unknown( 2653 + format!("Service was not ready: {}", e.into()), 2654 + ) 2655 + })?; 2331 2656 let codec = tonic::codec::ProstCodec::default(); 2332 2657 let path = http::uri::PathAndQuery::from_static( 2333 2658 "/rockbox.v1alpha1.PlaybackService/FlushAndReloadTracks", 2334 2659 ); 2335 2660 let mut req = request.into_request(); 2336 - req.extensions_mut().insert(GrpcMethod::new( 2337 - "rockbox.v1alpha1.PlaybackService", 2338 - "FlushAndReloadTracks", 2339 - )); 2661 + req.extensions_mut() 2662 + .insert( 2663 + GrpcMethod::new( 2664 + "rockbox.v1alpha1.PlaybackService", 2665 + "FlushAndReloadTracks", 2666 + ), 2667 + ); 2340 2668 self.inner.unary(req, path, codec).await 2341 2669 } 2342 2670 pub async fn get_file_position( 2343 2671 &mut self, 2344 2672 request: impl tonic::IntoRequest<super::GetFilePositionRequest>, 2345 - ) -> std::result::Result<tonic::Response<super::GetFilePositionResponse>, tonic::Status> 2346 - { 2347 - self.inner.ready().await.map_err(|e| { 2348 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2349 - })?; 2673 + ) -> std::result::Result< 2674 + tonic::Response<super::GetFilePositionResponse>, 2675 + tonic::Status, 2676 + > { 2677 + self.inner 2678 + .ready() 2679 + .await 2680 + .map_err(|e| { 2681 + tonic::Status::unknown( 2682 + format!("Service was not ready: {}", e.into()), 2683 + ) 2684 + })?; 2350 2685 let codec = tonic::codec::ProstCodec::default(); 2351 2686 let path = http::uri::PathAndQuery::from_static( 2352 2687 "/rockbox.v1alpha1.PlaybackService/GetFilePosition", 2353 2688 ); 2354 2689 let mut req = request.into_request(); 2355 - req.extensions_mut().insert(GrpcMethod::new( 2356 - "rockbox.v1alpha1.PlaybackService", 2357 - "GetFilePosition", 2358 - )); 2690 + req.extensions_mut() 2691 + .insert( 2692 + GrpcMethod::new( 2693 + "rockbox.v1alpha1.PlaybackService", 2694 + "GetFilePosition", 2695 + ), 2696 + ); 2359 2697 self.inner.unary(req, path, codec).await 2360 2698 } 2361 2699 pub async fn hard_stop( 2362 2700 &mut self, 2363 2701 request: impl tonic::IntoRequest<super::HardStopRequest>, 2364 - ) -> std::result::Result<tonic::Response<super::HardStopResponse>, tonic::Status> { 2365 - self.inner.ready().await.map_err(|e| { 2366 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2367 - })?; 2702 + ) -> std::result::Result< 2703 + tonic::Response<super::HardStopResponse>, 2704 + tonic::Status, 2705 + > { 2706 + self.inner 2707 + .ready() 2708 + .await 2709 + .map_err(|e| { 2710 + tonic::Status::unknown( 2711 + format!("Service was not ready: {}", e.into()), 2712 + ) 2713 + })?; 2368 2714 let codec = tonic::codec::ProstCodec::default(); 2369 - let path = 2370 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/HardStop"); 2715 + let path = http::uri::PathAndQuery::from_static( 2716 + "/rockbox.v1alpha1.PlaybackService/HardStop", 2717 + ); 2371 2718 let mut req = request.into_request(); 2372 - req.extensions_mut().insert(GrpcMethod::new( 2373 - "rockbox.v1alpha1.PlaybackService", 2374 - "HardStop", 2375 - )); 2719 + req.extensions_mut() 2720 + .insert(GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "HardStop")); 2376 2721 self.inner.unary(req, path, codec).await 2377 2722 } 2378 2723 pub async fn play_album( 2379 2724 &mut self, 2380 2725 request: impl tonic::IntoRequest<super::PlayAlbumRequest>, 2381 - ) -> std::result::Result<tonic::Response<super::PlayAlbumResponse>, tonic::Status> { 2382 - self.inner.ready().await.map_err(|e| { 2383 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2384 - })?; 2726 + ) -> std::result::Result< 2727 + tonic::Response<super::PlayAlbumResponse>, 2728 + tonic::Status, 2729 + > { 2730 + self.inner 2731 + .ready() 2732 + .await 2733 + .map_err(|e| { 2734 + tonic::Status::unknown( 2735 + format!("Service was not ready: {}", e.into()), 2736 + ) 2737 + })?; 2385 2738 let codec = tonic::codec::ProstCodec::default(); 2386 - let path = 2387 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/PlayAlbum"); 2739 + let path = http::uri::PathAndQuery::from_static( 2740 + "/rockbox.v1alpha1.PlaybackService/PlayAlbum", 2741 + ); 2388 2742 let mut req = request.into_request(); 2389 - req.extensions_mut().insert(GrpcMethod::new( 2390 - "rockbox.v1alpha1.PlaybackService", 2391 - "PlayAlbum", 2392 - )); 2743 + req.extensions_mut() 2744 + .insert( 2745 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "PlayAlbum"), 2746 + ); 2393 2747 self.inner.unary(req, path, codec).await 2394 2748 } 2395 2749 pub async fn play_artist_tracks( 2396 2750 &mut self, 2397 2751 request: impl tonic::IntoRequest<super::PlayArtistTracksRequest>, 2398 - ) -> std::result::Result<tonic::Response<super::PlayArtistTracksResponse>, tonic::Status> 2399 - { 2400 - self.inner.ready().await.map_err(|e| { 2401 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2402 - })?; 2752 + ) -> std::result::Result< 2753 + tonic::Response<super::PlayArtistTracksResponse>, 2754 + tonic::Status, 2755 + > { 2756 + self.inner 2757 + .ready() 2758 + .await 2759 + .map_err(|e| { 2760 + tonic::Status::unknown( 2761 + format!("Service was not ready: {}", e.into()), 2762 + ) 2763 + })?; 2403 2764 let codec = tonic::codec::ProstCodec::default(); 2404 2765 let path = http::uri::PathAndQuery::from_static( 2405 2766 "/rockbox.v1alpha1.PlaybackService/PlayArtistTracks", 2406 2767 ); 2407 2768 let mut req = request.into_request(); 2408 - req.extensions_mut().insert(GrpcMethod::new( 2409 - "rockbox.v1alpha1.PlaybackService", 2410 - "PlayArtistTracks", 2411 - )); 2769 + req.extensions_mut() 2770 + .insert( 2771 + GrpcMethod::new( 2772 + "rockbox.v1alpha1.PlaybackService", 2773 + "PlayArtistTracks", 2774 + ), 2775 + ); 2412 2776 self.inner.unary(req, path, codec).await 2413 2777 } 2414 2778 pub async fn play_playlist( 2415 2779 &mut self, 2416 2780 request: impl tonic::IntoRequest<super::PlayPlaylistRequest>, 2417 - ) -> std::result::Result<tonic::Response<super::PlayPlaylistResponse>, tonic::Status> 2418 - { 2419 - self.inner.ready().await.map_err(|e| { 2420 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2421 - })?; 2781 + ) -> std::result::Result< 2782 + tonic::Response<super::PlayPlaylistResponse>, 2783 + tonic::Status, 2784 + > { 2785 + self.inner 2786 + .ready() 2787 + .await 2788 + .map_err(|e| { 2789 + tonic::Status::unknown( 2790 + format!("Service was not ready: {}", e.into()), 2791 + ) 2792 + })?; 2422 2793 let codec = tonic::codec::ProstCodec::default(); 2423 2794 let path = http::uri::PathAndQuery::from_static( 2424 2795 "/rockbox.v1alpha1.PlaybackService/PlayPlaylist", 2425 2796 ); 2426 2797 let mut req = request.into_request(); 2427 - req.extensions_mut().insert(GrpcMethod::new( 2428 - "rockbox.v1alpha1.PlaybackService", 2429 - "PlayPlaylist", 2430 - )); 2798 + req.extensions_mut() 2799 + .insert( 2800 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "PlayPlaylist"), 2801 + ); 2431 2802 self.inner.unary(req, path, codec).await 2432 2803 } 2433 2804 pub async fn play_directory( 2434 2805 &mut self, 2435 2806 request: impl tonic::IntoRequest<super::PlayDirectoryRequest>, 2436 - ) -> std::result::Result<tonic::Response<super::PlayDirectoryResponse>, tonic::Status> 2437 - { 2438 - self.inner.ready().await.map_err(|e| { 2439 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2440 - })?; 2807 + ) -> std::result::Result< 2808 + tonic::Response<super::PlayDirectoryResponse>, 2809 + tonic::Status, 2810 + > { 2811 + self.inner 2812 + .ready() 2813 + .await 2814 + .map_err(|e| { 2815 + tonic::Status::unknown( 2816 + format!("Service was not ready: {}", e.into()), 2817 + ) 2818 + })?; 2441 2819 let codec = tonic::codec::ProstCodec::default(); 2442 2820 let path = http::uri::PathAndQuery::from_static( 2443 2821 "/rockbox.v1alpha1.PlaybackService/PlayDirectory", 2444 2822 ); 2445 2823 let mut req = request.into_request(); 2446 - req.extensions_mut().insert(GrpcMethod::new( 2447 - "rockbox.v1alpha1.PlaybackService", 2448 - "PlayDirectory", 2449 - )); 2824 + req.extensions_mut() 2825 + .insert( 2826 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "PlayDirectory"), 2827 + ); 2450 2828 self.inner.unary(req, path, codec).await 2451 2829 } 2452 2830 pub async fn play_music_directory( 2453 2831 &mut self, 2454 2832 request: impl tonic::IntoRequest<super::PlayMusicDirectoryRequest>, 2455 - ) -> std::result::Result<tonic::Response<super::PlayMusicDirectoryResponse>, tonic::Status> 2456 - { 2457 - self.inner.ready().await.map_err(|e| { 2458 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2459 - })?; 2833 + ) -> std::result::Result< 2834 + tonic::Response<super::PlayMusicDirectoryResponse>, 2835 + tonic::Status, 2836 + > { 2837 + self.inner 2838 + .ready() 2839 + .await 2840 + .map_err(|e| { 2841 + tonic::Status::unknown( 2842 + format!("Service was not ready: {}", e.into()), 2843 + ) 2844 + })?; 2460 2845 let codec = tonic::codec::ProstCodec::default(); 2461 2846 let path = http::uri::PathAndQuery::from_static( 2462 2847 "/rockbox.v1alpha1.PlaybackService/PlayMusicDirectory", 2463 2848 ); 2464 2849 let mut req = request.into_request(); 2465 - req.extensions_mut().insert(GrpcMethod::new( 2466 - "rockbox.v1alpha1.PlaybackService", 2467 - "PlayMusicDirectory", 2468 - )); 2850 + req.extensions_mut() 2851 + .insert( 2852 + GrpcMethod::new( 2853 + "rockbox.v1alpha1.PlaybackService", 2854 + "PlayMusicDirectory", 2855 + ), 2856 + ); 2469 2857 self.inner.unary(req, path, codec).await 2470 2858 } 2471 2859 pub async fn play_track( 2472 2860 &mut self, 2473 2861 request: impl tonic::IntoRequest<super::PlayTrackRequest>, 2474 - ) -> std::result::Result<tonic::Response<super::PlayTrackResponse>, tonic::Status> { 2475 - self.inner.ready().await.map_err(|e| { 2476 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2477 - })?; 2862 + ) -> std::result::Result< 2863 + tonic::Response<super::PlayTrackResponse>, 2864 + tonic::Status, 2865 + > { 2866 + self.inner 2867 + .ready() 2868 + .await 2869 + .map_err(|e| { 2870 + tonic::Status::unknown( 2871 + format!("Service was not ready: {}", e.into()), 2872 + ) 2873 + })?; 2478 2874 let codec = tonic::codec::ProstCodec::default(); 2479 - let path = 2480 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/PlayTrack"); 2875 + let path = http::uri::PathAndQuery::from_static( 2876 + "/rockbox.v1alpha1.PlaybackService/PlayTrack", 2877 + ); 2481 2878 let mut req = request.into_request(); 2482 - req.extensions_mut().insert(GrpcMethod::new( 2483 - "rockbox.v1alpha1.PlaybackService", 2484 - "PlayTrack", 2485 - )); 2879 + req.extensions_mut() 2880 + .insert( 2881 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "PlayTrack"), 2882 + ); 2486 2883 self.inner.unary(req, path, codec).await 2487 2884 } 2488 2885 pub async fn play_liked_tracks( 2489 2886 &mut self, 2490 2887 request: impl tonic::IntoRequest<super::PlayLikedTracksRequest>, 2491 - ) -> std::result::Result<tonic::Response<super::PlayLikedTracksResponse>, tonic::Status> 2492 - { 2493 - self.inner.ready().await.map_err(|e| { 2494 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2495 - })?; 2888 + ) -> std::result::Result< 2889 + tonic::Response<super::PlayLikedTracksResponse>, 2890 + tonic::Status, 2891 + > { 2892 + self.inner 2893 + .ready() 2894 + .await 2895 + .map_err(|e| { 2896 + tonic::Status::unknown( 2897 + format!("Service was not ready: {}", e.into()), 2898 + ) 2899 + })?; 2496 2900 let codec = tonic::codec::ProstCodec::default(); 2497 2901 let path = http::uri::PathAndQuery::from_static( 2498 2902 "/rockbox.v1alpha1.PlaybackService/PlayLikedTracks", 2499 2903 ); 2500 2904 let mut req = request.into_request(); 2501 - req.extensions_mut().insert(GrpcMethod::new( 2502 - "rockbox.v1alpha1.PlaybackService", 2503 - "PlayLikedTracks", 2504 - )); 2905 + req.extensions_mut() 2906 + .insert( 2907 + GrpcMethod::new( 2908 + "rockbox.v1alpha1.PlaybackService", 2909 + "PlayLikedTracks", 2910 + ), 2911 + ); 2505 2912 self.inner.unary(req, path, codec).await 2506 2913 } 2507 2914 pub async fn play_all_tracks( 2508 2915 &mut self, 2509 2916 request: impl tonic::IntoRequest<super::PlayAllTracksRequest>, 2510 - ) -> std::result::Result<tonic::Response<super::PlayAllTracksResponse>, tonic::Status> 2511 - { 2512 - self.inner.ready().await.map_err(|e| { 2513 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2514 - })?; 2917 + ) -> std::result::Result< 2918 + tonic::Response<super::PlayAllTracksResponse>, 2919 + tonic::Status, 2920 + > { 2921 + self.inner 2922 + .ready() 2923 + .await 2924 + .map_err(|e| { 2925 + tonic::Status::unknown( 2926 + format!("Service was not ready: {}", e.into()), 2927 + ) 2928 + })?; 2515 2929 let codec = tonic::codec::ProstCodec::default(); 2516 2930 let path = http::uri::PathAndQuery::from_static( 2517 2931 "/rockbox.v1alpha1.PlaybackService/PlayAllTracks", 2518 2932 ); 2519 2933 let mut req = request.into_request(); 2520 - req.extensions_mut().insert(GrpcMethod::new( 2521 - "rockbox.v1alpha1.PlaybackService", 2522 - "PlayAllTracks", 2523 - )); 2934 + req.extensions_mut() 2935 + .insert( 2936 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "PlayAllTracks"), 2937 + ); 2524 2938 self.inner.unary(req, path, codec).await 2525 2939 } 2526 2940 pub async fn stream_current_track( ··· 2530 2944 tonic::Response<tonic::codec::Streaming<super::CurrentTrackResponse>>, 2531 2945 tonic::Status, 2532 2946 > { 2533 - self.inner.ready().await.map_err(|e| { 2534 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2535 - })?; 2947 + self.inner 2948 + .ready() 2949 + .await 2950 + .map_err(|e| { 2951 + tonic::Status::unknown( 2952 + format!("Service was not ready: {}", e.into()), 2953 + ) 2954 + })?; 2536 2955 let codec = tonic::codec::ProstCodec::default(); 2537 2956 let path = http::uri::PathAndQuery::from_static( 2538 2957 "/rockbox.v1alpha1.PlaybackService/StreamCurrentTrack", 2539 2958 ); 2540 2959 let mut req = request.into_request(); 2541 - req.extensions_mut().insert(GrpcMethod::new( 2542 - "rockbox.v1alpha1.PlaybackService", 2543 - "StreamCurrentTrack", 2544 - )); 2960 + req.extensions_mut() 2961 + .insert( 2962 + GrpcMethod::new( 2963 + "rockbox.v1alpha1.PlaybackService", 2964 + "StreamCurrentTrack", 2965 + ), 2966 + ); 2545 2967 self.inner.server_streaming(req, path, codec).await 2546 2968 } 2547 2969 pub async fn stream_status( ··· 2551 2973 tonic::Response<tonic::codec::Streaming<super::StatusResponse>>, 2552 2974 tonic::Status, 2553 2975 > { 2554 - self.inner.ready().await.map_err(|e| { 2555 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2556 - })?; 2976 + self.inner 2977 + .ready() 2978 + .await 2979 + .map_err(|e| { 2980 + tonic::Status::unknown( 2981 + format!("Service was not ready: {}", e.into()), 2982 + ) 2983 + })?; 2557 2984 let codec = tonic::codec::ProstCodec::default(); 2558 2985 let path = http::uri::PathAndQuery::from_static( 2559 2986 "/rockbox.v1alpha1.PlaybackService/StreamStatus", 2560 2987 ); 2561 2988 let mut req = request.into_request(); 2562 - req.extensions_mut().insert(GrpcMethod::new( 2563 - "rockbox.v1alpha1.PlaybackService", 2564 - "StreamStatus", 2565 - )); 2989 + req.extensions_mut() 2990 + .insert( 2991 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "StreamStatus"), 2992 + ); 2566 2993 self.inner.server_streaming(req, path, codec).await 2567 2994 } 2568 2995 pub async fn stream_playlist( ··· 2572 2999 tonic::Response<tonic::codec::Streaming<super::PlaylistResponse>>, 2573 3000 tonic::Status, 2574 3001 > { 2575 - self.inner.ready().await.map_err(|e| { 2576 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2577 - })?; 3002 + self.inner 3003 + .ready() 3004 + .await 3005 + .map_err(|e| { 3006 + tonic::Status::unknown( 3007 + format!("Service was not ready: {}", e.into()), 3008 + ) 3009 + })?; 2578 3010 let codec = tonic::codec::ProstCodec::default(); 2579 3011 let path = http::uri::PathAndQuery::from_static( 2580 3012 "/rockbox.v1alpha1.PlaybackService/StreamPlaylist", 2581 3013 ); 2582 3014 let mut req = request.into_request(); 2583 - req.extensions_mut().insert(GrpcMethod::new( 2584 - "rockbox.v1alpha1.PlaybackService", 2585 - "StreamPlaylist", 2586 - )); 3015 + req.extensions_mut() 3016 + .insert( 3017 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "StreamPlaylist"), 3018 + ); 2587 3019 self.inner.server_streaming(req, path, codec).await 2588 3020 } 2589 3021 } ··· 2595 3027 dead_code, 2596 3028 missing_docs, 2597 3029 clippy::wildcard_imports, 2598 - clippy::let_unit_value 3030 + clippy::let_unit_value, 2599 3031 )] 2600 3032 use tonic::codegen::*; 2601 3033 /// Generated trait containing gRPC methods that should be implemented for use with PlaybackServiceServer. ··· 2612 3044 async fn play_or_pause( 2613 3045 &self, 2614 3046 request: tonic::Request<super::PlayOrPauseRequest>, 2615 - ) -> std::result::Result<tonic::Response<super::PlayOrPauseResponse>, tonic::Status>; 3047 + ) -> std::result::Result< 3048 + tonic::Response<super::PlayOrPauseResponse>, 3049 + tonic::Status, 3050 + >; 2616 3051 async fn resume( 2617 3052 &self, 2618 3053 request: tonic::Request<super::ResumeRequest>, ··· 2624 3059 async fn previous( 2625 3060 &self, 2626 3061 request: tonic::Request<super::PreviousRequest>, 2627 - ) -> std::result::Result<tonic::Response<super::PreviousResponse>, tonic::Status>; 3062 + ) -> std::result::Result< 3063 + tonic::Response<super::PreviousResponse>, 3064 + tonic::Status, 3065 + >; 2628 3066 async fn fast_forward_rewind( 2629 3067 &self, 2630 3068 request: tonic::Request<super::FastForwardRewindRequest>, 2631 - ) -> std::result::Result<tonic::Response<super::FastForwardRewindResponse>, tonic::Status>; 3069 + ) -> std::result::Result< 3070 + tonic::Response<super::FastForwardRewindResponse>, 3071 + tonic::Status, 3072 + >; 2632 3073 async fn status( 2633 3074 &self, 2634 3075 request: tonic::Request<super::StatusRequest>, ··· 2636 3077 async fn current_track( 2637 3078 &self, 2638 3079 request: tonic::Request<super::CurrentTrackRequest>, 2639 - ) -> std::result::Result<tonic::Response<super::CurrentTrackResponse>, tonic::Status>; 3080 + ) -> std::result::Result< 3081 + tonic::Response<super::CurrentTrackResponse>, 3082 + tonic::Status, 3083 + >; 2640 3084 async fn next_track( 2641 3085 &self, 2642 3086 request: tonic::Request<super::NextTrackRequest>, 2643 - ) -> std::result::Result<tonic::Response<super::NextTrackResponse>, tonic::Status>; 3087 + ) -> std::result::Result< 3088 + tonic::Response<super::NextTrackResponse>, 3089 + tonic::Status, 3090 + >; 2644 3091 async fn flush_and_reload_tracks( 2645 3092 &self, 2646 3093 request: tonic::Request<super::FlushAndReloadTracksRequest>, 2647 - ) -> std::result::Result<tonic::Response<super::FlushAndReloadTracksResponse>, tonic::Status>; 3094 + ) -> std::result::Result< 3095 + tonic::Response<super::FlushAndReloadTracksResponse>, 3096 + tonic::Status, 3097 + >; 2648 3098 async fn get_file_position( 2649 3099 &self, 2650 3100 request: tonic::Request<super::GetFilePositionRequest>, 2651 - ) -> std::result::Result<tonic::Response<super::GetFilePositionResponse>, tonic::Status>; 3101 + ) -> std::result::Result< 3102 + tonic::Response<super::GetFilePositionResponse>, 3103 + tonic::Status, 3104 + >; 2652 3105 async fn hard_stop( 2653 3106 &self, 2654 3107 request: tonic::Request<super::HardStopRequest>, 2655 - ) -> std::result::Result<tonic::Response<super::HardStopResponse>, tonic::Status>; 3108 + ) -> std::result::Result< 3109 + tonic::Response<super::HardStopResponse>, 3110 + tonic::Status, 3111 + >; 2656 3112 async fn play_album( 2657 3113 &self, 2658 3114 request: tonic::Request<super::PlayAlbumRequest>, 2659 - ) -> std::result::Result<tonic::Response<super::PlayAlbumResponse>, tonic::Status>; 3115 + ) -> std::result::Result< 3116 + tonic::Response<super::PlayAlbumResponse>, 3117 + tonic::Status, 3118 + >; 2660 3119 async fn play_artist_tracks( 2661 3120 &self, 2662 3121 request: tonic::Request<super::PlayArtistTracksRequest>, 2663 - ) -> std::result::Result<tonic::Response<super::PlayArtistTracksResponse>, tonic::Status>; 3122 + ) -> std::result::Result< 3123 + tonic::Response<super::PlayArtistTracksResponse>, 3124 + tonic::Status, 3125 + >; 2664 3126 async fn play_playlist( 2665 3127 &self, 2666 3128 request: tonic::Request<super::PlayPlaylistRequest>, 2667 - ) -> std::result::Result<tonic::Response<super::PlayPlaylistResponse>, tonic::Status>; 3129 + ) -> std::result::Result< 3130 + tonic::Response<super::PlayPlaylistResponse>, 3131 + tonic::Status, 3132 + >; 2668 3133 async fn play_directory( 2669 3134 &self, 2670 3135 request: tonic::Request<super::PlayDirectoryRequest>, 2671 - ) -> std::result::Result<tonic::Response<super::PlayDirectoryResponse>, tonic::Status>; 3136 + ) -> std::result::Result< 3137 + tonic::Response<super::PlayDirectoryResponse>, 3138 + tonic::Status, 3139 + >; 2672 3140 async fn play_music_directory( 2673 3141 &self, 2674 3142 request: tonic::Request<super::PlayMusicDirectoryRequest>, 2675 - ) -> std::result::Result<tonic::Response<super::PlayMusicDirectoryResponse>, tonic::Status>; 3143 + ) -> std::result::Result< 3144 + tonic::Response<super::PlayMusicDirectoryResponse>, 3145 + tonic::Status, 3146 + >; 2676 3147 async fn play_track( 2677 3148 &self, 2678 3149 request: tonic::Request<super::PlayTrackRequest>, 2679 - ) -> std::result::Result<tonic::Response<super::PlayTrackResponse>, tonic::Status>; 3150 + ) -> std::result::Result< 3151 + tonic::Response<super::PlayTrackResponse>, 3152 + tonic::Status, 3153 + >; 2680 3154 async fn play_liked_tracks( 2681 3155 &self, 2682 3156 request: tonic::Request<super::PlayLikedTracksRequest>, 2683 - ) -> std::result::Result<tonic::Response<super::PlayLikedTracksResponse>, tonic::Status>; 3157 + ) -> std::result::Result< 3158 + tonic::Response<super::PlayLikedTracksResponse>, 3159 + tonic::Status, 3160 + >; 2684 3161 async fn play_all_tracks( 2685 3162 &self, 2686 3163 request: tonic::Request<super::PlayAllTracksRequest>, 2687 - ) -> std::result::Result<tonic::Response<super::PlayAllTracksResponse>, tonic::Status>; 3164 + ) -> std::result::Result< 3165 + tonic::Response<super::PlayAllTracksResponse>, 3166 + tonic::Status, 3167 + >; 2688 3168 /// Server streaming response type for the StreamCurrentTrack method. 2689 3169 type StreamCurrentTrackStream: tonic::codegen::tokio_stream::Stream< 2690 3170 Item = std::result::Result<super::CurrentTrackResponse, tonic::Status>, 2691 - > + std::marker::Send 3171 + > 3172 + + std::marker::Send 2692 3173 + 'static; 2693 3174 async fn stream_current_track( 2694 3175 &self, 2695 3176 request: tonic::Request<super::StreamCurrentTrackRequest>, 2696 - ) -> std::result::Result<tonic::Response<Self::StreamCurrentTrackStream>, tonic::Status>; 3177 + ) -> std::result::Result< 3178 + tonic::Response<Self::StreamCurrentTrackStream>, 3179 + tonic::Status, 3180 + >; 2697 3181 /// Server streaming response type for the StreamStatus method. 2698 3182 type StreamStatusStream: tonic::codegen::tokio_stream::Stream< 2699 3183 Item = std::result::Result<super::StatusResponse, tonic::Status>, 2700 - > + std::marker::Send 3184 + > 3185 + + std::marker::Send 2701 3186 + 'static; 2702 3187 async fn stream_status( 2703 3188 &self, 2704 3189 request: tonic::Request<super::StreamStatusRequest>, 2705 - ) -> std::result::Result<tonic::Response<Self::StreamStatusStream>, tonic::Status>; 3190 + ) -> std::result::Result< 3191 + tonic::Response<Self::StreamStatusStream>, 3192 + tonic::Status, 3193 + >; 2706 3194 /// Server streaming response type for the StreamPlaylist method. 2707 3195 type StreamPlaylistStream: tonic::codegen::tokio_stream::Stream< 2708 3196 Item = std::result::Result<super::PlaylistResponse, tonic::Status>, 2709 - > + std::marker::Send 3197 + > 3198 + + std::marker::Send 2710 3199 + 'static; 2711 3200 async fn stream_playlist( 2712 3201 &self, 2713 3202 request: tonic::Request<super::StreamPlaylistRequest>, 2714 - ) -> std::result::Result<tonic::Response<Self::StreamPlaylistStream>, tonic::Status>; 3203 + ) -> std::result::Result< 3204 + tonic::Response<Self::StreamPlaylistStream>, 3205 + tonic::Status, 3206 + >; 2715 3207 } 2716 3208 #[derive(Debug)] 2717 3209 pub struct PlaybackServiceServer<T> { ··· 2734 3226 max_encoding_message_size: None, 2735 3227 } 2736 3228 } 2737 - pub fn with_interceptor<F>(inner: T, interceptor: F) -> InterceptedService<Self, F> 3229 + pub fn with_interceptor<F>( 3230 + inner: T, 3231 + interceptor: F, 3232 + ) -> InterceptedService<Self, F> 2738 3233 where 2739 3234 F: tonic::service::Interceptor, 2740 3235 { ··· 2789 3284 "/rockbox.v1alpha1.PlaybackService/Play" => { 2790 3285 #[allow(non_camel_case_types)] 2791 3286 struct PlaySvc<T: PlaybackService>(pub Arc<T>); 2792 - impl<T: PlaybackService> tonic::server::UnaryService<super::PlayRequest> for PlaySvc<T> { 3287 + impl< 3288 + T: PlaybackService, 3289 + > tonic::server::UnaryService<super::PlayRequest> for PlaySvc<T> { 2793 3290 type Response = super::PlayResponse; 2794 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 3291 + type Future = BoxFuture< 3292 + tonic::Response<Self::Response>, 3293 + tonic::Status, 3294 + >; 2795 3295 fn call( 2796 3296 &mut self, 2797 3297 request: tonic::Request<super::PlayRequest>, 2798 3298 ) -> Self::Future { 2799 3299 let inner = Arc::clone(&self.0); 2800 - let fut = 2801 - async move { <T as PlaybackService>::play(&inner, request).await }; 3300 + let fut = async move { 3301 + <T as PlaybackService>::play(&inner, request).await 3302 + }; 2802 3303 Box::pin(fut) 2803 3304 } 2804 3305 } ··· 2827 3328 "/rockbox.v1alpha1.PlaybackService/Pause" => { 2828 3329 #[allow(non_camel_case_types)] 2829 3330 struct PauseSvc<T: PlaybackService>(pub Arc<T>); 2830 - impl<T: PlaybackService> tonic::server::UnaryService<super::PauseRequest> for PauseSvc<T> { 3331 + impl< 3332 + T: PlaybackService, 3333 + > tonic::server::UnaryService<super::PauseRequest> for PauseSvc<T> { 2831 3334 type Response = super::PauseResponse; 2832 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 3335 + type Future = BoxFuture< 3336 + tonic::Response<Self::Response>, 3337 + tonic::Status, 3338 + >; 2833 3339 fn call( 2834 3340 &mut self, 2835 3341 request: tonic::Request<super::PauseRequest>, 2836 3342 ) -> Self::Future { 2837 3343 let inner = Arc::clone(&self.0); 2838 - let fut = 2839 - async move { <T as PlaybackService>::pause(&inner, request).await }; 3344 + let fut = async move { 3345 + <T as PlaybackService>::pause(&inner, request).await 3346 + }; 2840 3347 Box::pin(fut) 2841 3348 } 2842 3349 } ··· 2865 3372 "/rockbox.v1alpha1.PlaybackService/PlayOrPause" => { 2866 3373 #[allow(non_camel_case_types)] 2867 3374 struct PlayOrPauseSvc<T: PlaybackService>(pub Arc<T>); 2868 - impl<T: PlaybackService> tonic::server::UnaryService<super::PlayOrPauseRequest> 2869 - for PlayOrPauseSvc<T> 2870 - { 3375 + impl< 3376 + T: PlaybackService, 3377 + > tonic::server::UnaryService<super::PlayOrPauseRequest> 3378 + for PlayOrPauseSvc<T> { 2871 3379 type Response = super::PlayOrPauseResponse; 2872 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 3380 + type Future = BoxFuture< 3381 + tonic::Response<Self::Response>, 3382 + tonic::Status, 3383 + >; 2873 3384 fn call( 2874 3385 &mut self, 2875 3386 request: tonic::Request<super::PlayOrPauseRequest>, ··· 2906 3417 "/rockbox.v1alpha1.PlaybackService/Resume" => { 2907 3418 #[allow(non_camel_case_types)] 2908 3419 struct ResumeSvc<T: PlaybackService>(pub Arc<T>); 2909 - impl<T: PlaybackService> tonic::server::UnaryService<super::ResumeRequest> for ResumeSvc<T> { 3420 + impl< 3421 + T: PlaybackService, 3422 + > tonic::server::UnaryService<super::ResumeRequest> 3423 + for ResumeSvc<T> { 2910 3424 type Response = super::ResumeResponse; 2911 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 3425 + type Future = BoxFuture< 3426 + tonic::Response<Self::Response>, 3427 + tonic::Status, 3428 + >; 2912 3429 fn call( 2913 3430 &mut self, 2914 3431 request: tonic::Request<super::ResumeRequest>, ··· 2945 3462 "/rockbox.v1alpha1.PlaybackService/Next" => { 2946 3463 #[allow(non_camel_case_types)] 2947 3464 struct NextSvc<T: PlaybackService>(pub Arc<T>); 2948 - impl<T: PlaybackService> tonic::server::UnaryService<super::NextRequest> for NextSvc<T> { 3465 + impl< 3466 + T: PlaybackService, 3467 + > tonic::server::UnaryService<super::NextRequest> for NextSvc<T> { 2949 3468 type Response = super::NextResponse; 2950 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 3469 + type Future = BoxFuture< 3470 + tonic::Response<Self::Response>, 3471 + tonic::Status, 3472 + >; 2951 3473 fn call( 2952 3474 &mut self, 2953 3475 request: tonic::Request<super::NextRequest>, 2954 3476 ) -> Self::Future { 2955 3477 let inner = Arc::clone(&self.0); 2956 - let fut = 2957 - async move { <T as PlaybackService>::next(&inner, request).await }; 3478 + let fut = async move { 3479 + <T as PlaybackService>::next(&inner, request).await 3480 + }; 2958 3481 Box::pin(fut) 2959 3482 } 2960 3483 } ··· 2983 3506 "/rockbox.v1alpha1.PlaybackService/Previous" => { 2984 3507 #[allow(non_camel_case_types)] 2985 3508 struct PreviousSvc<T: PlaybackService>(pub Arc<T>); 2986 - impl<T: PlaybackService> tonic::server::UnaryService<super::PreviousRequest> for PreviousSvc<T> { 3509 + impl< 3510 + T: PlaybackService, 3511 + > tonic::server::UnaryService<super::PreviousRequest> 3512 + for PreviousSvc<T> { 2987 3513 type Response = super::PreviousResponse; 2988 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 3514 + type Future = BoxFuture< 3515 + tonic::Response<Self::Response>, 3516 + tonic::Status, 3517 + >; 2989 3518 fn call( 2990 3519 &mut self, 2991 3520 request: tonic::Request<super::PreviousRequest>, ··· 3022 3551 "/rockbox.v1alpha1.PlaybackService/FastForwardRewind" => { 3023 3552 #[allow(non_camel_case_types)] 3024 3553 struct FastForwardRewindSvc<T: PlaybackService>(pub Arc<T>); 3025 - impl<T: PlaybackService> 3026 - tonic::server::UnaryService<super::FastForwardRewindRequest> 3027 - for FastForwardRewindSvc<T> 3028 - { 3554 + impl< 3555 + T: PlaybackService, 3556 + > tonic::server::UnaryService<super::FastForwardRewindRequest> 3557 + for FastForwardRewindSvc<T> { 3029 3558 type Response = super::FastForwardRewindResponse; 3030 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 3559 + type Future = BoxFuture< 3560 + tonic::Response<Self::Response>, 3561 + tonic::Status, 3562 + >; 3031 3563 fn call( 3032 3564 &mut self, 3033 3565 request: tonic::Request<super::FastForwardRewindRequest>, 3034 3566 ) -> Self::Future { 3035 3567 let inner = Arc::clone(&self.0); 3036 3568 let fut = async move { 3037 - <T as PlaybackService>::fast_forward_rewind(&inner, request).await 3569 + <T as PlaybackService>::fast_forward_rewind(&inner, request) 3570 + .await 3038 3571 }; 3039 3572 Box::pin(fut) 3040 3573 } ··· 3064 3597 "/rockbox.v1alpha1.PlaybackService/Status" => { 3065 3598 #[allow(non_camel_case_types)] 3066 3599 struct StatusSvc<T: PlaybackService>(pub Arc<T>); 3067 - impl<T: PlaybackService> tonic::server::UnaryService<super::StatusRequest> for StatusSvc<T> { 3600 + impl< 3601 + T: PlaybackService, 3602 + > tonic::server::UnaryService<super::StatusRequest> 3603 + for StatusSvc<T> { 3068 3604 type Response = super::StatusResponse; 3069 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 3605 + type Future = BoxFuture< 3606 + tonic::Response<Self::Response>, 3607 + tonic::Status, 3608 + >; 3070 3609 fn call( 3071 3610 &mut self, 3072 3611 request: tonic::Request<super::StatusRequest>, ··· 3103 3642 "/rockbox.v1alpha1.PlaybackService/CurrentTrack" => { 3104 3643 #[allow(non_camel_case_types)] 3105 3644 struct CurrentTrackSvc<T: PlaybackService>(pub Arc<T>); 3106 - impl<T: PlaybackService> tonic::server::UnaryService<super::CurrentTrackRequest> 3107 - for CurrentTrackSvc<T> 3108 - { 3645 + impl< 3646 + T: PlaybackService, 3647 + > tonic::server::UnaryService<super::CurrentTrackRequest> 3648 + for CurrentTrackSvc<T> { 3109 3649 type Response = super::CurrentTrackResponse; 3110 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 3650 + type Future = BoxFuture< 3651 + tonic::Response<Self::Response>, 3652 + tonic::Status, 3653 + >; 3111 3654 fn call( 3112 3655 &mut self, 3113 3656 request: tonic::Request<super::CurrentTrackRequest>, ··· 3144 3687 "/rockbox.v1alpha1.PlaybackService/NextTrack" => { 3145 3688 #[allow(non_camel_case_types)] 3146 3689 struct NextTrackSvc<T: PlaybackService>(pub Arc<T>); 3147 - impl<T: PlaybackService> tonic::server::UnaryService<super::NextTrackRequest> for NextTrackSvc<T> { 3690 + impl< 3691 + T: PlaybackService, 3692 + > tonic::server::UnaryService<super::NextTrackRequest> 3693 + for NextTrackSvc<T> { 3148 3694 type Response = super::NextTrackResponse; 3149 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 3695 + type Future = BoxFuture< 3696 + tonic::Response<Self::Response>, 3697 + tonic::Status, 3698 + >; 3150 3699 fn call( 3151 3700 &mut self, 3152 3701 request: tonic::Request<super::NextTrackRequest>, ··· 3183 3732 "/rockbox.v1alpha1.PlaybackService/FlushAndReloadTracks" => { 3184 3733 #[allow(non_camel_case_types)] 3185 3734 struct FlushAndReloadTracksSvc<T: PlaybackService>(pub Arc<T>); 3186 - impl<T: PlaybackService> 3187 - tonic::server::UnaryService<super::FlushAndReloadTracksRequest> 3188 - for FlushAndReloadTracksSvc<T> 3189 - { 3735 + impl< 3736 + T: PlaybackService, 3737 + > tonic::server::UnaryService<super::FlushAndReloadTracksRequest> 3738 + for FlushAndReloadTracksSvc<T> { 3190 3739 type Response = super::FlushAndReloadTracksResponse; 3191 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 3740 + type Future = BoxFuture< 3741 + tonic::Response<Self::Response>, 3742 + tonic::Status, 3743 + >; 3192 3744 fn call( 3193 3745 &mut self, 3194 3746 request: tonic::Request<super::FlushAndReloadTracksRequest>, 3195 3747 ) -> Self::Future { 3196 3748 let inner = Arc::clone(&self.0); 3197 3749 let fut = async move { 3198 - <T as PlaybackService>::flush_and_reload_tracks(&inner, request) 3750 + <T as PlaybackService>::flush_and_reload_tracks( 3751 + &inner, 3752 + request, 3753 + ) 3199 3754 .await 3200 3755 }; 3201 3756 Box::pin(fut) ··· 3226 3781 "/rockbox.v1alpha1.PlaybackService/GetFilePosition" => { 3227 3782 #[allow(non_camel_case_types)] 3228 3783 struct GetFilePositionSvc<T: PlaybackService>(pub Arc<T>); 3229 - impl<T: PlaybackService> 3230 - tonic::server::UnaryService<super::GetFilePositionRequest> 3231 - for GetFilePositionSvc<T> 3232 - { 3784 + impl< 3785 + T: PlaybackService, 3786 + > tonic::server::UnaryService<super::GetFilePositionRequest> 3787 + for GetFilePositionSvc<T> { 3233 3788 type Response = super::GetFilePositionResponse; 3234 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 3789 + type Future = BoxFuture< 3790 + tonic::Response<Self::Response>, 3791 + tonic::Status, 3792 + >; 3235 3793 fn call( 3236 3794 &mut self, 3237 3795 request: tonic::Request<super::GetFilePositionRequest>, 3238 3796 ) -> Self::Future { 3239 3797 let inner = Arc::clone(&self.0); 3240 3798 let fut = async move { 3241 - <T as PlaybackService>::get_file_position(&inner, request).await 3799 + <T as PlaybackService>::get_file_position(&inner, request) 3800 + .await 3242 3801 }; 3243 3802 Box::pin(fut) 3244 3803 } ··· 3268 3827 "/rockbox.v1alpha1.PlaybackService/HardStop" => { 3269 3828 #[allow(non_camel_case_types)] 3270 3829 struct HardStopSvc<T: PlaybackService>(pub Arc<T>); 3271 - impl<T: PlaybackService> tonic::server::UnaryService<super::HardStopRequest> for HardStopSvc<T> { 3830 + impl< 3831 + T: PlaybackService, 3832 + > tonic::server::UnaryService<super::HardStopRequest> 3833 + for HardStopSvc<T> { 3272 3834 type Response = super::HardStopResponse; 3273 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 3835 + type Future = BoxFuture< 3836 + tonic::Response<Self::Response>, 3837 + tonic::Status, 3838 + >; 3274 3839 fn call( 3275 3840 &mut self, 3276 3841 request: tonic::Request<super::HardStopRequest>, ··· 3307 3872 "/rockbox.v1alpha1.PlaybackService/PlayAlbum" => { 3308 3873 #[allow(non_camel_case_types)] 3309 3874 struct PlayAlbumSvc<T: PlaybackService>(pub Arc<T>); 3310 - impl<T: PlaybackService> tonic::server::UnaryService<super::PlayAlbumRequest> for PlayAlbumSvc<T> { 3875 + impl< 3876 + T: PlaybackService, 3877 + > tonic::server::UnaryService<super::PlayAlbumRequest> 3878 + for PlayAlbumSvc<T> { 3311 3879 type Response = super::PlayAlbumResponse; 3312 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 3880 + type Future = BoxFuture< 3881 + tonic::Response<Self::Response>, 3882 + tonic::Status, 3883 + >; 3313 3884 fn call( 3314 3885 &mut self, 3315 3886 request: tonic::Request<super::PlayAlbumRequest>, ··· 3346 3917 "/rockbox.v1alpha1.PlaybackService/PlayArtistTracks" => { 3347 3918 #[allow(non_camel_case_types)] 3348 3919 struct PlayArtistTracksSvc<T: PlaybackService>(pub Arc<T>); 3349 - impl<T: PlaybackService> 3350 - tonic::server::UnaryService<super::PlayArtistTracksRequest> 3351 - for PlayArtistTracksSvc<T> 3352 - { 3920 + impl< 3921 + T: PlaybackService, 3922 + > tonic::server::UnaryService<super::PlayArtistTracksRequest> 3923 + for PlayArtistTracksSvc<T> { 3353 3924 type Response = super::PlayArtistTracksResponse; 3354 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 3925 + type Future = BoxFuture< 3926 + tonic::Response<Self::Response>, 3927 + tonic::Status, 3928 + >; 3355 3929 fn call( 3356 3930 &mut self, 3357 3931 request: tonic::Request<super::PlayArtistTracksRequest>, 3358 3932 ) -> Self::Future { 3359 3933 let inner = Arc::clone(&self.0); 3360 3934 let fut = async move { 3361 - <T as PlaybackService>::play_artist_tracks(&inner, request).await 3935 + <T as PlaybackService>::play_artist_tracks(&inner, request) 3936 + .await 3362 3937 }; 3363 3938 Box::pin(fut) 3364 3939 } ··· 3388 3963 "/rockbox.v1alpha1.PlaybackService/PlayPlaylist" => { 3389 3964 #[allow(non_camel_case_types)] 3390 3965 struct PlayPlaylistSvc<T: PlaybackService>(pub Arc<T>); 3391 - impl<T: PlaybackService> tonic::server::UnaryService<super::PlayPlaylistRequest> 3392 - for PlayPlaylistSvc<T> 3393 - { 3966 + impl< 3967 + T: PlaybackService, 3968 + > tonic::server::UnaryService<super::PlayPlaylistRequest> 3969 + for PlayPlaylistSvc<T> { 3394 3970 type Response = super::PlayPlaylistResponse; 3395 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 3971 + type Future = BoxFuture< 3972 + tonic::Response<Self::Response>, 3973 + tonic::Status, 3974 + >; 3396 3975 fn call( 3397 3976 &mut self, 3398 3977 request: tonic::Request<super::PlayPlaylistRequest>, ··· 3429 4008 "/rockbox.v1alpha1.PlaybackService/PlayDirectory" => { 3430 4009 #[allow(non_camel_case_types)] 3431 4010 struct PlayDirectorySvc<T: PlaybackService>(pub Arc<T>); 3432 - impl<T: PlaybackService> 3433 - tonic::server::UnaryService<super::PlayDirectoryRequest> 3434 - for PlayDirectorySvc<T> 3435 - { 4011 + impl< 4012 + T: PlaybackService, 4013 + > tonic::server::UnaryService<super::PlayDirectoryRequest> 4014 + for PlayDirectorySvc<T> { 3436 4015 type Response = super::PlayDirectoryResponse; 3437 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4016 + type Future = BoxFuture< 4017 + tonic::Response<Self::Response>, 4018 + tonic::Status, 4019 + >; 3438 4020 fn call( 3439 4021 &mut self, 3440 4022 request: tonic::Request<super::PlayDirectoryRequest>, 3441 4023 ) -> Self::Future { 3442 4024 let inner = Arc::clone(&self.0); 3443 4025 let fut = async move { 3444 - <T as PlaybackService>::play_directory(&inner, request).await 4026 + <T as PlaybackService>::play_directory(&inner, request) 4027 + .await 3445 4028 }; 3446 4029 Box::pin(fut) 3447 4030 } ··· 3471 4054 "/rockbox.v1alpha1.PlaybackService/PlayMusicDirectory" => { 3472 4055 #[allow(non_camel_case_types)] 3473 4056 struct PlayMusicDirectorySvc<T: PlaybackService>(pub Arc<T>); 3474 - impl<T: PlaybackService> 3475 - tonic::server::UnaryService<super::PlayMusicDirectoryRequest> 3476 - for PlayMusicDirectorySvc<T> 3477 - { 4057 + impl< 4058 + T: PlaybackService, 4059 + > tonic::server::UnaryService<super::PlayMusicDirectoryRequest> 4060 + for PlayMusicDirectorySvc<T> { 3478 4061 type Response = super::PlayMusicDirectoryResponse; 3479 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4062 + type Future = BoxFuture< 4063 + tonic::Response<Self::Response>, 4064 + tonic::Status, 4065 + >; 3480 4066 fn call( 3481 4067 &mut self, 3482 4068 request: tonic::Request<super::PlayMusicDirectoryRequest>, 3483 4069 ) -> Self::Future { 3484 4070 let inner = Arc::clone(&self.0); 3485 4071 let fut = async move { 3486 - <T as PlaybackService>::play_music_directory(&inner, request).await 4072 + <T as PlaybackService>::play_music_directory( 4073 + &inner, 4074 + request, 4075 + ) 4076 + .await 3487 4077 }; 3488 4078 Box::pin(fut) 3489 4079 } ··· 3513 4103 "/rockbox.v1alpha1.PlaybackService/PlayTrack" => { 3514 4104 #[allow(non_camel_case_types)] 3515 4105 struct PlayTrackSvc<T: PlaybackService>(pub Arc<T>); 3516 - impl<T: PlaybackService> tonic::server::UnaryService<super::PlayTrackRequest> for PlayTrackSvc<T> { 4106 + impl< 4107 + T: PlaybackService, 4108 + > tonic::server::UnaryService<super::PlayTrackRequest> 4109 + for PlayTrackSvc<T> { 3517 4110 type Response = super::PlayTrackResponse; 3518 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4111 + type Future = BoxFuture< 4112 + tonic::Response<Self::Response>, 4113 + tonic::Status, 4114 + >; 3519 4115 fn call( 3520 4116 &mut self, 3521 4117 request: tonic::Request<super::PlayTrackRequest>, ··· 3552 4148 "/rockbox.v1alpha1.PlaybackService/PlayLikedTracks" => { 3553 4149 #[allow(non_camel_case_types)] 3554 4150 struct PlayLikedTracksSvc<T: PlaybackService>(pub Arc<T>); 3555 - impl<T: PlaybackService> 3556 - tonic::server::UnaryService<super::PlayLikedTracksRequest> 3557 - for PlayLikedTracksSvc<T> 3558 - { 4151 + impl< 4152 + T: PlaybackService, 4153 + > tonic::server::UnaryService<super::PlayLikedTracksRequest> 4154 + for PlayLikedTracksSvc<T> { 3559 4155 type Response = super::PlayLikedTracksResponse; 3560 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4156 + type Future = BoxFuture< 4157 + tonic::Response<Self::Response>, 4158 + tonic::Status, 4159 + >; 3561 4160 fn call( 3562 4161 &mut self, 3563 4162 request: tonic::Request<super::PlayLikedTracksRequest>, 3564 4163 ) -> Self::Future { 3565 4164 let inner = Arc::clone(&self.0); 3566 4165 let fut = async move { 3567 - <T as PlaybackService>::play_liked_tracks(&inner, request).await 4166 + <T as PlaybackService>::play_liked_tracks(&inner, request) 4167 + .await 3568 4168 }; 3569 4169 Box::pin(fut) 3570 4170 } ··· 3594 4194 "/rockbox.v1alpha1.PlaybackService/PlayAllTracks" => { 3595 4195 #[allow(non_camel_case_types)] 3596 4196 struct PlayAllTracksSvc<T: PlaybackService>(pub Arc<T>); 3597 - impl<T: PlaybackService> 3598 - tonic::server::UnaryService<super::PlayAllTracksRequest> 3599 - for PlayAllTracksSvc<T> 3600 - { 4197 + impl< 4198 + T: PlaybackService, 4199 + > tonic::server::UnaryService<super::PlayAllTracksRequest> 4200 + for PlayAllTracksSvc<T> { 3601 4201 type Response = super::PlayAllTracksResponse; 3602 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4202 + type Future = BoxFuture< 4203 + tonic::Response<Self::Response>, 4204 + tonic::Status, 4205 + >; 3603 4206 fn call( 3604 4207 &mut self, 3605 4208 request: tonic::Request<super::PlayAllTracksRequest>, 3606 4209 ) -> Self::Future { 3607 4210 let inner = Arc::clone(&self.0); 3608 4211 let fut = async move { 3609 - <T as PlaybackService>::play_all_tracks(&inner, request).await 4212 + <T as PlaybackService>::play_all_tracks(&inner, request) 4213 + .await 3610 4214 }; 3611 4215 Box::pin(fut) 3612 4216 } ··· 3636 4240 "/rockbox.v1alpha1.PlaybackService/StreamCurrentTrack" => { 3637 4241 #[allow(non_camel_case_types)] 3638 4242 struct StreamCurrentTrackSvc<T: PlaybackService>(pub Arc<T>); 3639 - impl<T: PlaybackService> 3640 - tonic::server::ServerStreamingService<super::StreamCurrentTrackRequest> 3641 - for StreamCurrentTrackSvc<T> 3642 - { 4243 + impl< 4244 + T: PlaybackService, 4245 + > tonic::server::ServerStreamingService< 4246 + super::StreamCurrentTrackRequest, 4247 + > for StreamCurrentTrackSvc<T> { 3643 4248 type Response = super::CurrentTrackResponse; 3644 4249 type ResponseStream = T::StreamCurrentTrackStream; 3645 - type Future = 3646 - BoxFuture<tonic::Response<Self::ResponseStream>, tonic::Status>; 4250 + type Future = BoxFuture< 4251 + tonic::Response<Self::ResponseStream>, 4252 + tonic::Status, 4253 + >; 3647 4254 fn call( 3648 4255 &mut self, 3649 4256 request: tonic::Request<super::StreamCurrentTrackRequest>, 3650 4257 ) -> Self::Future { 3651 4258 let inner = Arc::clone(&self.0); 3652 4259 let fut = async move { 3653 - <T as PlaybackService>::stream_current_track(&inner, request).await 4260 + <T as PlaybackService>::stream_current_track( 4261 + &inner, 4262 + request, 4263 + ) 4264 + .await 3654 4265 }; 3655 4266 Box::pin(fut) 3656 4267 } ··· 3680 4291 "/rockbox.v1alpha1.PlaybackService/StreamStatus" => { 3681 4292 #[allow(non_camel_case_types)] 3682 4293 struct StreamStatusSvc<T: PlaybackService>(pub Arc<T>); 3683 - impl<T: PlaybackService> 3684 - tonic::server::ServerStreamingService<super::StreamStatusRequest> 3685 - for StreamStatusSvc<T> 3686 - { 4294 + impl< 4295 + T: PlaybackService, 4296 + > tonic::server::ServerStreamingService<super::StreamStatusRequest> 4297 + for StreamStatusSvc<T> { 3687 4298 type Response = super::StatusResponse; 3688 4299 type ResponseStream = T::StreamStatusStream; 3689 - type Future = 3690 - BoxFuture<tonic::Response<Self::ResponseStream>, tonic::Status>; 4300 + type Future = BoxFuture< 4301 + tonic::Response<Self::ResponseStream>, 4302 + tonic::Status, 4303 + >; 3691 4304 fn call( 3692 4305 &mut self, 3693 4306 request: tonic::Request<super::StreamStatusRequest>, ··· 3724 4337 "/rockbox.v1alpha1.PlaybackService/StreamPlaylist" => { 3725 4338 #[allow(non_camel_case_types)] 3726 4339 struct StreamPlaylistSvc<T: PlaybackService>(pub Arc<T>); 3727 - impl<T: PlaybackService> 3728 - tonic::server::ServerStreamingService<super::StreamPlaylistRequest> 3729 - for StreamPlaylistSvc<T> 3730 - { 4340 + impl< 4341 + T: PlaybackService, 4342 + > tonic::server::ServerStreamingService<super::StreamPlaylistRequest> 4343 + for StreamPlaylistSvc<T> { 3731 4344 type Response = super::PlaylistResponse; 3732 4345 type ResponseStream = T::StreamPlaylistStream; 3733 - type Future = 3734 - BoxFuture<tonic::Response<Self::ResponseStream>, tonic::Status>; 4346 + type Future = BoxFuture< 4347 + tonic::Response<Self::ResponseStream>, 4348 + tonic::Status, 4349 + >; 3735 4350 fn call( 3736 4351 &mut self, 3737 4352 request: tonic::Request<super::StreamPlaylistRequest>, 3738 4353 ) -> Self::Future { 3739 4354 let inner = Arc::clone(&self.0); 3740 4355 let fut = async move { 3741 - <T as PlaybackService>::stream_playlist(&inner, request).await 4356 + <T as PlaybackService>::stream_playlist(&inner, request) 4357 + .await 3742 4358 }; 3743 4359 Box::pin(fut) 3744 4360 } ··· 3765 4381 }; 3766 4382 Box::pin(fut) 3767 4383 } 3768 - _ => Box::pin(async move { 3769 - let mut response = http::Response::new(empty_body()); 3770 - let headers = response.headers_mut(); 3771 - headers.insert( 3772 - tonic::Status::GRPC_STATUS, 3773 - (tonic::Code::Unimplemented as i32).into(), 3774 - ); 3775 - headers.insert( 3776 - http::header::CONTENT_TYPE, 3777 - tonic::metadata::GRPC_CONTENT_TYPE, 3778 - ); 3779 - Ok(response) 3780 - }), 4384 + _ => { 4385 + Box::pin(async move { 4386 + let mut response = http::Response::new(empty_body()); 4387 + let headers = response.headers_mut(); 4388 + headers 4389 + .insert( 4390 + tonic::Status::GRPC_STATUS, 4391 + (tonic::Code::Unimplemented as i32).into(), 4392 + ); 4393 + headers 4394 + .insert( 4395 + http::header::CONTENT_TYPE, 4396 + tonic::metadata::GRPC_CONTENT_TYPE, 4397 + ); 4398 + Ok(response) 4399 + }) 4400 + } 3781 4401 } 3782 4402 } 3783 4403 } ··· 3984 4604 dead_code, 3985 4605 missing_docs, 3986 4606 clippy::wildcard_imports, 3987 - clippy::let_unit_value 4607 + clippy::let_unit_value, 3988 4608 )] 3989 - use tonic::codegen::http::Uri; 3990 4609 use tonic::codegen::*; 4610 + use tonic::codegen::http::Uri; 3991 4611 #[derive(Debug, Clone)] 3992 4612 pub struct PlaylistServiceClient<T> { 3993 4613 inner: tonic::client::Grpc<T>, ··· 4031 4651 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody, 4032 4652 >, 4033 4653 >, 4034 - <T as tonic::codegen::Service<http::Request<tonic::body::BoxBody>>>::Error: 4035 - Into<StdError> + std::marker::Send + std::marker::Sync, 4654 + <T as tonic::codegen::Service< 4655 + http::Request<tonic::body::BoxBody>, 4656 + >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync, 4036 4657 { 4037 4658 PlaylistServiceClient::new(InterceptedService::new(inner, interceptor)) 4038 4659 } ··· 4070 4691 pub async fn get_current( 4071 4692 &mut self, 4072 4693 request: impl tonic::IntoRequest<super::GetCurrentRequest>, 4073 - ) -> std::result::Result<tonic::Response<super::GetCurrentResponse>, tonic::Status> 4074 - { 4075 - self.inner.ready().await.map_err(|e| { 4076 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4077 - })?; 4694 + ) -> std::result::Result< 4695 + tonic::Response<super::GetCurrentResponse>, 4696 + tonic::Status, 4697 + > { 4698 + self.inner 4699 + .ready() 4700 + .await 4701 + .map_err(|e| { 4702 + tonic::Status::unknown( 4703 + format!("Service was not ready: {}", e.into()), 4704 + ) 4705 + })?; 4078 4706 let codec = tonic::codec::ProstCodec::default(); 4079 4707 let path = http::uri::PathAndQuery::from_static( 4080 4708 "/rockbox.v1alpha1.PlaylistService/GetCurrent", 4081 4709 ); 4082 4710 let mut req = request.into_request(); 4083 - req.extensions_mut().insert(GrpcMethod::new( 4084 - "rockbox.v1alpha1.PlaylistService", 4085 - "GetCurrent", 4086 - )); 4711 + req.extensions_mut() 4712 + .insert( 4713 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "GetCurrent"), 4714 + ); 4087 4715 self.inner.unary(req, path, codec).await 4088 4716 } 4089 4717 pub async fn get_resume_info( 4090 4718 &mut self, 4091 4719 request: impl tonic::IntoRequest<super::GetResumeInfoRequest>, 4092 - ) -> std::result::Result<tonic::Response<super::GetResumeInfoResponse>, tonic::Status> 4093 - { 4094 - self.inner.ready().await.map_err(|e| { 4095 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4096 - })?; 4720 + ) -> std::result::Result< 4721 + tonic::Response<super::GetResumeInfoResponse>, 4722 + tonic::Status, 4723 + > { 4724 + self.inner 4725 + .ready() 4726 + .await 4727 + .map_err(|e| { 4728 + tonic::Status::unknown( 4729 + format!("Service was not ready: {}", e.into()), 4730 + ) 4731 + })?; 4097 4732 let codec = tonic::codec::ProstCodec::default(); 4098 4733 let path = http::uri::PathAndQuery::from_static( 4099 4734 "/rockbox.v1alpha1.PlaylistService/GetResumeInfo", 4100 4735 ); 4101 4736 let mut req = request.into_request(); 4102 - req.extensions_mut().insert(GrpcMethod::new( 4103 - "rockbox.v1alpha1.PlaylistService", 4104 - "GetResumeInfo", 4105 - )); 4737 + req.extensions_mut() 4738 + .insert( 4739 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "GetResumeInfo"), 4740 + ); 4106 4741 self.inner.unary(req, path, codec).await 4107 4742 } 4108 4743 pub async fn get_track_info( 4109 4744 &mut self, 4110 4745 request: impl tonic::IntoRequest<super::GetTrackInfoRequest>, 4111 - ) -> std::result::Result<tonic::Response<super::GetTrackInfoResponse>, tonic::Status> 4112 - { 4113 - self.inner.ready().await.map_err(|e| { 4114 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4115 - })?; 4746 + ) -> std::result::Result< 4747 + tonic::Response<super::GetTrackInfoResponse>, 4748 + tonic::Status, 4749 + > { 4750 + self.inner 4751 + .ready() 4752 + .await 4753 + .map_err(|e| { 4754 + tonic::Status::unknown( 4755 + format!("Service was not ready: {}", e.into()), 4756 + ) 4757 + })?; 4116 4758 let codec = tonic::codec::ProstCodec::default(); 4117 4759 let path = http::uri::PathAndQuery::from_static( 4118 4760 "/rockbox.v1alpha1.PlaylistService/GetTrackInfo", 4119 4761 ); 4120 4762 let mut req = request.into_request(); 4121 - req.extensions_mut().insert(GrpcMethod::new( 4122 - "rockbox.v1alpha1.PlaylistService", 4123 - "GetTrackInfo", 4124 - )); 4763 + req.extensions_mut() 4764 + .insert( 4765 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "GetTrackInfo"), 4766 + ); 4125 4767 self.inner.unary(req, path, codec).await 4126 4768 } 4127 4769 pub async fn get_first_index( 4128 4770 &mut self, 4129 4771 request: impl tonic::IntoRequest<super::GetFirstIndexRequest>, 4130 - ) -> std::result::Result<tonic::Response<super::GetFirstIndexResponse>, tonic::Status> 4131 - { 4132 - self.inner.ready().await.map_err(|e| { 4133 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4134 - })?; 4772 + ) -> std::result::Result< 4773 + tonic::Response<super::GetFirstIndexResponse>, 4774 + tonic::Status, 4775 + > { 4776 + self.inner 4777 + .ready() 4778 + .await 4779 + .map_err(|e| { 4780 + tonic::Status::unknown( 4781 + format!("Service was not ready: {}", e.into()), 4782 + ) 4783 + })?; 4135 4784 let codec = tonic::codec::ProstCodec::default(); 4136 4785 let path = http::uri::PathAndQuery::from_static( 4137 4786 "/rockbox.v1alpha1.PlaylistService/GetFirstIndex", 4138 4787 ); 4139 4788 let mut req = request.into_request(); 4140 - req.extensions_mut().insert(GrpcMethod::new( 4141 - "rockbox.v1alpha1.PlaylistService", 4142 - "GetFirstIndex", 4143 - )); 4789 + req.extensions_mut() 4790 + .insert( 4791 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "GetFirstIndex"), 4792 + ); 4144 4793 self.inner.unary(req, path, codec).await 4145 4794 } 4146 4795 pub async fn get_display_index( 4147 4796 &mut self, 4148 4797 request: impl tonic::IntoRequest<super::GetDisplayIndexRequest>, 4149 - ) -> std::result::Result<tonic::Response<super::GetDisplayIndexResponse>, tonic::Status> 4150 - { 4151 - self.inner.ready().await.map_err(|e| { 4152 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4153 - })?; 4798 + ) -> std::result::Result< 4799 + tonic::Response<super::GetDisplayIndexResponse>, 4800 + tonic::Status, 4801 + > { 4802 + self.inner 4803 + .ready() 4804 + .await 4805 + .map_err(|e| { 4806 + tonic::Status::unknown( 4807 + format!("Service was not ready: {}", e.into()), 4808 + ) 4809 + })?; 4154 4810 let codec = tonic::codec::ProstCodec::default(); 4155 4811 let path = http::uri::PathAndQuery::from_static( 4156 4812 "/rockbox.v1alpha1.PlaylistService/GetDisplayIndex", 4157 4813 ); 4158 4814 let mut req = request.into_request(); 4159 - req.extensions_mut().insert(GrpcMethod::new( 4160 - "rockbox.v1alpha1.PlaylistService", 4161 - "GetDisplayIndex", 4162 - )); 4815 + req.extensions_mut() 4816 + .insert( 4817 + GrpcMethod::new( 4818 + "rockbox.v1alpha1.PlaylistService", 4819 + "GetDisplayIndex", 4820 + ), 4821 + ); 4163 4822 self.inner.unary(req, path, codec).await 4164 4823 } 4165 4824 pub async fn amount( 4166 4825 &mut self, 4167 4826 request: impl tonic::IntoRequest<super::AmountRequest>, 4168 4827 ) -> std::result::Result<tonic::Response<super::AmountResponse>, tonic::Status> { 4169 - self.inner.ready().await.map_err(|e| { 4170 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4171 - })?; 4828 + self.inner 4829 + .ready() 4830 + .await 4831 + .map_err(|e| { 4832 + tonic::Status::unknown( 4833 + format!("Service was not ready: {}", e.into()), 4834 + ) 4835 + })?; 4172 4836 let codec = tonic::codec::ProstCodec::default(); 4173 - let path = 4174 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaylistService/Amount"); 4837 + let path = http::uri::PathAndQuery::from_static( 4838 + "/rockbox.v1alpha1.PlaylistService/Amount", 4839 + ); 4175 4840 let mut req = request.into_request(); 4176 - req.extensions_mut().insert(GrpcMethod::new( 4177 - "rockbox.v1alpha1.PlaylistService", 4178 - "Amount", 4179 - )); 4841 + req.extensions_mut() 4842 + .insert(GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "Amount")); 4180 4843 self.inner.unary(req, path, codec).await 4181 4844 } 4182 4845 pub async fn playlist_resume( 4183 4846 &mut self, 4184 4847 request: impl tonic::IntoRequest<super::PlaylistResumeRequest>, 4185 - ) -> std::result::Result<tonic::Response<super::PlaylistResumeResponse>, tonic::Status> 4186 - { 4187 - self.inner.ready().await.map_err(|e| { 4188 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4189 - })?; 4848 + ) -> std::result::Result< 4849 + tonic::Response<super::PlaylistResumeResponse>, 4850 + tonic::Status, 4851 + > { 4852 + self.inner 4853 + .ready() 4854 + .await 4855 + .map_err(|e| { 4856 + tonic::Status::unknown( 4857 + format!("Service was not ready: {}", e.into()), 4858 + ) 4859 + })?; 4190 4860 let codec = tonic::codec::ProstCodec::default(); 4191 4861 let path = http::uri::PathAndQuery::from_static( 4192 4862 "/rockbox.v1alpha1.PlaylistService/PlaylistResume", 4193 4863 ); 4194 4864 let mut req = request.into_request(); 4195 - req.extensions_mut().insert(GrpcMethod::new( 4196 - "rockbox.v1alpha1.PlaylistService", 4197 - "PlaylistResume", 4198 - )); 4865 + req.extensions_mut() 4866 + .insert( 4867 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "PlaylistResume"), 4868 + ); 4199 4869 self.inner.unary(req, path, codec).await 4200 4870 } 4201 4871 pub async fn resume_track( 4202 4872 &mut self, 4203 4873 request: impl tonic::IntoRequest<super::ResumeTrackRequest>, 4204 - ) -> std::result::Result<tonic::Response<super::ResumeTrackResponse>, tonic::Status> 4205 - { 4206 - self.inner.ready().await.map_err(|e| { 4207 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4208 - })?; 4874 + ) -> std::result::Result< 4875 + tonic::Response<super::ResumeTrackResponse>, 4876 + tonic::Status, 4877 + > { 4878 + self.inner 4879 + .ready() 4880 + .await 4881 + .map_err(|e| { 4882 + tonic::Status::unknown( 4883 + format!("Service was not ready: {}", e.into()), 4884 + ) 4885 + })?; 4209 4886 let codec = tonic::codec::ProstCodec::default(); 4210 4887 let path = http::uri::PathAndQuery::from_static( 4211 4888 "/rockbox.v1alpha1.PlaylistService/ResumeTrack", 4212 4889 ); 4213 4890 let mut req = request.into_request(); 4214 - req.extensions_mut().insert(GrpcMethod::new( 4215 - "rockbox.v1alpha1.PlaylistService", 4216 - "ResumeTrack", 4217 - )); 4891 + req.extensions_mut() 4892 + .insert( 4893 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "ResumeTrack"), 4894 + ); 4218 4895 self.inner.unary(req, path, codec).await 4219 4896 } 4220 4897 pub async fn set_modified( 4221 4898 &mut self, 4222 4899 request: impl tonic::IntoRequest<super::SetModifiedRequest>, 4223 - ) -> std::result::Result<tonic::Response<super::SetModifiedResponse>, tonic::Status> 4224 - { 4225 - self.inner.ready().await.map_err(|e| { 4226 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4227 - })?; 4900 + ) -> std::result::Result< 4901 + tonic::Response<super::SetModifiedResponse>, 4902 + tonic::Status, 4903 + > { 4904 + self.inner 4905 + .ready() 4906 + .await 4907 + .map_err(|e| { 4908 + tonic::Status::unknown( 4909 + format!("Service was not ready: {}", e.into()), 4910 + ) 4911 + })?; 4228 4912 let codec = tonic::codec::ProstCodec::default(); 4229 4913 let path = http::uri::PathAndQuery::from_static( 4230 4914 "/rockbox.v1alpha1.PlaylistService/SetModified", 4231 4915 ); 4232 4916 let mut req = request.into_request(); 4233 - req.extensions_mut().insert(GrpcMethod::new( 4234 - "rockbox.v1alpha1.PlaylistService", 4235 - "SetModified", 4236 - )); 4917 + req.extensions_mut() 4918 + .insert( 4919 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "SetModified"), 4920 + ); 4237 4921 self.inner.unary(req, path, codec).await 4238 4922 } 4239 4923 pub async fn start( 4240 4924 &mut self, 4241 4925 request: impl tonic::IntoRequest<super::StartRequest>, 4242 4926 ) -> std::result::Result<tonic::Response<super::StartResponse>, tonic::Status> { 4243 - self.inner.ready().await.map_err(|e| { 4244 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4245 - })?; 4927 + self.inner 4928 + .ready() 4929 + .await 4930 + .map_err(|e| { 4931 + tonic::Status::unknown( 4932 + format!("Service was not ready: {}", e.into()), 4933 + ) 4934 + })?; 4246 4935 let codec = tonic::codec::ProstCodec::default(); 4247 - let path = 4248 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaylistService/Start"); 4936 + let path = http::uri::PathAndQuery::from_static( 4937 + "/rockbox.v1alpha1.PlaylistService/Start", 4938 + ); 4249 4939 let mut req = request.into_request(); 4250 4940 req.extensions_mut() 4251 4941 .insert(GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "Start")); ··· 4255 4945 &mut self, 4256 4946 request: impl tonic::IntoRequest<super::SyncRequest>, 4257 4947 ) -> std::result::Result<tonic::Response<super::SyncResponse>, tonic::Status> { 4258 - self.inner.ready().await.map_err(|e| { 4259 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4260 - })?; 4948 + self.inner 4949 + .ready() 4950 + .await 4951 + .map_err(|e| { 4952 + tonic::Status::unknown( 4953 + format!("Service was not ready: {}", e.into()), 4954 + ) 4955 + })?; 4261 4956 let codec = tonic::codec::ProstCodec::default(); 4262 - let path = 4263 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaylistService/Sync"); 4957 + let path = http::uri::PathAndQuery::from_static( 4958 + "/rockbox.v1alpha1.PlaylistService/Sync", 4959 + ); 4264 4960 let mut req = request.into_request(); 4265 4961 req.extensions_mut() 4266 4962 .insert(GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "Sync")); ··· 4269 4965 pub async fn remove_all_tracks( 4270 4966 &mut self, 4271 4967 request: impl tonic::IntoRequest<super::RemoveAllTracksRequest>, 4272 - ) -> std::result::Result<tonic::Response<super::RemoveAllTracksResponse>, tonic::Status> 4273 - { 4274 - self.inner.ready().await.map_err(|e| { 4275 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4276 - })?; 4968 + ) -> std::result::Result< 4969 + tonic::Response<super::RemoveAllTracksResponse>, 4970 + tonic::Status, 4971 + > { 4972 + self.inner 4973 + .ready() 4974 + .await 4975 + .map_err(|e| { 4976 + tonic::Status::unknown( 4977 + format!("Service was not ready: {}", e.into()), 4978 + ) 4979 + })?; 4277 4980 let codec = tonic::codec::ProstCodec::default(); 4278 4981 let path = http::uri::PathAndQuery::from_static( 4279 4982 "/rockbox.v1alpha1.PlaylistService/RemoveAllTracks", 4280 4983 ); 4281 4984 let mut req = request.into_request(); 4282 - req.extensions_mut().insert(GrpcMethod::new( 4283 - "rockbox.v1alpha1.PlaylistService", 4284 - "RemoveAllTracks", 4285 - )); 4985 + req.extensions_mut() 4986 + .insert( 4987 + GrpcMethod::new( 4988 + "rockbox.v1alpha1.PlaylistService", 4989 + "RemoveAllTracks", 4990 + ), 4991 + ); 4286 4992 self.inner.unary(req, path, codec).await 4287 4993 } 4288 4994 pub async fn remove_tracks( 4289 4995 &mut self, 4290 4996 request: impl tonic::IntoRequest<super::RemoveTracksRequest>, 4291 - ) -> std::result::Result<tonic::Response<super::RemoveTracksResponse>, tonic::Status> 4292 - { 4293 - self.inner.ready().await.map_err(|e| { 4294 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4295 - })?; 4997 + ) -> std::result::Result< 4998 + tonic::Response<super::RemoveTracksResponse>, 4999 + tonic::Status, 5000 + > { 5001 + self.inner 5002 + .ready() 5003 + .await 5004 + .map_err(|e| { 5005 + tonic::Status::unknown( 5006 + format!("Service was not ready: {}", e.into()), 5007 + ) 5008 + })?; 4296 5009 let codec = tonic::codec::ProstCodec::default(); 4297 5010 let path = http::uri::PathAndQuery::from_static( 4298 5011 "/rockbox.v1alpha1.PlaylistService/RemoveTracks", 4299 5012 ); 4300 5013 let mut req = request.into_request(); 4301 - req.extensions_mut().insert(GrpcMethod::new( 4302 - "rockbox.v1alpha1.PlaylistService", 4303 - "RemoveTracks", 4304 - )); 5014 + req.extensions_mut() 5015 + .insert( 5016 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "RemoveTracks"), 5017 + ); 4305 5018 self.inner.unary(req, path, codec).await 4306 5019 } 4307 5020 pub async fn create_playlist( 4308 5021 &mut self, 4309 5022 request: impl tonic::IntoRequest<super::CreatePlaylistRequest>, 4310 - ) -> std::result::Result<tonic::Response<super::CreatePlaylistResponse>, tonic::Status> 4311 - { 4312 - self.inner.ready().await.map_err(|e| { 4313 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4314 - })?; 5023 + ) -> std::result::Result< 5024 + tonic::Response<super::CreatePlaylistResponse>, 5025 + tonic::Status, 5026 + > { 5027 + self.inner 5028 + .ready() 5029 + .await 5030 + .map_err(|e| { 5031 + tonic::Status::unknown( 5032 + format!("Service was not ready: {}", e.into()), 5033 + ) 5034 + })?; 4315 5035 let codec = tonic::codec::ProstCodec::default(); 4316 5036 let path = http::uri::PathAndQuery::from_static( 4317 5037 "/rockbox.v1alpha1.PlaylistService/CreatePlaylist", 4318 5038 ); 4319 5039 let mut req = request.into_request(); 4320 - req.extensions_mut().insert(GrpcMethod::new( 4321 - "rockbox.v1alpha1.PlaylistService", 4322 - "CreatePlaylist", 4323 - )); 5040 + req.extensions_mut() 5041 + .insert( 5042 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "CreatePlaylist"), 5043 + ); 4324 5044 self.inner.unary(req, path, codec).await 4325 5045 } 4326 5046 pub async fn insert_tracks( 4327 5047 &mut self, 4328 5048 request: impl tonic::IntoRequest<super::InsertTracksRequest>, 4329 - ) -> std::result::Result<tonic::Response<super::InsertTracksResponse>, tonic::Status> 4330 - { 4331 - self.inner.ready().await.map_err(|e| { 4332 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4333 - })?; 5049 + ) -> std::result::Result< 5050 + tonic::Response<super::InsertTracksResponse>, 5051 + tonic::Status, 5052 + > { 5053 + self.inner 5054 + .ready() 5055 + .await 5056 + .map_err(|e| { 5057 + tonic::Status::unknown( 5058 + format!("Service was not ready: {}", e.into()), 5059 + ) 5060 + })?; 4334 5061 let codec = tonic::codec::ProstCodec::default(); 4335 5062 let path = http::uri::PathAndQuery::from_static( 4336 5063 "/rockbox.v1alpha1.PlaylistService/InsertTracks", 4337 5064 ); 4338 5065 let mut req = request.into_request(); 4339 - req.extensions_mut().insert(GrpcMethod::new( 4340 - "rockbox.v1alpha1.PlaylistService", 4341 - "InsertTracks", 4342 - )); 5066 + req.extensions_mut() 5067 + .insert( 5068 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "InsertTracks"), 5069 + ); 4343 5070 self.inner.unary(req, path, codec).await 4344 5071 } 4345 5072 pub async fn insert_directory( 4346 5073 &mut self, 4347 5074 request: impl tonic::IntoRequest<super::InsertDirectoryRequest>, 4348 - ) -> std::result::Result<tonic::Response<super::InsertDirectoryResponse>, tonic::Status> 4349 - { 4350 - self.inner.ready().await.map_err(|e| { 4351 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4352 - })?; 5075 + ) -> std::result::Result< 5076 + tonic::Response<super::InsertDirectoryResponse>, 5077 + tonic::Status, 5078 + > { 5079 + self.inner 5080 + .ready() 5081 + .await 5082 + .map_err(|e| { 5083 + tonic::Status::unknown( 5084 + format!("Service was not ready: {}", e.into()), 5085 + ) 5086 + })?; 4353 5087 let codec = tonic::codec::ProstCodec::default(); 4354 5088 let path = http::uri::PathAndQuery::from_static( 4355 5089 "/rockbox.v1alpha1.PlaylistService/InsertDirectory", 4356 5090 ); 4357 5091 let mut req = request.into_request(); 4358 - req.extensions_mut().insert(GrpcMethod::new( 4359 - "rockbox.v1alpha1.PlaylistService", 4360 - "InsertDirectory", 4361 - )); 5092 + req.extensions_mut() 5093 + .insert( 5094 + GrpcMethod::new( 5095 + "rockbox.v1alpha1.PlaylistService", 5096 + "InsertDirectory", 5097 + ), 5098 + ); 4362 5099 self.inner.unary(req, path, codec).await 4363 5100 } 4364 5101 pub async fn insert_playlist( 4365 5102 &mut self, 4366 5103 request: impl tonic::IntoRequest<super::InsertPlaylistRequest>, 4367 - ) -> std::result::Result<tonic::Response<super::InsertPlaylistResponse>, tonic::Status> 4368 - { 4369 - self.inner.ready().await.map_err(|e| { 4370 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4371 - })?; 5104 + ) -> std::result::Result< 5105 + tonic::Response<super::InsertPlaylistResponse>, 5106 + tonic::Status, 5107 + > { 5108 + self.inner 5109 + .ready() 5110 + .await 5111 + .map_err(|e| { 5112 + tonic::Status::unknown( 5113 + format!("Service was not ready: {}", e.into()), 5114 + ) 5115 + })?; 4372 5116 let codec = tonic::codec::ProstCodec::default(); 4373 5117 let path = http::uri::PathAndQuery::from_static( 4374 5118 "/rockbox.v1alpha1.PlaylistService/InsertPlaylist", 4375 5119 ); 4376 5120 let mut req = request.into_request(); 4377 - req.extensions_mut().insert(GrpcMethod::new( 4378 - "rockbox.v1alpha1.PlaylistService", 4379 - "InsertPlaylist", 4380 - )); 5121 + req.extensions_mut() 5122 + .insert( 5123 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "InsertPlaylist"), 5124 + ); 4381 5125 self.inner.unary(req, path, codec).await 4382 5126 } 4383 5127 pub async fn insert_album( 4384 5128 &mut self, 4385 5129 request: impl tonic::IntoRequest<super::InsertAlbumRequest>, 4386 - ) -> std::result::Result<tonic::Response<super::InsertAlbumResponse>, tonic::Status> 4387 - { 4388 - self.inner.ready().await.map_err(|e| { 4389 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4390 - })?; 5130 + ) -> std::result::Result< 5131 + tonic::Response<super::InsertAlbumResponse>, 5132 + tonic::Status, 5133 + > { 5134 + self.inner 5135 + .ready() 5136 + .await 5137 + .map_err(|e| { 5138 + tonic::Status::unknown( 5139 + format!("Service was not ready: {}", e.into()), 5140 + ) 5141 + })?; 4391 5142 let codec = tonic::codec::ProstCodec::default(); 4392 5143 let path = http::uri::PathAndQuery::from_static( 4393 5144 "/rockbox.v1alpha1.PlaylistService/InsertAlbum", 4394 5145 ); 4395 5146 let mut req = request.into_request(); 4396 - req.extensions_mut().insert(GrpcMethod::new( 4397 - "rockbox.v1alpha1.PlaylistService", 4398 - "InsertAlbum", 4399 - )); 5147 + req.extensions_mut() 5148 + .insert( 5149 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "InsertAlbum"), 5150 + ); 4400 5151 self.inner.unary(req, path, codec).await 4401 5152 } 4402 5153 pub async fn insert_artist_tracks( 4403 5154 &mut self, 4404 5155 request: impl tonic::IntoRequest<super::InsertArtistTracksRequest>, 4405 - ) -> std::result::Result<tonic::Response<super::InsertArtistTracksResponse>, tonic::Status> 4406 - { 4407 - self.inner.ready().await.map_err(|e| { 4408 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4409 - })?; 5156 + ) -> std::result::Result< 5157 + tonic::Response<super::InsertArtistTracksResponse>, 5158 + tonic::Status, 5159 + > { 5160 + self.inner 5161 + .ready() 5162 + .await 5163 + .map_err(|e| { 5164 + tonic::Status::unknown( 5165 + format!("Service was not ready: {}", e.into()), 5166 + ) 5167 + })?; 4410 5168 let codec = tonic::codec::ProstCodec::default(); 4411 5169 let path = http::uri::PathAndQuery::from_static( 4412 5170 "/rockbox.v1alpha1.PlaylistService/InsertArtistTracks", 4413 5171 ); 4414 5172 let mut req = request.into_request(); 4415 - req.extensions_mut().insert(GrpcMethod::new( 4416 - "rockbox.v1alpha1.PlaylistService", 4417 - "InsertArtistTracks", 4418 - )); 5173 + req.extensions_mut() 5174 + .insert( 5175 + GrpcMethod::new( 5176 + "rockbox.v1alpha1.PlaylistService", 5177 + "InsertArtistTracks", 5178 + ), 5179 + ); 4419 5180 self.inner.unary(req, path, codec).await 4420 5181 } 4421 5182 pub async fn shuffle_playlist( 4422 5183 &mut self, 4423 5184 request: impl tonic::IntoRequest<super::ShufflePlaylistRequest>, 4424 - ) -> std::result::Result<tonic::Response<super::ShufflePlaylistResponse>, tonic::Status> 4425 - { 4426 - self.inner.ready().await.map_err(|e| { 4427 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4428 - })?; 5185 + ) -> std::result::Result< 5186 + tonic::Response<super::ShufflePlaylistResponse>, 5187 + tonic::Status, 5188 + > { 5189 + self.inner 5190 + .ready() 5191 + .await 5192 + .map_err(|e| { 5193 + tonic::Status::unknown( 5194 + format!("Service was not ready: {}", e.into()), 5195 + ) 5196 + })?; 4429 5197 let codec = tonic::codec::ProstCodec::default(); 4430 5198 let path = http::uri::PathAndQuery::from_static( 4431 5199 "/rockbox.v1alpha1.PlaylistService/ShufflePlaylist", 4432 5200 ); 4433 5201 let mut req = request.into_request(); 4434 - req.extensions_mut().insert(GrpcMethod::new( 4435 - "rockbox.v1alpha1.PlaylistService", 4436 - "ShufflePlaylist", 4437 - )); 5202 + req.extensions_mut() 5203 + .insert( 5204 + GrpcMethod::new( 5205 + "rockbox.v1alpha1.PlaylistService", 5206 + "ShufflePlaylist", 5207 + ), 5208 + ); 4438 5209 self.inner.unary(req, path, codec).await 4439 5210 } 4440 5211 } ··· 4446 5217 dead_code, 4447 5218 missing_docs, 4448 5219 clippy::wildcard_imports, 4449 - clippy::let_unit_value 5220 + clippy::let_unit_value, 4450 5221 )] 4451 5222 use tonic::codegen::*; 4452 5223 /// Generated trait containing gRPC methods that should be implemented for use with PlaylistServiceServer. ··· 4455 5226 async fn get_current( 4456 5227 &self, 4457 5228 request: tonic::Request<super::GetCurrentRequest>, 4458 - ) -> std::result::Result<tonic::Response<super::GetCurrentResponse>, tonic::Status>; 5229 + ) -> std::result::Result< 5230 + tonic::Response<super::GetCurrentResponse>, 5231 + tonic::Status, 5232 + >; 4459 5233 async fn get_resume_info( 4460 5234 &self, 4461 5235 request: tonic::Request<super::GetResumeInfoRequest>, 4462 - ) -> std::result::Result<tonic::Response<super::GetResumeInfoResponse>, tonic::Status>; 5236 + ) -> std::result::Result< 5237 + tonic::Response<super::GetResumeInfoResponse>, 5238 + tonic::Status, 5239 + >; 4463 5240 async fn get_track_info( 4464 5241 &self, 4465 5242 request: tonic::Request<super::GetTrackInfoRequest>, 4466 - ) -> std::result::Result<tonic::Response<super::GetTrackInfoResponse>, tonic::Status>; 5243 + ) -> std::result::Result< 5244 + tonic::Response<super::GetTrackInfoResponse>, 5245 + tonic::Status, 5246 + >; 4467 5247 async fn get_first_index( 4468 5248 &self, 4469 5249 request: tonic::Request<super::GetFirstIndexRequest>, 4470 - ) -> std::result::Result<tonic::Response<super::GetFirstIndexResponse>, tonic::Status>; 5250 + ) -> std::result::Result< 5251 + tonic::Response<super::GetFirstIndexResponse>, 5252 + tonic::Status, 5253 + >; 4471 5254 async fn get_display_index( 4472 5255 &self, 4473 5256 request: tonic::Request<super::GetDisplayIndexRequest>, 4474 - ) -> std::result::Result<tonic::Response<super::GetDisplayIndexResponse>, tonic::Status>; 5257 + ) -> std::result::Result< 5258 + tonic::Response<super::GetDisplayIndexResponse>, 5259 + tonic::Status, 5260 + >; 4475 5261 async fn amount( 4476 5262 &self, 4477 5263 request: tonic::Request<super::AmountRequest>, ··· 4479 5265 async fn playlist_resume( 4480 5266 &self, 4481 5267 request: tonic::Request<super::PlaylistResumeRequest>, 4482 - ) -> std::result::Result<tonic::Response<super::PlaylistResumeResponse>, tonic::Status>; 5268 + ) -> std::result::Result< 5269 + tonic::Response<super::PlaylistResumeResponse>, 5270 + tonic::Status, 5271 + >; 4483 5272 async fn resume_track( 4484 5273 &self, 4485 5274 request: tonic::Request<super::ResumeTrackRequest>, 4486 - ) -> std::result::Result<tonic::Response<super::ResumeTrackResponse>, tonic::Status>; 5275 + ) -> std::result::Result< 5276 + tonic::Response<super::ResumeTrackResponse>, 5277 + tonic::Status, 5278 + >; 4487 5279 async fn set_modified( 4488 5280 &self, 4489 5281 request: tonic::Request<super::SetModifiedRequest>, 4490 - ) -> std::result::Result<tonic::Response<super::SetModifiedResponse>, tonic::Status>; 5282 + ) -> std::result::Result< 5283 + tonic::Response<super::SetModifiedResponse>, 5284 + tonic::Status, 5285 + >; 4491 5286 async fn start( 4492 5287 &self, 4493 5288 request: tonic::Request<super::StartRequest>, ··· 4499 5294 async fn remove_all_tracks( 4500 5295 &self, 4501 5296 request: tonic::Request<super::RemoveAllTracksRequest>, 4502 - ) -> std::result::Result<tonic::Response<super::RemoveAllTracksResponse>, tonic::Status>; 5297 + ) -> std::result::Result< 5298 + tonic::Response<super::RemoveAllTracksResponse>, 5299 + tonic::Status, 5300 + >; 4503 5301 async fn remove_tracks( 4504 5302 &self, 4505 5303 request: tonic::Request<super::RemoveTracksRequest>, 4506 - ) -> std::result::Result<tonic::Response<super::RemoveTracksResponse>, tonic::Status>; 5304 + ) -> std::result::Result< 5305 + tonic::Response<super::RemoveTracksResponse>, 5306 + tonic::Status, 5307 + >; 4507 5308 async fn create_playlist( 4508 5309 &self, 4509 5310 request: tonic::Request<super::CreatePlaylistRequest>, 4510 - ) -> std::result::Result<tonic::Response<super::CreatePlaylistResponse>, tonic::Status>; 5311 + ) -> std::result::Result< 5312 + tonic::Response<super::CreatePlaylistResponse>, 5313 + tonic::Status, 5314 + >; 4511 5315 async fn insert_tracks( 4512 5316 &self, 4513 5317 request: tonic::Request<super::InsertTracksRequest>, 4514 - ) -> std::result::Result<tonic::Response<super::InsertTracksResponse>, tonic::Status>; 5318 + ) -> std::result::Result< 5319 + tonic::Response<super::InsertTracksResponse>, 5320 + tonic::Status, 5321 + >; 4515 5322 async fn insert_directory( 4516 5323 &self, 4517 5324 request: tonic::Request<super::InsertDirectoryRequest>, 4518 - ) -> std::result::Result<tonic::Response<super::InsertDirectoryResponse>, tonic::Status>; 5325 + ) -> std::result::Result< 5326 + tonic::Response<super::InsertDirectoryResponse>, 5327 + tonic::Status, 5328 + >; 4519 5329 async fn insert_playlist( 4520 5330 &self, 4521 5331 request: tonic::Request<super::InsertPlaylistRequest>, 4522 - ) -> std::result::Result<tonic::Response<super::InsertPlaylistResponse>, tonic::Status>; 5332 + ) -> std::result::Result< 5333 + tonic::Response<super::InsertPlaylistResponse>, 5334 + tonic::Status, 5335 + >; 4523 5336 async fn insert_album( 4524 5337 &self, 4525 5338 request: tonic::Request<super::InsertAlbumRequest>, 4526 - ) -> std::result::Result<tonic::Response<super::InsertAlbumResponse>, tonic::Status>; 5339 + ) -> std::result::Result< 5340 + tonic::Response<super::InsertAlbumResponse>, 5341 + tonic::Status, 5342 + >; 4527 5343 async fn insert_artist_tracks( 4528 5344 &self, 4529 5345 request: tonic::Request<super::InsertArtistTracksRequest>, 4530 - ) -> std::result::Result<tonic::Response<super::InsertArtistTracksResponse>, tonic::Status>; 5346 + ) -> std::result::Result< 5347 + tonic::Response<super::InsertArtistTracksResponse>, 5348 + tonic::Status, 5349 + >; 4531 5350 async fn shuffle_playlist( 4532 5351 &self, 4533 5352 request: tonic::Request<super::ShufflePlaylistRequest>, 4534 - ) -> std::result::Result<tonic::Response<super::ShufflePlaylistResponse>, tonic::Status>; 5353 + ) -> std::result::Result< 5354 + tonic::Response<super::ShufflePlaylistResponse>, 5355 + tonic::Status, 5356 + >; 4535 5357 } 4536 5358 #[derive(Debug)] 4537 5359 pub struct PlaylistServiceServer<T> { ··· 4554 5376 max_encoding_message_size: None, 4555 5377 } 4556 5378 } 4557 - pub fn with_interceptor<F>(inner: T, interceptor: F) -> InterceptedService<Self, F> 5379 + pub fn with_interceptor<F>( 5380 + inner: T, 5381 + interceptor: F, 5382 + ) -> InterceptedService<Self, F> 4558 5383 where 4559 5384 F: tonic::service::Interceptor, 4560 5385 { ··· 4609 5434 "/rockbox.v1alpha1.PlaylistService/GetCurrent" => { 4610 5435 #[allow(non_camel_case_types)] 4611 5436 struct GetCurrentSvc<T: PlaylistService>(pub Arc<T>); 4612 - impl<T: PlaylistService> tonic::server::UnaryService<super::GetCurrentRequest> 4613 - for GetCurrentSvc<T> 4614 - { 5437 + impl< 5438 + T: PlaylistService, 5439 + > tonic::server::UnaryService<super::GetCurrentRequest> 5440 + for GetCurrentSvc<T> { 4615 5441 type Response = super::GetCurrentResponse; 4616 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 5442 + type Future = BoxFuture< 5443 + tonic::Response<Self::Response>, 5444 + tonic::Status, 5445 + >; 4617 5446 fn call( 4618 5447 &mut self, 4619 5448 request: tonic::Request<super::GetCurrentRequest>, ··· 4650 5479 "/rockbox.v1alpha1.PlaylistService/GetResumeInfo" => { 4651 5480 #[allow(non_camel_case_types)] 4652 5481 struct GetResumeInfoSvc<T: PlaylistService>(pub Arc<T>); 4653 - impl<T: PlaylistService> 4654 - tonic::server::UnaryService<super::GetResumeInfoRequest> 4655 - for GetResumeInfoSvc<T> 4656 - { 5482 + impl< 5483 + T: PlaylistService, 5484 + > tonic::server::UnaryService<super::GetResumeInfoRequest> 5485 + for GetResumeInfoSvc<T> { 4657 5486 type Response = super::GetResumeInfoResponse; 4658 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 5487 + type Future = BoxFuture< 5488 + tonic::Response<Self::Response>, 5489 + tonic::Status, 5490 + >; 4659 5491 fn call( 4660 5492 &mut self, 4661 5493 request: tonic::Request<super::GetResumeInfoRequest>, 4662 5494 ) -> Self::Future { 4663 5495 let inner = Arc::clone(&self.0); 4664 5496 let fut = async move { 4665 - <T as PlaylistService>::get_resume_info(&inner, request).await 5497 + <T as PlaylistService>::get_resume_info(&inner, request) 5498 + .await 4666 5499 }; 4667 5500 Box::pin(fut) 4668 5501 } ··· 4692 5525 "/rockbox.v1alpha1.PlaylistService/GetTrackInfo" => { 4693 5526 #[allow(non_camel_case_types)] 4694 5527 struct GetTrackInfoSvc<T: PlaylistService>(pub Arc<T>); 4695 - impl<T: PlaylistService> tonic::server::UnaryService<super::GetTrackInfoRequest> 4696 - for GetTrackInfoSvc<T> 4697 - { 5528 + impl< 5529 + T: PlaylistService, 5530 + > tonic::server::UnaryService<super::GetTrackInfoRequest> 5531 + for GetTrackInfoSvc<T> { 4698 5532 type Response = super::GetTrackInfoResponse; 4699 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 5533 + type Future = BoxFuture< 5534 + tonic::Response<Self::Response>, 5535 + tonic::Status, 5536 + >; 4700 5537 fn call( 4701 5538 &mut self, 4702 5539 request: tonic::Request<super::GetTrackInfoRequest>, 4703 5540 ) -> Self::Future { 4704 5541 let inner = Arc::clone(&self.0); 4705 5542 let fut = async move { 4706 - <T as PlaylistService>::get_track_info(&inner, request).await 5543 + <T as PlaylistService>::get_track_info(&inner, request) 5544 + .await 4707 5545 }; 4708 5546 Box::pin(fut) 4709 5547 } ··· 4733 5571 "/rockbox.v1alpha1.PlaylistService/GetFirstIndex" => { 4734 5572 #[allow(non_camel_case_types)] 4735 5573 struct GetFirstIndexSvc<T: PlaylistService>(pub Arc<T>); 4736 - impl<T: PlaylistService> 4737 - tonic::server::UnaryService<super::GetFirstIndexRequest> 4738 - for GetFirstIndexSvc<T> 4739 - { 5574 + impl< 5575 + T: PlaylistService, 5576 + > tonic::server::UnaryService<super::GetFirstIndexRequest> 5577 + for GetFirstIndexSvc<T> { 4740 5578 type Response = super::GetFirstIndexResponse; 4741 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 5579 + type Future = BoxFuture< 5580 + tonic::Response<Self::Response>, 5581 + tonic::Status, 5582 + >; 4742 5583 fn call( 4743 5584 &mut self, 4744 5585 request: tonic::Request<super::GetFirstIndexRequest>, 4745 5586 ) -> Self::Future { 4746 5587 let inner = Arc::clone(&self.0); 4747 5588 let fut = async move { 4748 - <T as PlaylistService>::get_first_index(&inner, request).await 5589 + <T as PlaylistService>::get_first_index(&inner, request) 5590 + .await 4749 5591 }; 4750 5592 Box::pin(fut) 4751 5593 } ··· 4775 5617 "/rockbox.v1alpha1.PlaylistService/GetDisplayIndex" => { 4776 5618 #[allow(non_camel_case_types)] 4777 5619 struct GetDisplayIndexSvc<T: PlaylistService>(pub Arc<T>); 4778 - impl<T: PlaylistService> 4779 - tonic::server::UnaryService<super::GetDisplayIndexRequest> 4780 - for GetDisplayIndexSvc<T> 4781 - { 5620 + impl< 5621 + T: PlaylistService, 5622 + > tonic::server::UnaryService<super::GetDisplayIndexRequest> 5623 + for GetDisplayIndexSvc<T> { 4782 5624 type Response = super::GetDisplayIndexResponse; 4783 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 5625 + type Future = BoxFuture< 5626 + tonic::Response<Self::Response>, 5627 + tonic::Status, 5628 + >; 4784 5629 fn call( 4785 5630 &mut self, 4786 5631 request: tonic::Request<super::GetDisplayIndexRequest>, 4787 5632 ) -> Self::Future { 4788 5633 let inner = Arc::clone(&self.0); 4789 5634 let fut = async move { 4790 - <T as PlaylistService>::get_display_index(&inner, request).await 5635 + <T as PlaylistService>::get_display_index(&inner, request) 5636 + .await 4791 5637 }; 4792 5638 Box::pin(fut) 4793 5639 } ··· 4817 5663 "/rockbox.v1alpha1.PlaylistService/Amount" => { 4818 5664 #[allow(non_camel_case_types)] 4819 5665 struct AmountSvc<T: PlaylistService>(pub Arc<T>); 4820 - impl<T: PlaylistService> tonic::server::UnaryService<super::AmountRequest> for AmountSvc<T> { 5666 + impl< 5667 + T: PlaylistService, 5668 + > tonic::server::UnaryService<super::AmountRequest> 5669 + for AmountSvc<T> { 4821 5670 type Response = super::AmountResponse; 4822 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 5671 + type Future = BoxFuture< 5672 + tonic::Response<Self::Response>, 5673 + tonic::Status, 5674 + >; 4823 5675 fn call( 4824 5676 &mut self, 4825 5677 request: tonic::Request<super::AmountRequest>, ··· 4856 5708 "/rockbox.v1alpha1.PlaylistService/PlaylistResume" => { 4857 5709 #[allow(non_camel_case_types)] 4858 5710 struct PlaylistResumeSvc<T: PlaylistService>(pub Arc<T>); 4859 - impl<T: PlaylistService> 4860 - tonic::server::UnaryService<super::PlaylistResumeRequest> 4861 - for PlaylistResumeSvc<T> 4862 - { 5711 + impl< 5712 + T: PlaylistService, 5713 + > tonic::server::UnaryService<super::PlaylistResumeRequest> 5714 + for PlaylistResumeSvc<T> { 4863 5715 type Response = super::PlaylistResumeResponse; 4864 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 5716 + type Future = BoxFuture< 5717 + tonic::Response<Self::Response>, 5718 + tonic::Status, 5719 + >; 4865 5720 fn call( 4866 5721 &mut self, 4867 5722 request: tonic::Request<super::PlaylistResumeRequest>, 4868 5723 ) -> Self::Future { 4869 5724 let inner = Arc::clone(&self.0); 4870 5725 let fut = async move { 4871 - <T as PlaylistService>::playlist_resume(&inner, request).await 5726 + <T as PlaylistService>::playlist_resume(&inner, request) 5727 + .await 4872 5728 }; 4873 5729 Box::pin(fut) 4874 5730 } ··· 4898 5754 "/rockbox.v1alpha1.PlaylistService/ResumeTrack" => { 4899 5755 #[allow(non_camel_case_types)] 4900 5756 struct ResumeTrackSvc<T: PlaylistService>(pub Arc<T>); 4901 - impl<T: PlaylistService> tonic::server::UnaryService<super::ResumeTrackRequest> 4902 - for ResumeTrackSvc<T> 4903 - { 5757 + impl< 5758 + T: PlaylistService, 5759 + > tonic::server::UnaryService<super::ResumeTrackRequest> 5760 + for ResumeTrackSvc<T> { 4904 5761 type Response = super::ResumeTrackResponse; 4905 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 5762 + type Future = BoxFuture< 5763 + tonic::Response<Self::Response>, 5764 + tonic::Status, 5765 + >; 4906 5766 fn call( 4907 5767 &mut self, 4908 5768 request: tonic::Request<super::ResumeTrackRequest>, ··· 4939 5799 "/rockbox.v1alpha1.PlaylistService/SetModified" => { 4940 5800 #[allow(non_camel_case_types)] 4941 5801 struct SetModifiedSvc<T: PlaylistService>(pub Arc<T>); 4942 - impl<T: PlaylistService> tonic::server::UnaryService<super::SetModifiedRequest> 4943 - for SetModifiedSvc<T> 4944 - { 5802 + impl< 5803 + T: PlaylistService, 5804 + > tonic::server::UnaryService<super::SetModifiedRequest> 5805 + for SetModifiedSvc<T> { 4945 5806 type Response = super::SetModifiedResponse; 4946 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 5807 + type Future = BoxFuture< 5808 + tonic::Response<Self::Response>, 5809 + tonic::Status, 5810 + >; 4947 5811 fn call( 4948 5812 &mut self, 4949 5813 request: tonic::Request<super::SetModifiedRequest>, ··· 4980 5844 "/rockbox.v1alpha1.PlaylistService/Start" => { 4981 5845 #[allow(non_camel_case_types)] 4982 5846 struct StartSvc<T: PlaylistService>(pub Arc<T>); 4983 - impl<T: PlaylistService> tonic::server::UnaryService<super::StartRequest> for StartSvc<T> { 5847 + impl< 5848 + T: PlaylistService, 5849 + > tonic::server::UnaryService<super::StartRequest> for StartSvc<T> { 4984 5850 type Response = super::StartResponse; 4985 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 5851 + type Future = BoxFuture< 5852 + tonic::Response<Self::Response>, 5853 + tonic::Status, 5854 + >; 4986 5855 fn call( 4987 5856 &mut self, 4988 5857 request: tonic::Request<super::StartRequest>, 4989 5858 ) -> Self::Future { 4990 5859 let inner = Arc::clone(&self.0); 4991 - let fut = 4992 - async move { <T as PlaylistService>::start(&inner, request).await }; 5860 + let fut = async move { 5861 + <T as PlaylistService>::start(&inner, request).await 5862 + }; 4993 5863 Box::pin(fut) 4994 5864 } 4995 5865 } ··· 5018 5888 "/rockbox.v1alpha1.PlaylistService/Sync" => { 5019 5889 #[allow(non_camel_case_types)] 5020 5890 struct SyncSvc<T: PlaylistService>(pub Arc<T>); 5021 - impl<T: PlaylistService> tonic::server::UnaryService<super::SyncRequest> for SyncSvc<T> { 5891 + impl< 5892 + T: PlaylistService, 5893 + > tonic::server::UnaryService<super::SyncRequest> for SyncSvc<T> { 5022 5894 type Response = super::SyncResponse; 5023 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 5895 + type Future = BoxFuture< 5896 + tonic::Response<Self::Response>, 5897 + tonic::Status, 5898 + >; 5024 5899 fn call( 5025 5900 &mut self, 5026 5901 request: tonic::Request<super::SyncRequest>, 5027 5902 ) -> Self::Future { 5028 5903 let inner = Arc::clone(&self.0); 5029 - let fut = 5030 - async move { <T as PlaylistService>::sync(&inner, request).await }; 5904 + let fut = async move { 5905 + <T as PlaylistService>::sync(&inner, request).await 5906 + }; 5031 5907 Box::pin(fut) 5032 5908 } 5033 5909 } ··· 5056 5932 "/rockbox.v1alpha1.PlaylistService/RemoveAllTracks" => { 5057 5933 #[allow(non_camel_case_types)] 5058 5934 struct RemoveAllTracksSvc<T: PlaylistService>(pub Arc<T>); 5059 - impl<T: PlaylistService> 5060 - tonic::server::UnaryService<super::RemoveAllTracksRequest> 5061 - for RemoveAllTracksSvc<T> 5062 - { 5935 + impl< 5936 + T: PlaylistService, 5937 + > tonic::server::UnaryService<super::RemoveAllTracksRequest> 5938 + for RemoveAllTracksSvc<T> { 5063 5939 type Response = super::RemoveAllTracksResponse; 5064 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 5940 + type Future = BoxFuture< 5941 + tonic::Response<Self::Response>, 5942 + tonic::Status, 5943 + >; 5065 5944 fn call( 5066 5945 &mut self, 5067 5946 request: tonic::Request<super::RemoveAllTracksRequest>, 5068 5947 ) -> Self::Future { 5069 5948 let inner = Arc::clone(&self.0); 5070 5949 let fut = async move { 5071 - <T as PlaylistService>::remove_all_tracks(&inner, request).await 5950 + <T as PlaylistService>::remove_all_tracks(&inner, request) 5951 + .await 5072 5952 }; 5073 5953 Box::pin(fut) 5074 5954 } ··· 5098 5978 "/rockbox.v1alpha1.PlaylistService/RemoveTracks" => { 5099 5979 #[allow(non_camel_case_types)] 5100 5980 struct RemoveTracksSvc<T: PlaylistService>(pub Arc<T>); 5101 - impl<T: PlaylistService> tonic::server::UnaryService<super::RemoveTracksRequest> 5102 - for RemoveTracksSvc<T> 5103 - { 5981 + impl< 5982 + T: PlaylistService, 5983 + > tonic::server::UnaryService<super::RemoveTracksRequest> 5984 + for RemoveTracksSvc<T> { 5104 5985 type Response = super::RemoveTracksResponse; 5105 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 5986 + type Future = BoxFuture< 5987 + tonic::Response<Self::Response>, 5988 + tonic::Status, 5989 + >; 5106 5990 fn call( 5107 5991 &mut self, 5108 5992 request: tonic::Request<super::RemoveTracksRequest>, ··· 5139 6023 "/rockbox.v1alpha1.PlaylistService/CreatePlaylist" => { 5140 6024 #[allow(non_camel_case_types)] 5141 6025 struct CreatePlaylistSvc<T: PlaylistService>(pub Arc<T>); 5142 - impl<T: PlaylistService> 5143 - tonic::server::UnaryService<super::CreatePlaylistRequest> 5144 - for CreatePlaylistSvc<T> 5145 - { 6026 + impl< 6027 + T: PlaylistService, 6028 + > tonic::server::UnaryService<super::CreatePlaylistRequest> 6029 + for CreatePlaylistSvc<T> { 5146 6030 type Response = super::CreatePlaylistResponse; 5147 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6031 + type Future = BoxFuture< 6032 + tonic::Response<Self::Response>, 6033 + tonic::Status, 6034 + >; 5148 6035 fn call( 5149 6036 &mut self, 5150 6037 request: tonic::Request<super::CreatePlaylistRequest>, 5151 6038 ) -> Self::Future { 5152 6039 let inner = Arc::clone(&self.0); 5153 6040 let fut = async move { 5154 - <T as PlaylistService>::create_playlist(&inner, request).await 6041 + <T as PlaylistService>::create_playlist(&inner, request) 6042 + .await 5155 6043 }; 5156 6044 Box::pin(fut) 5157 6045 } ··· 5181 6069 "/rockbox.v1alpha1.PlaylistService/InsertTracks" => { 5182 6070 #[allow(non_camel_case_types)] 5183 6071 struct InsertTracksSvc<T: PlaylistService>(pub Arc<T>); 5184 - impl<T: PlaylistService> tonic::server::UnaryService<super::InsertTracksRequest> 5185 - for InsertTracksSvc<T> 5186 - { 6072 + impl< 6073 + T: PlaylistService, 6074 + > tonic::server::UnaryService<super::InsertTracksRequest> 6075 + for InsertTracksSvc<T> { 5187 6076 type Response = super::InsertTracksResponse; 5188 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6077 + type Future = BoxFuture< 6078 + tonic::Response<Self::Response>, 6079 + tonic::Status, 6080 + >; 5189 6081 fn call( 5190 6082 &mut self, 5191 6083 request: tonic::Request<super::InsertTracksRequest>, ··· 5222 6114 "/rockbox.v1alpha1.PlaylistService/InsertDirectory" => { 5223 6115 #[allow(non_camel_case_types)] 5224 6116 struct InsertDirectorySvc<T: PlaylistService>(pub Arc<T>); 5225 - impl<T: PlaylistService> 5226 - tonic::server::UnaryService<super::InsertDirectoryRequest> 5227 - for InsertDirectorySvc<T> 5228 - { 6117 + impl< 6118 + T: PlaylistService, 6119 + > tonic::server::UnaryService<super::InsertDirectoryRequest> 6120 + for InsertDirectorySvc<T> { 5229 6121 type Response = super::InsertDirectoryResponse; 5230 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6122 + type Future = BoxFuture< 6123 + tonic::Response<Self::Response>, 6124 + tonic::Status, 6125 + >; 5231 6126 fn call( 5232 6127 &mut self, 5233 6128 request: tonic::Request<super::InsertDirectoryRequest>, 5234 6129 ) -> Self::Future { 5235 6130 let inner = Arc::clone(&self.0); 5236 6131 let fut = async move { 5237 - <T as PlaylistService>::insert_directory(&inner, request).await 6132 + <T as PlaylistService>::insert_directory(&inner, request) 6133 + .await 5238 6134 }; 5239 6135 Box::pin(fut) 5240 6136 } ··· 5264 6160 "/rockbox.v1alpha1.PlaylistService/InsertPlaylist" => { 5265 6161 #[allow(non_camel_case_types)] 5266 6162 struct InsertPlaylistSvc<T: PlaylistService>(pub Arc<T>); 5267 - impl<T: PlaylistService> 5268 - tonic::server::UnaryService<super::InsertPlaylistRequest> 5269 - for InsertPlaylistSvc<T> 5270 - { 6163 + impl< 6164 + T: PlaylistService, 6165 + > tonic::server::UnaryService<super::InsertPlaylistRequest> 6166 + for InsertPlaylistSvc<T> { 5271 6167 type Response = super::InsertPlaylistResponse; 5272 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6168 + type Future = BoxFuture< 6169 + tonic::Response<Self::Response>, 6170 + tonic::Status, 6171 + >; 5273 6172 fn call( 5274 6173 &mut self, 5275 6174 request: tonic::Request<super::InsertPlaylistRequest>, 5276 6175 ) -> Self::Future { 5277 6176 let inner = Arc::clone(&self.0); 5278 6177 let fut = async move { 5279 - <T as PlaylistService>::insert_playlist(&inner, request).await 6178 + <T as PlaylistService>::insert_playlist(&inner, request) 6179 + .await 5280 6180 }; 5281 6181 Box::pin(fut) 5282 6182 } ··· 5306 6206 "/rockbox.v1alpha1.PlaylistService/InsertAlbum" => { 5307 6207 #[allow(non_camel_case_types)] 5308 6208 struct InsertAlbumSvc<T: PlaylistService>(pub Arc<T>); 5309 - impl<T: PlaylistService> tonic::server::UnaryService<super::InsertAlbumRequest> 5310 - for InsertAlbumSvc<T> 5311 - { 6209 + impl< 6210 + T: PlaylistService, 6211 + > tonic::server::UnaryService<super::InsertAlbumRequest> 6212 + for InsertAlbumSvc<T> { 5312 6213 type Response = super::InsertAlbumResponse; 5313 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6214 + type Future = BoxFuture< 6215 + tonic::Response<Self::Response>, 6216 + tonic::Status, 6217 + >; 5314 6218 fn call( 5315 6219 &mut self, 5316 6220 request: tonic::Request<super::InsertAlbumRequest>, ··· 5347 6251 "/rockbox.v1alpha1.PlaylistService/InsertArtistTracks" => { 5348 6252 #[allow(non_camel_case_types)] 5349 6253 struct InsertArtistTracksSvc<T: PlaylistService>(pub Arc<T>); 5350 - impl<T: PlaylistService> 5351 - tonic::server::UnaryService<super::InsertArtistTracksRequest> 5352 - for InsertArtistTracksSvc<T> 5353 - { 6254 + impl< 6255 + T: PlaylistService, 6256 + > tonic::server::UnaryService<super::InsertArtistTracksRequest> 6257 + for InsertArtistTracksSvc<T> { 5354 6258 type Response = super::InsertArtistTracksResponse; 5355 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6259 + type Future = BoxFuture< 6260 + tonic::Response<Self::Response>, 6261 + tonic::Status, 6262 + >; 5356 6263 fn call( 5357 6264 &mut self, 5358 6265 request: tonic::Request<super::InsertArtistTracksRequest>, 5359 6266 ) -> Self::Future { 5360 6267 let inner = Arc::clone(&self.0); 5361 6268 let fut = async move { 5362 - <T as PlaylistService>::insert_artist_tracks(&inner, request).await 6269 + <T as PlaylistService>::insert_artist_tracks( 6270 + &inner, 6271 + request, 6272 + ) 6273 + .await 5363 6274 }; 5364 6275 Box::pin(fut) 5365 6276 } ··· 5389 6300 "/rockbox.v1alpha1.PlaylistService/ShufflePlaylist" => { 5390 6301 #[allow(non_camel_case_types)] 5391 6302 struct ShufflePlaylistSvc<T: PlaylistService>(pub Arc<T>); 5392 - impl<T: PlaylistService> 5393 - tonic::server::UnaryService<super::ShufflePlaylistRequest> 5394 - for ShufflePlaylistSvc<T> 5395 - { 6303 + impl< 6304 + T: PlaylistService, 6305 + > tonic::server::UnaryService<super::ShufflePlaylistRequest> 6306 + for ShufflePlaylistSvc<T> { 5396 6307 type Response = super::ShufflePlaylistResponse; 5397 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6308 + type Future = BoxFuture< 6309 + tonic::Response<Self::Response>, 6310 + tonic::Status, 6311 + >; 5398 6312 fn call( 5399 6313 &mut self, 5400 6314 request: tonic::Request<super::ShufflePlaylistRequest>, 5401 6315 ) -> Self::Future { 5402 6316 let inner = Arc::clone(&self.0); 5403 6317 let fut = async move { 5404 - <T as PlaylistService>::shuffle_playlist(&inner, request).await 6318 + <T as PlaylistService>::shuffle_playlist(&inner, request) 6319 + .await 5405 6320 }; 5406 6321 Box::pin(fut) 5407 6322 } ··· 5428 6343 }; 5429 6344 Box::pin(fut) 5430 6345 } 5431 - _ => Box::pin(async move { 5432 - let mut response = http::Response::new(empty_body()); 5433 - let headers = response.headers_mut(); 5434 - headers.insert( 5435 - tonic::Status::GRPC_STATUS, 5436 - (tonic::Code::Unimplemented as i32).into(), 5437 - ); 5438 - headers.insert( 5439 - http::header::CONTENT_TYPE, 5440 - tonic::metadata::GRPC_CONTENT_TYPE, 5441 - ); 5442 - Ok(response) 5443 - }), 6346 + _ => { 6347 + Box::pin(async move { 6348 + let mut response = http::Response::new(empty_body()); 6349 + let headers = response.headers_mut(); 6350 + headers 6351 + .insert( 6352 + tonic::Status::GRPC_STATUS, 6353 + (tonic::Code::Unimplemented as i32).into(), 6354 + ); 6355 + headers 6356 + .insert( 6357 + http::header::CONTENT_TYPE, 6358 + tonic::metadata::GRPC_CONTENT_TYPE, 6359 + ); 6360 + Ok(response) 6361 + }) 6362 + } 5444 6363 } 5445 6364 } 5446 6365 } ··· 5950 6869 dead_code, 5951 6870 missing_docs, 5952 6871 clippy::wildcard_imports, 5953 - clippy::let_unit_value 6872 + clippy::let_unit_value, 5954 6873 )] 5955 - use tonic::codegen::http::Uri; 5956 6874 use tonic::codegen::*; 6875 + use tonic::codegen::http::Uri; 5957 6876 #[derive(Debug, Clone)] 5958 6877 pub struct SettingsServiceClient<T> { 5959 6878 inner: tonic::client::Grpc<T>, ··· 5997 6916 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody, 5998 6917 >, 5999 6918 >, 6000 - <T as tonic::codegen::Service<http::Request<tonic::body::BoxBody>>>::Error: 6001 - Into<StdError> + std::marker::Send + std::marker::Sync, 6919 + <T as tonic::codegen::Service< 6920 + http::Request<tonic::body::BoxBody>, 6921 + >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync, 6002 6922 { 6003 6923 SettingsServiceClient::new(InterceptedService::new(inner, interceptor)) 6004 6924 } ··· 6036 6956 pub async fn get_settings_list( 6037 6957 &mut self, 6038 6958 request: impl tonic::IntoRequest<super::GetSettingsListRequest>, 6039 - ) -> std::result::Result<tonic::Response<super::GetSettingsListResponse>, tonic::Status> 6040 - { 6041 - self.inner.ready().await.map_err(|e| { 6042 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6043 - })?; 6959 + ) -> std::result::Result< 6960 + tonic::Response<super::GetSettingsListResponse>, 6961 + tonic::Status, 6962 + > { 6963 + self.inner 6964 + .ready() 6965 + .await 6966 + .map_err(|e| { 6967 + tonic::Status::unknown( 6968 + format!("Service was not ready: {}", e.into()), 6969 + ) 6970 + })?; 6044 6971 let codec = tonic::codec::ProstCodec::default(); 6045 6972 let path = http::uri::PathAndQuery::from_static( 6046 6973 "/rockbox.v1alpha1.SettingsService/GetSettingsList", 6047 6974 ); 6048 6975 let mut req = request.into_request(); 6049 - req.extensions_mut().insert(GrpcMethod::new( 6050 - "rockbox.v1alpha1.SettingsService", 6051 - "GetSettingsList", 6052 - )); 6976 + req.extensions_mut() 6977 + .insert( 6978 + GrpcMethod::new( 6979 + "rockbox.v1alpha1.SettingsService", 6980 + "GetSettingsList", 6981 + ), 6982 + ); 6053 6983 self.inner.unary(req, path, codec).await 6054 6984 } 6055 6985 pub async fn get_global_settings( 6056 6986 &mut self, 6057 6987 request: impl tonic::IntoRequest<super::GetGlobalSettingsRequest>, 6058 - ) -> std::result::Result<tonic::Response<super::GetGlobalSettingsResponse>, tonic::Status> 6059 - { 6060 - self.inner.ready().await.map_err(|e| { 6061 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6062 - })?; 6988 + ) -> std::result::Result< 6989 + tonic::Response<super::GetGlobalSettingsResponse>, 6990 + tonic::Status, 6991 + > { 6992 + self.inner 6993 + .ready() 6994 + .await 6995 + .map_err(|e| { 6996 + tonic::Status::unknown( 6997 + format!("Service was not ready: {}", e.into()), 6998 + ) 6999 + })?; 6063 7000 let codec = tonic::codec::ProstCodec::default(); 6064 7001 let path = http::uri::PathAndQuery::from_static( 6065 7002 "/rockbox.v1alpha1.SettingsService/GetGlobalSettings", 6066 7003 ); 6067 7004 let mut req = request.into_request(); 6068 - req.extensions_mut().insert(GrpcMethod::new( 6069 - "rockbox.v1alpha1.SettingsService", 6070 - "GetGlobalSettings", 6071 - )); 7005 + req.extensions_mut() 7006 + .insert( 7007 + GrpcMethod::new( 7008 + "rockbox.v1alpha1.SettingsService", 7009 + "GetGlobalSettings", 7010 + ), 7011 + ); 6072 7012 self.inner.unary(req, path, codec).await 6073 7013 } 6074 7014 pub async fn save_settings( 6075 7015 &mut self, 6076 7016 request: impl tonic::IntoRequest<super::SaveSettingsRequest>, 6077 - ) -> std::result::Result<tonic::Response<super::SaveSettingsResponse>, tonic::Status> 6078 - { 6079 - self.inner.ready().await.map_err(|e| { 6080 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6081 - })?; 7017 + ) -> std::result::Result< 7018 + tonic::Response<super::SaveSettingsResponse>, 7019 + tonic::Status, 7020 + > { 7021 + self.inner 7022 + .ready() 7023 + .await 7024 + .map_err(|e| { 7025 + tonic::Status::unknown( 7026 + format!("Service was not ready: {}", e.into()), 7027 + ) 7028 + })?; 6082 7029 let codec = tonic::codec::ProstCodec::default(); 6083 7030 let path = http::uri::PathAndQuery::from_static( 6084 7031 "/rockbox.v1alpha1.SettingsService/SaveSettings", 6085 7032 ); 6086 7033 let mut req = request.into_request(); 6087 - req.extensions_mut().insert(GrpcMethod::new( 6088 - "rockbox.v1alpha1.SettingsService", 6089 - "SaveSettings", 6090 - )); 7034 + req.extensions_mut() 7035 + .insert( 7036 + GrpcMethod::new("rockbox.v1alpha1.SettingsService", "SaveSettings"), 7037 + ); 6091 7038 self.inner.unary(req, path, codec).await 6092 7039 } 6093 7040 } ··· 6099 7046 dead_code, 6100 7047 missing_docs, 6101 7048 clippy::wildcard_imports, 6102 - clippy::let_unit_value 7049 + clippy::let_unit_value, 6103 7050 )] 6104 7051 use tonic::codegen::*; 6105 7052 /// Generated trait containing gRPC methods that should be implemented for use with SettingsServiceServer. ··· 6108 7055 async fn get_settings_list( 6109 7056 &self, 6110 7057 request: tonic::Request<super::GetSettingsListRequest>, 6111 - ) -> std::result::Result<tonic::Response<super::GetSettingsListResponse>, tonic::Status>; 7058 + ) -> std::result::Result< 7059 + tonic::Response<super::GetSettingsListResponse>, 7060 + tonic::Status, 7061 + >; 6112 7062 async fn get_global_settings( 6113 7063 &self, 6114 7064 request: tonic::Request<super::GetGlobalSettingsRequest>, 6115 - ) -> std::result::Result<tonic::Response<super::GetGlobalSettingsResponse>, tonic::Status>; 7065 + ) -> std::result::Result< 7066 + tonic::Response<super::GetGlobalSettingsResponse>, 7067 + tonic::Status, 7068 + >; 6116 7069 async fn save_settings( 6117 7070 &self, 6118 7071 request: tonic::Request<super::SaveSettingsRequest>, 6119 - ) -> std::result::Result<tonic::Response<super::SaveSettingsResponse>, tonic::Status>; 7072 + ) -> std::result::Result< 7073 + tonic::Response<super::SaveSettingsResponse>, 7074 + tonic::Status, 7075 + >; 6120 7076 } 6121 7077 #[derive(Debug)] 6122 7078 pub struct SettingsServiceServer<T> { ··· 6139 7095 max_encoding_message_size: None, 6140 7096 } 6141 7097 } 6142 - pub fn with_interceptor<F>(inner: T, interceptor: F) -> InterceptedService<Self, F> 7098 + pub fn with_interceptor<F>( 7099 + inner: T, 7100 + interceptor: F, 7101 + ) -> InterceptedService<Self, F> 6143 7102 where 6144 7103 F: tonic::service::Interceptor, 6145 7104 { ··· 6194 7153 "/rockbox.v1alpha1.SettingsService/GetSettingsList" => { 6195 7154 #[allow(non_camel_case_types)] 6196 7155 struct GetSettingsListSvc<T: SettingsService>(pub Arc<T>); 6197 - impl<T: SettingsService> 6198 - tonic::server::UnaryService<super::GetSettingsListRequest> 6199 - for GetSettingsListSvc<T> 6200 - { 7156 + impl< 7157 + T: SettingsService, 7158 + > tonic::server::UnaryService<super::GetSettingsListRequest> 7159 + for GetSettingsListSvc<T> { 6201 7160 type Response = super::GetSettingsListResponse; 6202 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 7161 + type Future = BoxFuture< 7162 + tonic::Response<Self::Response>, 7163 + tonic::Status, 7164 + >; 6203 7165 fn call( 6204 7166 &mut self, 6205 7167 request: tonic::Request<super::GetSettingsListRequest>, 6206 7168 ) -> Self::Future { 6207 7169 let inner = Arc::clone(&self.0); 6208 7170 let fut = async move { 6209 - <T as SettingsService>::get_settings_list(&inner, request).await 7171 + <T as SettingsService>::get_settings_list(&inner, request) 7172 + .await 6210 7173 }; 6211 7174 Box::pin(fut) 6212 7175 } ··· 6236 7199 "/rockbox.v1alpha1.SettingsService/GetGlobalSettings" => { 6237 7200 #[allow(non_camel_case_types)] 6238 7201 struct GetGlobalSettingsSvc<T: SettingsService>(pub Arc<T>); 6239 - impl<T: SettingsService> 6240 - tonic::server::UnaryService<super::GetGlobalSettingsRequest> 6241 - for GetGlobalSettingsSvc<T> 6242 - { 7202 + impl< 7203 + T: SettingsService, 7204 + > tonic::server::UnaryService<super::GetGlobalSettingsRequest> 7205 + for GetGlobalSettingsSvc<T> { 6243 7206 type Response = super::GetGlobalSettingsResponse; 6244 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 7207 + type Future = BoxFuture< 7208 + tonic::Response<Self::Response>, 7209 + tonic::Status, 7210 + >; 6245 7211 fn call( 6246 7212 &mut self, 6247 7213 request: tonic::Request<super::GetGlobalSettingsRequest>, 6248 7214 ) -> Self::Future { 6249 7215 let inner = Arc::clone(&self.0); 6250 7216 let fut = async move { 6251 - <T as SettingsService>::get_global_settings(&inner, request).await 7217 + <T as SettingsService>::get_global_settings(&inner, request) 7218 + .await 6252 7219 }; 6253 7220 Box::pin(fut) 6254 7221 } ··· 6278 7245 "/rockbox.v1alpha1.SettingsService/SaveSettings" => { 6279 7246 #[allow(non_camel_case_types)] 6280 7247 struct SaveSettingsSvc<T: SettingsService>(pub Arc<T>); 6281 - impl<T: SettingsService> tonic::server::UnaryService<super::SaveSettingsRequest> 6282 - for SaveSettingsSvc<T> 6283 - { 7248 + impl< 7249 + T: SettingsService, 7250 + > tonic::server::UnaryService<super::SaveSettingsRequest> 7251 + for SaveSettingsSvc<T> { 6284 7252 type Response = super::SaveSettingsResponse; 6285 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 7253 + type Future = BoxFuture< 7254 + tonic::Response<Self::Response>, 7255 + tonic::Status, 7256 + >; 6286 7257 fn call( 6287 7258 &mut self, 6288 7259 request: tonic::Request<super::SaveSettingsRequest>, ··· 6316 7287 }; 6317 7288 Box::pin(fut) 6318 7289 } 6319 - _ => Box::pin(async move { 6320 - let mut response = http::Response::new(empty_body()); 6321 - let headers = response.headers_mut(); 6322 - headers.insert( 6323 - tonic::Status::GRPC_STATUS, 6324 - (tonic::Code::Unimplemented as i32).into(), 6325 - ); 6326 - headers.insert( 6327 - http::header::CONTENT_TYPE, 6328 - tonic::metadata::GRPC_CONTENT_TYPE, 6329 - ); 6330 - Ok(response) 6331 - }), 7290 + _ => { 7291 + Box::pin(async move { 7292 + let mut response = http::Response::new(empty_body()); 7293 + let headers = response.headers_mut(); 7294 + headers 7295 + .insert( 7296 + tonic::Status::GRPC_STATUS, 7297 + (tonic::Code::Unimplemented as i32).into(), 7298 + ); 7299 + headers 7300 + .insert( 7301 + http::header::CONTENT_TYPE, 7302 + tonic::metadata::GRPC_CONTENT_TYPE, 7303 + ); 7304 + Ok(response) 7305 + }) 7306 + } 6332 7307 } 6333 7308 } 6334 7309 } ··· 6486 7461 dead_code, 6487 7462 missing_docs, 6488 7463 clippy::wildcard_imports, 6489 - clippy::let_unit_value 7464 + clippy::let_unit_value, 6490 7465 )] 6491 - use tonic::codegen::http::Uri; 6492 7466 use tonic::codegen::*; 7467 + use tonic::codegen::http::Uri; 6493 7468 #[derive(Debug, Clone)] 6494 7469 pub struct SoundServiceClient<T> { 6495 7470 inner: tonic::client::Grpc<T>, ··· 6533 7508 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody, 6534 7509 >, 6535 7510 >, 6536 - <T as tonic::codegen::Service<http::Request<tonic::body::BoxBody>>>::Error: 6537 - Into<StdError> + std::marker::Send + std::marker::Sync, 7511 + <T as tonic::codegen::Service< 7512 + http::Request<tonic::body::BoxBody>, 7513 + >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync, 6538 7514 { 6539 7515 SoundServiceClient::new(InterceptedService::new(inner, interceptor)) 6540 7516 } ··· 6572 7548 pub async fn adjust_volume( 6573 7549 &mut self, 6574 7550 request: impl tonic::IntoRequest<super::AdjustVolumeRequest>, 6575 - ) -> std::result::Result<tonic::Response<super::AdjustVolumeResponse>, tonic::Status> 6576 - { 6577 - self.inner.ready().await.map_err(|e| { 6578 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6579 - })?; 7551 + ) -> std::result::Result< 7552 + tonic::Response<super::AdjustVolumeResponse>, 7553 + tonic::Status, 7554 + > { 7555 + self.inner 7556 + .ready() 7557 + .await 7558 + .map_err(|e| { 7559 + tonic::Status::unknown( 7560 + format!("Service was not ready: {}", e.into()), 7561 + ) 7562 + })?; 6580 7563 let codec = tonic::codec::ProstCodec::default(); 6581 - let path = 6582 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/AdjustVolume"); 7564 + let path = http::uri::PathAndQuery::from_static( 7565 + "/rockbox.v1alpha1.SoundService/AdjustVolume", 7566 + ); 6583 7567 let mut req = request.into_request(); 6584 - req.extensions_mut().insert(GrpcMethod::new( 6585 - "rockbox.v1alpha1.SoundService", 6586 - "AdjustVolume", 6587 - )); 7568 + req.extensions_mut() 7569 + .insert( 7570 + GrpcMethod::new("rockbox.v1alpha1.SoundService", "AdjustVolume"), 7571 + ); 6588 7572 self.inner.unary(req, path, codec).await 6589 7573 } 6590 7574 pub async fn sound_set( 6591 7575 &mut self, 6592 7576 request: impl tonic::IntoRequest<super::SoundSetRequest>, 6593 - ) -> std::result::Result<tonic::Response<super::SoundSetResponse>, tonic::Status> { 6594 - self.inner.ready().await.map_err(|e| { 6595 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6596 - })?; 7577 + ) -> std::result::Result< 7578 + tonic::Response<super::SoundSetResponse>, 7579 + tonic::Status, 7580 + > { 7581 + self.inner 7582 + .ready() 7583 + .await 7584 + .map_err(|e| { 7585 + tonic::Status::unknown( 7586 + format!("Service was not ready: {}", e.into()), 7587 + ) 7588 + })?; 6597 7589 let codec = tonic::codec::ProstCodec::default(); 6598 - let path = 6599 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/SoundSet"); 7590 + let path = http::uri::PathAndQuery::from_static( 7591 + "/rockbox.v1alpha1.SoundService/SoundSet", 7592 + ); 6600 7593 let mut req = request.into_request(); 6601 7594 req.extensions_mut() 6602 7595 .insert(GrpcMethod::new("rockbox.v1alpha1.SoundService", "SoundSet")); ··· 6605 7598 pub async fn sound_current( 6606 7599 &mut self, 6607 7600 request: impl tonic::IntoRequest<super::SoundCurrentRequest>, 6608 - ) -> std::result::Result<tonic::Response<super::SoundCurrentResponse>, tonic::Status> 6609 - { 6610 - self.inner.ready().await.map_err(|e| { 6611 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6612 - })?; 7601 + ) -> std::result::Result< 7602 + tonic::Response<super::SoundCurrentResponse>, 7603 + tonic::Status, 7604 + > { 7605 + self.inner 7606 + .ready() 7607 + .await 7608 + .map_err(|e| { 7609 + tonic::Status::unknown( 7610 + format!("Service was not ready: {}", e.into()), 7611 + ) 7612 + })?; 6613 7613 let codec = tonic::codec::ProstCodec::default(); 6614 - let path = 6615 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/SoundCurrent"); 7614 + let path = http::uri::PathAndQuery::from_static( 7615 + "/rockbox.v1alpha1.SoundService/SoundCurrent", 7616 + ); 6616 7617 let mut req = request.into_request(); 6617 - req.extensions_mut().insert(GrpcMethod::new( 6618 - "rockbox.v1alpha1.SoundService", 6619 - "SoundCurrent", 6620 - )); 7618 + req.extensions_mut() 7619 + .insert( 7620 + GrpcMethod::new("rockbox.v1alpha1.SoundService", "SoundCurrent"), 7621 + ); 6621 7622 self.inner.unary(req, path, codec).await 6622 7623 } 6623 7624 pub async fn sound_default( 6624 7625 &mut self, 6625 7626 request: impl tonic::IntoRequest<super::SoundDefaultRequest>, 6626 - ) -> std::result::Result<tonic::Response<super::SoundDefaultResponse>, tonic::Status> 6627 - { 6628 - self.inner.ready().await.map_err(|e| { 6629 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6630 - })?; 7627 + ) -> std::result::Result< 7628 + tonic::Response<super::SoundDefaultResponse>, 7629 + tonic::Status, 7630 + > { 7631 + self.inner 7632 + .ready() 7633 + .await 7634 + .map_err(|e| { 7635 + tonic::Status::unknown( 7636 + format!("Service was not ready: {}", e.into()), 7637 + ) 7638 + })?; 6631 7639 let codec = tonic::codec::ProstCodec::default(); 6632 - let path = 6633 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/SoundDefault"); 7640 + let path = http::uri::PathAndQuery::from_static( 7641 + "/rockbox.v1alpha1.SoundService/SoundDefault", 7642 + ); 6634 7643 let mut req = request.into_request(); 6635 - req.extensions_mut().insert(GrpcMethod::new( 6636 - "rockbox.v1alpha1.SoundService", 6637 - "SoundDefault", 6638 - )); 7644 + req.extensions_mut() 7645 + .insert( 7646 + GrpcMethod::new("rockbox.v1alpha1.SoundService", "SoundDefault"), 7647 + ); 6639 7648 self.inner.unary(req, path, codec).await 6640 7649 } 6641 7650 pub async fn sound_min( 6642 7651 &mut self, 6643 7652 request: impl tonic::IntoRequest<super::SoundMinRequest>, 6644 - ) -> std::result::Result<tonic::Response<super::SoundMinResponse>, tonic::Status> { 6645 - self.inner.ready().await.map_err(|e| { 6646 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6647 - })?; 7653 + ) -> std::result::Result< 7654 + tonic::Response<super::SoundMinResponse>, 7655 + tonic::Status, 7656 + > { 7657 + self.inner 7658 + .ready() 7659 + .await 7660 + .map_err(|e| { 7661 + tonic::Status::unknown( 7662 + format!("Service was not ready: {}", e.into()), 7663 + ) 7664 + })?; 6648 7665 let codec = tonic::codec::ProstCodec::default(); 6649 - let path = 6650 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/SoundMin"); 7666 + let path = http::uri::PathAndQuery::from_static( 7667 + "/rockbox.v1alpha1.SoundService/SoundMin", 7668 + ); 6651 7669 let mut req = request.into_request(); 6652 7670 req.extensions_mut() 6653 7671 .insert(GrpcMethod::new("rockbox.v1alpha1.SoundService", "SoundMin")); ··· 6656 7674 pub async fn sound_max( 6657 7675 &mut self, 6658 7676 request: impl tonic::IntoRequest<super::SoundMaxRequest>, 6659 - ) -> std::result::Result<tonic::Response<super::SoundMaxResponse>, tonic::Status> { 6660 - self.inner.ready().await.map_err(|e| { 6661 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6662 - })?; 7677 + ) -> std::result::Result< 7678 + tonic::Response<super::SoundMaxResponse>, 7679 + tonic::Status, 7680 + > { 7681 + self.inner 7682 + .ready() 7683 + .await 7684 + .map_err(|e| { 7685 + tonic::Status::unknown( 7686 + format!("Service was not ready: {}", e.into()), 7687 + ) 7688 + })?; 6663 7689 let codec = tonic::codec::ProstCodec::default(); 6664 - let path = 6665 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/SoundMax"); 7690 + let path = http::uri::PathAndQuery::from_static( 7691 + "/rockbox.v1alpha1.SoundService/SoundMax", 7692 + ); 6666 7693 let mut req = request.into_request(); 6667 7694 req.extensions_mut() 6668 7695 .insert(GrpcMethod::new("rockbox.v1alpha1.SoundService", "SoundMax")); ··· 6671 7698 pub async fn sound_unit( 6672 7699 &mut self, 6673 7700 request: impl tonic::IntoRequest<super::SoundUnitRequest>, 6674 - ) -> std::result::Result<tonic::Response<super::SoundUnitResponse>, tonic::Status> { 6675 - self.inner.ready().await.map_err(|e| { 6676 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6677 - })?; 7701 + ) -> std::result::Result< 7702 + tonic::Response<super::SoundUnitResponse>, 7703 + tonic::Status, 7704 + > { 7705 + self.inner 7706 + .ready() 7707 + .await 7708 + .map_err(|e| { 7709 + tonic::Status::unknown( 7710 + format!("Service was not ready: {}", e.into()), 7711 + ) 7712 + })?; 6678 7713 let codec = tonic::codec::ProstCodec::default(); 6679 - let path = 6680 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/SoundUnit"); 7714 + let path = http::uri::PathAndQuery::from_static( 7715 + "/rockbox.v1alpha1.SoundService/SoundUnit", 7716 + ); 6681 7717 let mut req = request.into_request(); 6682 - req.extensions_mut().insert(GrpcMethod::new( 6683 - "rockbox.v1alpha1.SoundService", 6684 - "SoundUnit", 6685 - )); 7718 + req.extensions_mut() 7719 + .insert(GrpcMethod::new("rockbox.v1alpha1.SoundService", "SoundUnit")); 6686 7720 self.inner.unary(req, path, codec).await 6687 7721 } 6688 7722 pub async fn sound_val2_phys( 6689 7723 &mut self, 6690 7724 request: impl tonic::IntoRequest<super::SoundVal2PhysRequest>, 6691 - ) -> std::result::Result<tonic::Response<super::SoundVal2PhysResponse>, tonic::Status> 6692 - { 6693 - self.inner.ready().await.map_err(|e| { 6694 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6695 - })?; 7725 + ) -> std::result::Result< 7726 + tonic::Response<super::SoundVal2PhysResponse>, 7727 + tonic::Status, 7728 + > { 7729 + self.inner 7730 + .ready() 7731 + .await 7732 + .map_err(|e| { 7733 + tonic::Status::unknown( 7734 + format!("Service was not ready: {}", e.into()), 7735 + ) 7736 + })?; 6696 7737 let codec = tonic::codec::ProstCodec::default(); 6697 7738 let path = http::uri::PathAndQuery::from_static( 6698 7739 "/rockbox.v1alpha1.SoundService/SoundVal2Phys", 6699 7740 ); 6700 7741 let mut req = request.into_request(); 6701 - req.extensions_mut().insert(GrpcMethod::new( 6702 - "rockbox.v1alpha1.SoundService", 6703 - "SoundVal2Phys", 6704 - )); 7742 + req.extensions_mut() 7743 + .insert( 7744 + GrpcMethod::new("rockbox.v1alpha1.SoundService", "SoundVal2Phys"), 7745 + ); 6705 7746 self.inner.unary(req, path, codec).await 6706 7747 } 6707 7748 pub async fn get_pitch( 6708 7749 &mut self, 6709 7750 request: impl tonic::IntoRequest<super::GetPitchRequest>, 6710 - ) -> std::result::Result<tonic::Response<super::GetPitchResponse>, tonic::Status> { 6711 - self.inner.ready().await.map_err(|e| { 6712 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6713 - })?; 7751 + ) -> std::result::Result< 7752 + tonic::Response<super::GetPitchResponse>, 7753 + tonic::Status, 7754 + > { 7755 + self.inner 7756 + .ready() 7757 + .await 7758 + .map_err(|e| { 7759 + tonic::Status::unknown( 7760 + format!("Service was not ready: {}", e.into()), 7761 + ) 7762 + })?; 6714 7763 let codec = tonic::codec::ProstCodec::default(); 6715 - let path = 6716 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/GetPitch"); 7764 + let path = http::uri::PathAndQuery::from_static( 7765 + "/rockbox.v1alpha1.SoundService/GetPitch", 7766 + ); 6717 7767 let mut req = request.into_request(); 6718 7768 req.extensions_mut() 6719 7769 .insert(GrpcMethod::new("rockbox.v1alpha1.SoundService", "GetPitch")); ··· 6722 7772 pub async fn set_pitch( 6723 7773 &mut self, 6724 7774 request: impl tonic::IntoRequest<super::SetPitchRequest>, 6725 - ) -> std::result::Result<tonic::Response<super::SetPitchResponse>, tonic::Status> { 6726 - self.inner.ready().await.map_err(|e| { 6727 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6728 - })?; 7775 + ) -> std::result::Result< 7776 + tonic::Response<super::SetPitchResponse>, 7777 + tonic::Status, 7778 + > { 7779 + self.inner 7780 + .ready() 7781 + .await 7782 + .map_err(|e| { 7783 + tonic::Status::unknown( 7784 + format!("Service was not ready: {}", e.into()), 7785 + ) 7786 + })?; 6729 7787 let codec = tonic::codec::ProstCodec::default(); 6730 - let path = 6731 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/SetPitch"); 7788 + let path = http::uri::PathAndQuery::from_static( 7789 + "/rockbox.v1alpha1.SoundService/SetPitch", 7790 + ); 6732 7791 let mut req = request.into_request(); 6733 7792 req.extensions_mut() 6734 7793 .insert(GrpcMethod::new("rockbox.v1alpha1.SoundService", "SetPitch")); ··· 6737 7796 pub async fn beep_play( 6738 7797 &mut self, 6739 7798 request: impl tonic::IntoRequest<super::BeepPlayRequest>, 6740 - ) -> std::result::Result<tonic::Response<super::BeepPlayResponse>, tonic::Status> { 6741 - self.inner.ready().await.map_err(|e| { 6742 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6743 - })?; 7799 + ) -> std::result::Result< 7800 + tonic::Response<super::BeepPlayResponse>, 7801 + tonic::Status, 7802 + > { 7803 + self.inner 7804 + .ready() 7805 + .await 7806 + .map_err(|e| { 7807 + tonic::Status::unknown( 7808 + format!("Service was not ready: {}", e.into()), 7809 + ) 7810 + })?; 6744 7811 let codec = tonic::codec::ProstCodec::default(); 6745 - let path = 6746 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/BeepPlay"); 7812 + let path = http::uri::PathAndQuery::from_static( 7813 + "/rockbox.v1alpha1.SoundService/BeepPlay", 7814 + ); 6747 7815 let mut req = request.into_request(); 6748 7816 req.extensions_mut() 6749 7817 .insert(GrpcMethod::new("rockbox.v1alpha1.SoundService", "BeepPlay")); ··· 6752 7820 pub async fn pcmbuf_fade( 6753 7821 &mut self, 6754 7822 request: impl tonic::IntoRequest<super::PcmbufFadeRequest>, 6755 - ) -> std::result::Result<tonic::Response<super::PcmbufFadeResponse>, tonic::Status> 6756 - { 6757 - self.inner.ready().await.map_err(|e| { 6758 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6759 - })?; 7823 + ) -> std::result::Result< 7824 + tonic::Response<super::PcmbufFadeResponse>, 7825 + tonic::Status, 7826 + > { 7827 + self.inner 7828 + .ready() 7829 + .await 7830 + .map_err(|e| { 7831 + tonic::Status::unknown( 7832 + format!("Service was not ready: {}", e.into()), 7833 + ) 7834 + })?; 6760 7835 let codec = tonic::codec::ProstCodec::default(); 6761 - let path = 6762 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/PcmbufFade"); 7836 + let path = http::uri::PathAndQuery::from_static( 7837 + "/rockbox.v1alpha1.SoundService/PcmbufFade", 7838 + ); 6763 7839 let mut req = request.into_request(); 6764 - req.extensions_mut().insert(GrpcMethod::new( 6765 - "rockbox.v1alpha1.SoundService", 6766 - "PcmbufFade", 6767 - )); 7840 + req.extensions_mut() 7841 + .insert(GrpcMethod::new("rockbox.v1alpha1.SoundService", "PcmbufFade")); 6768 7842 self.inner.unary(req, path, codec).await 6769 7843 } 6770 7844 pub async fn pcmbuf_set_low_latency( 6771 7845 &mut self, 6772 7846 request: impl tonic::IntoRequest<super::PcmbufSetLowLatencyRequest>, 6773 - ) -> std::result::Result<tonic::Response<super::PcmbufSetLowLatencyResponse>, tonic::Status> 6774 - { 6775 - self.inner.ready().await.map_err(|e| { 6776 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6777 - })?; 7847 + ) -> std::result::Result< 7848 + tonic::Response<super::PcmbufSetLowLatencyResponse>, 7849 + tonic::Status, 7850 + > { 7851 + self.inner 7852 + .ready() 7853 + .await 7854 + .map_err(|e| { 7855 + tonic::Status::unknown( 7856 + format!("Service was not ready: {}", e.into()), 7857 + ) 7858 + })?; 6778 7859 let codec = tonic::codec::ProstCodec::default(); 6779 7860 let path = http::uri::PathAndQuery::from_static( 6780 7861 "/rockbox.v1alpha1.SoundService/PcmbufSetLowLatency", 6781 7862 ); 6782 7863 let mut req = request.into_request(); 6783 - req.extensions_mut().insert(GrpcMethod::new( 6784 - "rockbox.v1alpha1.SoundService", 6785 - "PcmbufSetLowLatency", 6786 - )); 7864 + req.extensions_mut() 7865 + .insert( 7866 + GrpcMethod::new( 7867 + "rockbox.v1alpha1.SoundService", 7868 + "PcmbufSetLowLatency", 7869 + ), 7870 + ); 6787 7871 self.inner.unary(req, path, codec).await 6788 7872 } 6789 7873 pub async fn system_sound_play( 6790 7874 &mut self, 6791 7875 request: impl tonic::IntoRequest<super::SystemSoundPlayRequest>, 6792 - ) -> std::result::Result<tonic::Response<super::SystemSoundPlayResponse>, tonic::Status> 6793 - { 6794 - self.inner.ready().await.map_err(|e| { 6795 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6796 - })?; 7876 + ) -> std::result::Result< 7877 + tonic::Response<super::SystemSoundPlayResponse>, 7878 + tonic::Status, 7879 + > { 7880 + self.inner 7881 + .ready() 7882 + .await 7883 + .map_err(|e| { 7884 + tonic::Status::unknown( 7885 + format!("Service was not ready: {}", e.into()), 7886 + ) 7887 + })?; 6797 7888 let codec = tonic::codec::ProstCodec::default(); 6798 7889 let path = http::uri::PathAndQuery::from_static( 6799 7890 "/rockbox.v1alpha1.SoundService/SystemSoundPlay", 6800 7891 ); 6801 7892 let mut req = request.into_request(); 6802 - req.extensions_mut().insert(GrpcMethod::new( 6803 - "rockbox.v1alpha1.SoundService", 6804 - "SystemSoundPlay", 6805 - )); 7893 + req.extensions_mut() 7894 + .insert( 7895 + GrpcMethod::new("rockbox.v1alpha1.SoundService", "SystemSoundPlay"), 7896 + ); 6806 7897 self.inner.unary(req, path, codec).await 6807 7898 } 6808 7899 pub async fn keyclick_click( 6809 7900 &mut self, 6810 7901 request: impl tonic::IntoRequest<super::KeyclickClickRequest>, 6811 - ) -> std::result::Result<tonic::Response<super::KeyclickClickResponse>, tonic::Status> 6812 - { 6813 - self.inner.ready().await.map_err(|e| { 6814 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6815 - })?; 7902 + ) -> std::result::Result< 7903 + tonic::Response<super::KeyclickClickResponse>, 7904 + tonic::Status, 7905 + > { 7906 + self.inner 7907 + .ready() 7908 + .await 7909 + .map_err(|e| { 7910 + tonic::Status::unknown( 7911 + format!("Service was not ready: {}", e.into()), 7912 + ) 7913 + })?; 6816 7914 let codec = tonic::codec::ProstCodec::default(); 6817 7915 let path = http::uri::PathAndQuery::from_static( 6818 7916 "/rockbox.v1alpha1.SoundService/KeyclickClick", 6819 7917 ); 6820 7918 let mut req = request.into_request(); 6821 - req.extensions_mut().insert(GrpcMethod::new( 6822 - "rockbox.v1alpha1.SoundService", 6823 - "KeyclickClick", 6824 - )); 7919 + req.extensions_mut() 7920 + .insert( 7921 + GrpcMethod::new("rockbox.v1alpha1.SoundService", "KeyclickClick"), 7922 + ); 6825 7923 self.inner.unary(req, path, codec).await 6826 7924 } 6827 7925 } ··· 6833 7931 dead_code, 6834 7932 missing_docs, 6835 7933 clippy::wildcard_imports, 6836 - clippy::let_unit_value 7934 + clippy::let_unit_value, 6837 7935 )] 6838 7936 use tonic::codegen::*; 6839 7937 /// Generated trait containing gRPC methods that should be implemented for use with SoundServiceServer. ··· 6842 7940 async fn adjust_volume( 6843 7941 &self, 6844 7942 request: tonic::Request<super::AdjustVolumeRequest>, 6845 - ) -> std::result::Result<tonic::Response<super::AdjustVolumeResponse>, tonic::Status>; 7943 + ) -> std::result::Result< 7944 + tonic::Response<super::AdjustVolumeResponse>, 7945 + tonic::Status, 7946 + >; 6846 7947 async fn sound_set( 6847 7948 &self, 6848 7949 request: tonic::Request<super::SoundSetRequest>, 6849 - ) -> std::result::Result<tonic::Response<super::SoundSetResponse>, tonic::Status>; 7950 + ) -> std::result::Result< 7951 + tonic::Response<super::SoundSetResponse>, 7952 + tonic::Status, 7953 + >; 6850 7954 async fn sound_current( 6851 7955 &self, 6852 7956 request: tonic::Request<super::SoundCurrentRequest>, 6853 - ) -> std::result::Result<tonic::Response<super::SoundCurrentResponse>, tonic::Status>; 7957 + ) -> std::result::Result< 7958 + tonic::Response<super::SoundCurrentResponse>, 7959 + tonic::Status, 7960 + >; 6854 7961 async fn sound_default( 6855 7962 &self, 6856 7963 request: tonic::Request<super::SoundDefaultRequest>, 6857 - ) -> std::result::Result<tonic::Response<super::SoundDefaultResponse>, tonic::Status>; 7964 + ) -> std::result::Result< 7965 + tonic::Response<super::SoundDefaultResponse>, 7966 + tonic::Status, 7967 + >; 6858 7968 async fn sound_min( 6859 7969 &self, 6860 7970 request: tonic::Request<super::SoundMinRequest>, 6861 - ) -> std::result::Result<tonic::Response<super::SoundMinResponse>, tonic::Status>; 7971 + ) -> std::result::Result< 7972 + tonic::Response<super::SoundMinResponse>, 7973 + tonic::Status, 7974 + >; 6862 7975 async fn sound_max( 6863 7976 &self, 6864 7977 request: tonic::Request<super::SoundMaxRequest>, 6865 - ) -> std::result::Result<tonic::Response<super::SoundMaxResponse>, tonic::Status>; 7978 + ) -> std::result::Result< 7979 + tonic::Response<super::SoundMaxResponse>, 7980 + tonic::Status, 7981 + >; 6866 7982 async fn sound_unit( 6867 7983 &self, 6868 7984 request: tonic::Request<super::SoundUnitRequest>, 6869 - ) -> std::result::Result<tonic::Response<super::SoundUnitResponse>, tonic::Status>; 7985 + ) -> std::result::Result< 7986 + tonic::Response<super::SoundUnitResponse>, 7987 + tonic::Status, 7988 + >; 6870 7989 async fn sound_val2_phys( 6871 7990 &self, 6872 7991 request: tonic::Request<super::SoundVal2PhysRequest>, 6873 - ) -> std::result::Result<tonic::Response<super::SoundVal2PhysResponse>, tonic::Status>; 7992 + ) -> std::result::Result< 7993 + tonic::Response<super::SoundVal2PhysResponse>, 7994 + tonic::Status, 7995 + >; 6874 7996 async fn get_pitch( 6875 7997 &self, 6876 7998 request: tonic::Request<super::GetPitchRequest>, 6877 - ) -> std::result::Result<tonic::Response<super::GetPitchResponse>, tonic::Status>; 7999 + ) -> std::result::Result< 8000 + tonic::Response<super::GetPitchResponse>, 8001 + tonic::Status, 8002 + >; 6878 8003 async fn set_pitch( 6879 8004 &self, 6880 8005 request: tonic::Request<super::SetPitchRequest>, 6881 - ) -> std::result::Result<tonic::Response<super::SetPitchResponse>, tonic::Status>; 8006 + ) -> std::result::Result< 8007 + tonic::Response<super::SetPitchResponse>, 8008 + tonic::Status, 8009 + >; 6882 8010 async fn beep_play( 6883 8011 &self, 6884 8012 request: tonic::Request<super::BeepPlayRequest>, 6885 - ) -> std::result::Result<tonic::Response<super::BeepPlayResponse>, tonic::Status>; 8013 + ) -> std::result::Result< 8014 + tonic::Response<super::BeepPlayResponse>, 8015 + tonic::Status, 8016 + >; 6886 8017 async fn pcmbuf_fade( 6887 8018 &self, 6888 8019 request: tonic::Request<super::PcmbufFadeRequest>, 6889 - ) -> std::result::Result<tonic::Response<super::PcmbufFadeResponse>, tonic::Status>; 8020 + ) -> std::result::Result< 8021 + tonic::Response<super::PcmbufFadeResponse>, 8022 + tonic::Status, 8023 + >; 6890 8024 async fn pcmbuf_set_low_latency( 6891 8025 &self, 6892 8026 request: tonic::Request<super::PcmbufSetLowLatencyRequest>, 6893 - ) -> std::result::Result<tonic::Response<super::PcmbufSetLowLatencyResponse>, tonic::Status>; 8027 + ) -> std::result::Result< 8028 + tonic::Response<super::PcmbufSetLowLatencyResponse>, 8029 + tonic::Status, 8030 + >; 6894 8031 async fn system_sound_play( 6895 8032 &self, 6896 8033 request: tonic::Request<super::SystemSoundPlayRequest>, 6897 - ) -> std::result::Result<tonic::Response<super::SystemSoundPlayResponse>, tonic::Status>; 8034 + ) -> std::result::Result< 8035 + tonic::Response<super::SystemSoundPlayResponse>, 8036 + tonic::Status, 8037 + >; 6898 8038 async fn keyclick_click( 6899 8039 &self, 6900 8040 request: tonic::Request<super::KeyclickClickRequest>, 6901 - ) -> std::result::Result<tonic::Response<super::KeyclickClickResponse>, tonic::Status>; 8041 + ) -> std::result::Result< 8042 + tonic::Response<super::KeyclickClickResponse>, 8043 + tonic::Status, 8044 + >; 6902 8045 } 6903 8046 #[derive(Debug)] 6904 8047 pub struct SoundServiceServer<T> { ··· 6921 8064 max_encoding_message_size: None, 6922 8065 } 6923 8066 } 6924 - pub fn with_interceptor<F>(inner: T, interceptor: F) -> InterceptedService<Self, F> 8067 + pub fn with_interceptor<F>( 8068 + inner: T, 8069 + interceptor: F, 8070 + ) -> InterceptedService<Self, F> 6925 8071 where 6926 8072 F: tonic::service::Interceptor, 6927 8073 { ··· 6976 8122 "/rockbox.v1alpha1.SoundService/AdjustVolume" => { 6977 8123 #[allow(non_camel_case_types)] 6978 8124 struct AdjustVolumeSvc<T: SoundService>(pub Arc<T>); 6979 - impl<T: SoundService> tonic::server::UnaryService<super::AdjustVolumeRequest> 6980 - for AdjustVolumeSvc<T> 6981 - { 8125 + impl< 8126 + T: SoundService, 8127 + > tonic::server::UnaryService<super::AdjustVolumeRequest> 8128 + for AdjustVolumeSvc<T> { 6982 8129 type Response = super::AdjustVolumeResponse; 6983 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8130 + type Future = BoxFuture< 8131 + tonic::Response<Self::Response>, 8132 + tonic::Status, 8133 + >; 6984 8134 fn call( 6985 8135 &mut self, 6986 8136 request: tonic::Request<super::AdjustVolumeRequest>, ··· 7017 8167 "/rockbox.v1alpha1.SoundService/SoundSet" => { 7018 8168 #[allow(non_camel_case_types)] 7019 8169 struct SoundSetSvc<T: SoundService>(pub Arc<T>); 7020 - impl<T: SoundService> tonic::server::UnaryService<super::SoundSetRequest> for SoundSetSvc<T> { 8170 + impl< 8171 + T: SoundService, 8172 + > tonic::server::UnaryService<super::SoundSetRequest> 8173 + for SoundSetSvc<T> { 7021 8174 type Response = super::SoundSetResponse; 7022 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8175 + type Future = BoxFuture< 8176 + tonic::Response<Self::Response>, 8177 + tonic::Status, 8178 + >; 7023 8179 fn call( 7024 8180 &mut self, 7025 8181 request: tonic::Request<super::SoundSetRequest>, ··· 7056 8212 "/rockbox.v1alpha1.SoundService/SoundCurrent" => { 7057 8213 #[allow(non_camel_case_types)] 7058 8214 struct SoundCurrentSvc<T: SoundService>(pub Arc<T>); 7059 - impl<T: SoundService> tonic::server::UnaryService<super::SoundCurrentRequest> 7060 - for SoundCurrentSvc<T> 7061 - { 8215 + impl< 8216 + T: SoundService, 8217 + > tonic::server::UnaryService<super::SoundCurrentRequest> 8218 + for SoundCurrentSvc<T> { 7062 8219 type Response = super::SoundCurrentResponse; 7063 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8220 + type Future = BoxFuture< 8221 + tonic::Response<Self::Response>, 8222 + tonic::Status, 8223 + >; 7064 8224 fn call( 7065 8225 &mut self, 7066 8226 request: tonic::Request<super::SoundCurrentRequest>, ··· 7097 8257 "/rockbox.v1alpha1.SoundService/SoundDefault" => { 7098 8258 #[allow(non_camel_case_types)] 7099 8259 struct SoundDefaultSvc<T: SoundService>(pub Arc<T>); 7100 - impl<T: SoundService> tonic::server::UnaryService<super::SoundDefaultRequest> 7101 - for SoundDefaultSvc<T> 7102 - { 8260 + impl< 8261 + T: SoundService, 8262 + > tonic::server::UnaryService<super::SoundDefaultRequest> 8263 + for SoundDefaultSvc<T> { 7103 8264 type Response = super::SoundDefaultResponse; 7104 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8265 + type Future = BoxFuture< 8266 + tonic::Response<Self::Response>, 8267 + tonic::Status, 8268 + >; 7105 8269 fn call( 7106 8270 &mut self, 7107 8271 request: tonic::Request<super::SoundDefaultRequest>, ··· 7138 8302 "/rockbox.v1alpha1.SoundService/SoundMin" => { 7139 8303 #[allow(non_camel_case_types)] 7140 8304 struct SoundMinSvc<T: SoundService>(pub Arc<T>); 7141 - impl<T: SoundService> tonic::server::UnaryService<super::SoundMinRequest> for SoundMinSvc<T> { 8305 + impl< 8306 + T: SoundService, 8307 + > tonic::server::UnaryService<super::SoundMinRequest> 8308 + for SoundMinSvc<T> { 7142 8309 type Response = super::SoundMinResponse; 7143 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8310 + type Future = BoxFuture< 8311 + tonic::Response<Self::Response>, 8312 + tonic::Status, 8313 + >; 7144 8314 fn call( 7145 8315 &mut self, 7146 8316 request: tonic::Request<super::SoundMinRequest>, ··· 7177 8347 "/rockbox.v1alpha1.SoundService/SoundMax" => { 7178 8348 #[allow(non_camel_case_types)] 7179 8349 struct SoundMaxSvc<T: SoundService>(pub Arc<T>); 7180 - impl<T: SoundService> tonic::server::UnaryService<super::SoundMaxRequest> for SoundMaxSvc<T> { 8350 + impl< 8351 + T: SoundService, 8352 + > tonic::server::UnaryService<super::SoundMaxRequest> 8353 + for SoundMaxSvc<T> { 7181 8354 type Response = super::SoundMaxResponse; 7182 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8355 + type Future = BoxFuture< 8356 + tonic::Response<Self::Response>, 8357 + tonic::Status, 8358 + >; 7183 8359 fn call( 7184 8360 &mut self, 7185 8361 request: tonic::Request<super::SoundMaxRequest>, ··· 7216 8392 "/rockbox.v1alpha1.SoundService/SoundUnit" => { 7217 8393 #[allow(non_camel_case_types)] 7218 8394 struct SoundUnitSvc<T: SoundService>(pub Arc<T>); 7219 - impl<T: SoundService> tonic::server::UnaryService<super::SoundUnitRequest> for SoundUnitSvc<T> { 8395 + impl< 8396 + T: SoundService, 8397 + > tonic::server::UnaryService<super::SoundUnitRequest> 8398 + for SoundUnitSvc<T> { 7220 8399 type Response = super::SoundUnitResponse; 7221 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8400 + type Future = BoxFuture< 8401 + tonic::Response<Self::Response>, 8402 + tonic::Status, 8403 + >; 7222 8404 fn call( 7223 8405 &mut self, 7224 8406 request: tonic::Request<super::SoundUnitRequest>, ··· 7255 8437 "/rockbox.v1alpha1.SoundService/SoundVal2Phys" => { 7256 8438 #[allow(non_camel_case_types)] 7257 8439 struct SoundVal2PhysSvc<T: SoundService>(pub Arc<T>); 7258 - impl<T: SoundService> tonic::server::UnaryService<super::SoundVal2PhysRequest> 7259 - for SoundVal2PhysSvc<T> 7260 - { 8440 + impl< 8441 + T: SoundService, 8442 + > tonic::server::UnaryService<super::SoundVal2PhysRequest> 8443 + for SoundVal2PhysSvc<T> { 7261 8444 type Response = super::SoundVal2PhysResponse; 7262 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8445 + type Future = BoxFuture< 8446 + tonic::Response<Self::Response>, 8447 + tonic::Status, 8448 + >; 7263 8449 fn call( 7264 8450 &mut self, 7265 8451 request: tonic::Request<super::SoundVal2PhysRequest>, ··· 7296 8482 "/rockbox.v1alpha1.SoundService/GetPitch" => { 7297 8483 #[allow(non_camel_case_types)] 7298 8484 struct GetPitchSvc<T: SoundService>(pub Arc<T>); 7299 - impl<T: SoundService> tonic::server::UnaryService<super::GetPitchRequest> for GetPitchSvc<T> { 8485 + impl< 8486 + T: SoundService, 8487 + > tonic::server::UnaryService<super::GetPitchRequest> 8488 + for GetPitchSvc<T> { 7300 8489 type Response = super::GetPitchResponse; 7301 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8490 + type Future = BoxFuture< 8491 + tonic::Response<Self::Response>, 8492 + tonic::Status, 8493 + >; 7302 8494 fn call( 7303 8495 &mut self, 7304 8496 request: tonic::Request<super::GetPitchRequest>, ··· 7335 8527 "/rockbox.v1alpha1.SoundService/SetPitch" => { 7336 8528 #[allow(non_camel_case_types)] 7337 8529 struct SetPitchSvc<T: SoundService>(pub Arc<T>); 7338 - impl<T: SoundService> tonic::server::UnaryService<super::SetPitchRequest> for SetPitchSvc<T> { 8530 + impl< 8531 + T: SoundService, 8532 + > tonic::server::UnaryService<super::SetPitchRequest> 8533 + for SetPitchSvc<T> { 7339 8534 type Response = super::SetPitchResponse; 7340 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8535 + type Future = BoxFuture< 8536 + tonic::Response<Self::Response>, 8537 + tonic::Status, 8538 + >; 7341 8539 fn call( 7342 8540 &mut self, 7343 8541 request: tonic::Request<super::SetPitchRequest>, ··· 7374 8572 "/rockbox.v1alpha1.SoundService/BeepPlay" => { 7375 8573 #[allow(non_camel_case_types)] 7376 8574 struct BeepPlaySvc<T: SoundService>(pub Arc<T>); 7377 - impl<T: SoundService> tonic::server::UnaryService<super::BeepPlayRequest> for BeepPlaySvc<T> { 8575 + impl< 8576 + T: SoundService, 8577 + > tonic::server::UnaryService<super::BeepPlayRequest> 8578 + for BeepPlaySvc<T> { 7378 8579 type Response = super::BeepPlayResponse; 7379 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8580 + type Future = BoxFuture< 8581 + tonic::Response<Self::Response>, 8582 + tonic::Status, 8583 + >; 7380 8584 fn call( 7381 8585 &mut self, 7382 8586 request: tonic::Request<super::BeepPlayRequest>, ··· 7413 8617 "/rockbox.v1alpha1.SoundService/PcmbufFade" => { 7414 8618 #[allow(non_camel_case_types)] 7415 8619 struct PcmbufFadeSvc<T: SoundService>(pub Arc<T>); 7416 - impl<T: SoundService> tonic::server::UnaryService<super::PcmbufFadeRequest> for PcmbufFadeSvc<T> { 8620 + impl< 8621 + T: SoundService, 8622 + > tonic::server::UnaryService<super::PcmbufFadeRequest> 8623 + for PcmbufFadeSvc<T> { 7417 8624 type Response = super::PcmbufFadeResponse; 7418 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8625 + type Future = BoxFuture< 8626 + tonic::Response<Self::Response>, 8627 + tonic::Status, 8628 + >; 7419 8629 fn call( 7420 8630 &mut self, 7421 8631 request: tonic::Request<super::PcmbufFadeRequest>, ··· 7452 8662 "/rockbox.v1alpha1.SoundService/PcmbufSetLowLatency" => { 7453 8663 #[allow(non_camel_case_types)] 7454 8664 struct PcmbufSetLowLatencySvc<T: SoundService>(pub Arc<T>); 7455 - impl<T: SoundService> 7456 - tonic::server::UnaryService<super::PcmbufSetLowLatencyRequest> 7457 - for PcmbufSetLowLatencySvc<T> 7458 - { 8665 + impl< 8666 + T: SoundService, 8667 + > tonic::server::UnaryService<super::PcmbufSetLowLatencyRequest> 8668 + for PcmbufSetLowLatencySvc<T> { 7459 8669 type Response = super::PcmbufSetLowLatencyResponse; 7460 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8670 + type Future = BoxFuture< 8671 + tonic::Response<Self::Response>, 8672 + tonic::Status, 8673 + >; 7461 8674 fn call( 7462 8675 &mut self, 7463 8676 request: tonic::Request<super::PcmbufSetLowLatencyRequest>, 7464 8677 ) -> Self::Future { 7465 8678 let inner = Arc::clone(&self.0); 7466 8679 let fut = async move { 7467 - <T as SoundService>::pcmbuf_set_low_latency(&inner, request).await 8680 + <T as SoundService>::pcmbuf_set_low_latency(&inner, request) 8681 + .await 7468 8682 }; 7469 8683 Box::pin(fut) 7470 8684 } ··· 7494 8708 "/rockbox.v1alpha1.SoundService/SystemSoundPlay" => { 7495 8709 #[allow(non_camel_case_types)] 7496 8710 struct SystemSoundPlaySvc<T: SoundService>(pub Arc<T>); 7497 - impl<T: SoundService> tonic::server::UnaryService<super::SystemSoundPlayRequest> 7498 - for SystemSoundPlaySvc<T> 7499 - { 8711 + impl< 8712 + T: SoundService, 8713 + > tonic::server::UnaryService<super::SystemSoundPlayRequest> 8714 + for SystemSoundPlaySvc<T> { 7500 8715 type Response = super::SystemSoundPlayResponse; 7501 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8716 + type Future = BoxFuture< 8717 + tonic::Response<Self::Response>, 8718 + tonic::Status, 8719 + >; 7502 8720 fn call( 7503 8721 &mut self, 7504 8722 request: tonic::Request<super::SystemSoundPlayRequest>, 7505 8723 ) -> Self::Future { 7506 8724 let inner = Arc::clone(&self.0); 7507 8725 let fut = async move { 7508 - <T as SoundService>::system_sound_play(&inner, request).await 8726 + <T as SoundService>::system_sound_play(&inner, request) 8727 + .await 7509 8728 }; 7510 8729 Box::pin(fut) 7511 8730 } ··· 7535 8754 "/rockbox.v1alpha1.SoundService/KeyclickClick" => { 7536 8755 #[allow(non_camel_case_types)] 7537 8756 struct KeyclickClickSvc<T: SoundService>(pub Arc<T>); 7538 - impl<T: SoundService> tonic::server::UnaryService<super::KeyclickClickRequest> 7539 - for KeyclickClickSvc<T> 7540 - { 8757 + impl< 8758 + T: SoundService, 8759 + > tonic::server::UnaryService<super::KeyclickClickRequest> 8760 + for KeyclickClickSvc<T> { 7541 8761 type Response = super::KeyclickClickResponse; 7542 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8762 + type Future = BoxFuture< 8763 + tonic::Response<Self::Response>, 8764 + tonic::Status, 8765 + >; 7543 8766 fn call( 7544 8767 &mut self, 7545 8768 request: tonic::Request<super::KeyclickClickRequest>, ··· 7573 8796 }; 7574 8797 Box::pin(fut) 7575 8798 } 7576 - _ => Box::pin(async move { 7577 - let mut response = http::Response::new(empty_body()); 7578 - let headers = response.headers_mut(); 7579 - headers.insert( 7580 - tonic::Status::GRPC_STATUS, 7581 - (tonic::Code::Unimplemented as i32).into(), 7582 - ); 7583 - headers.insert( 7584 - http::header::CONTENT_TYPE, 7585 - tonic::metadata::GRPC_CONTENT_TYPE, 7586 - ); 7587 - Ok(response) 7588 - }), 8799 + _ => { 8800 + Box::pin(async move { 8801 + let mut response = http::Response::new(empty_body()); 8802 + let headers = response.headers_mut(); 8803 + headers 8804 + .insert( 8805 + tonic::Status::GRPC_STATUS, 8806 + (tonic::Code::Unimplemented as i32).into(), 8807 + ); 8808 + headers 8809 + .insert( 8810 + http::header::CONTENT_TYPE, 8811 + tonic::metadata::GRPC_CONTENT_TYPE, 8812 + ); 8813 + Ok(response) 8814 + }) 8815 + } 7589 8816 } 7590 8817 } 7591 8818 } ··· 7646 8873 dead_code, 7647 8874 missing_docs, 7648 8875 clippy::wildcard_imports, 7649 - clippy::let_unit_value 8876 + clippy::let_unit_value, 7650 8877 )] 8878 + use tonic::codegen::*; 7651 8879 use tonic::codegen::http::Uri; 7652 - use tonic::codegen::*; 7653 8880 #[derive(Debug, Clone)] 7654 8881 pub struct SystemServiceClient<T> { 7655 8882 inner: tonic::client::Grpc<T>, ··· 7693 8920 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody, 7694 8921 >, 7695 8922 >, 7696 - <T as tonic::codegen::Service<http::Request<tonic::body::BoxBody>>>::Error: 7697 - Into<StdError> + std::marker::Send + std::marker::Sync, 8923 + <T as tonic::codegen::Service< 8924 + http::Request<tonic::body::BoxBody>, 8925 + >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync, 7698 8926 { 7699 8927 SystemServiceClient::new(InterceptedService::new(inner, interceptor)) 7700 8928 } ··· 7732 8960 pub async fn get_rockbox_version( 7733 8961 &mut self, 7734 8962 request: impl tonic::IntoRequest<super::GetRockboxVersionRequest>, 7735 - ) -> std::result::Result<tonic::Response<super::GetRockboxVersionResponse>, tonic::Status> 7736 - { 7737 - self.inner.ready().await.map_err(|e| { 7738 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 7739 - })?; 8963 + ) -> std::result::Result< 8964 + tonic::Response<super::GetRockboxVersionResponse>, 8965 + tonic::Status, 8966 + > { 8967 + self.inner 8968 + .ready() 8969 + .await 8970 + .map_err(|e| { 8971 + tonic::Status::unknown( 8972 + format!("Service was not ready: {}", e.into()), 8973 + ) 8974 + })?; 7740 8975 let codec = tonic::codec::ProstCodec::default(); 7741 8976 let path = http::uri::PathAndQuery::from_static( 7742 8977 "/rockbox.v1alpha1.SystemService/GetRockboxVersion", 7743 8978 ); 7744 8979 let mut req = request.into_request(); 7745 - req.extensions_mut().insert(GrpcMethod::new( 7746 - "rockbox.v1alpha1.SystemService", 7747 - "GetRockboxVersion", 7748 - )); 8980 + req.extensions_mut() 8981 + .insert( 8982 + GrpcMethod::new( 8983 + "rockbox.v1alpha1.SystemService", 8984 + "GetRockboxVersion", 8985 + ), 8986 + ); 7749 8987 self.inner.unary(req, path, codec).await 7750 8988 } 7751 8989 pub async fn get_global_status( 7752 8990 &mut self, 7753 8991 request: impl tonic::IntoRequest<super::GetGlobalStatusRequest>, 7754 - ) -> std::result::Result<tonic::Response<super::GetGlobalStatusResponse>, tonic::Status> 7755 - { 7756 - self.inner.ready().await.map_err(|e| { 7757 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 7758 - })?; 8992 + ) -> std::result::Result< 8993 + tonic::Response<super::GetGlobalStatusResponse>, 8994 + tonic::Status, 8995 + > { 8996 + self.inner 8997 + .ready() 8998 + .await 8999 + .map_err(|e| { 9000 + tonic::Status::unknown( 9001 + format!("Service was not ready: {}", e.into()), 9002 + ) 9003 + })?; 7759 9004 let codec = tonic::codec::ProstCodec::default(); 7760 9005 let path = http::uri::PathAndQuery::from_static( 7761 9006 "/rockbox.v1alpha1.SystemService/GetGlobalStatus", 7762 9007 ); 7763 9008 let mut req = request.into_request(); 7764 - req.extensions_mut().insert(GrpcMethod::new( 7765 - "rockbox.v1alpha1.SystemService", 7766 - "GetGlobalStatus", 7767 - )); 9009 + req.extensions_mut() 9010 + .insert( 9011 + GrpcMethod::new("rockbox.v1alpha1.SystemService", "GetGlobalStatus"), 9012 + ); 7768 9013 self.inner.unary(req, path, codec).await 7769 9014 } 7770 9015 } ··· 7776 9021 dead_code, 7777 9022 missing_docs, 7778 9023 clippy::wildcard_imports, 7779 - clippy::let_unit_value 9024 + clippy::let_unit_value, 7780 9025 )] 7781 9026 use tonic::codegen::*; 7782 9027 /// Generated trait containing gRPC methods that should be implemented for use with SystemServiceServer. ··· 7785 9030 async fn get_rockbox_version( 7786 9031 &self, 7787 9032 request: tonic::Request<super::GetRockboxVersionRequest>, 7788 - ) -> std::result::Result<tonic::Response<super::GetRockboxVersionResponse>, tonic::Status>; 9033 + ) -> std::result::Result< 9034 + tonic::Response<super::GetRockboxVersionResponse>, 9035 + tonic::Status, 9036 + >; 7789 9037 async fn get_global_status( 7790 9038 &self, 7791 9039 request: tonic::Request<super::GetGlobalStatusRequest>, 7792 - ) -> std::result::Result<tonic::Response<super::GetGlobalStatusResponse>, tonic::Status>; 9040 + ) -> std::result::Result< 9041 + tonic::Response<super::GetGlobalStatusResponse>, 9042 + tonic::Status, 9043 + >; 7793 9044 } 7794 9045 #[derive(Debug)] 7795 9046 pub struct SystemServiceServer<T> { ··· 7812 9063 max_encoding_message_size: None, 7813 9064 } 7814 9065 } 7815 - pub fn with_interceptor<F>(inner: T, interceptor: F) -> InterceptedService<Self, F> 9066 + pub fn with_interceptor<F>( 9067 + inner: T, 9068 + interceptor: F, 9069 + ) -> InterceptedService<Self, F> 7816 9070 where 7817 9071 F: tonic::service::Interceptor, 7818 9072 { ··· 7867 9121 "/rockbox.v1alpha1.SystemService/GetRockboxVersion" => { 7868 9122 #[allow(non_camel_case_types)] 7869 9123 struct GetRockboxVersionSvc<T: SystemService>(pub Arc<T>); 7870 - impl<T: SystemService> 7871 - tonic::server::UnaryService<super::GetRockboxVersionRequest> 7872 - for GetRockboxVersionSvc<T> 7873 - { 9124 + impl< 9125 + T: SystemService, 9126 + > tonic::server::UnaryService<super::GetRockboxVersionRequest> 9127 + for GetRockboxVersionSvc<T> { 7874 9128 type Response = super::GetRockboxVersionResponse; 7875 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 9129 + type Future = BoxFuture< 9130 + tonic::Response<Self::Response>, 9131 + tonic::Status, 9132 + >; 7876 9133 fn call( 7877 9134 &mut self, 7878 9135 request: tonic::Request<super::GetRockboxVersionRequest>, 7879 9136 ) -> Self::Future { 7880 9137 let inner = Arc::clone(&self.0); 7881 9138 let fut = async move { 7882 - <T as SystemService>::get_rockbox_version(&inner, request).await 9139 + <T as SystemService>::get_rockbox_version(&inner, request) 9140 + .await 7883 9141 }; 7884 9142 Box::pin(fut) 7885 9143 } ··· 7909 9167 "/rockbox.v1alpha1.SystemService/GetGlobalStatus" => { 7910 9168 #[allow(non_camel_case_types)] 7911 9169 struct GetGlobalStatusSvc<T: SystemService>(pub Arc<T>); 7912 - impl<T: SystemService> 7913 - tonic::server::UnaryService<super::GetGlobalStatusRequest> 7914 - for GetGlobalStatusSvc<T> 7915 - { 9170 + impl< 9171 + T: SystemService, 9172 + > tonic::server::UnaryService<super::GetGlobalStatusRequest> 9173 + for GetGlobalStatusSvc<T> { 7916 9174 type Response = super::GetGlobalStatusResponse; 7917 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 9175 + type Future = BoxFuture< 9176 + tonic::Response<Self::Response>, 9177 + tonic::Status, 9178 + >; 7918 9179 fn call( 7919 9180 &mut self, 7920 9181 request: tonic::Request<super::GetGlobalStatusRequest>, 7921 9182 ) -> Self::Future { 7922 9183 let inner = Arc::clone(&self.0); 7923 9184 let fut = async move { 7924 - <T as SystemService>::get_global_status(&inner, request).await 9185 + <T as SystemService>::get_global_status(&inner, request) 9186 + .await 7925 9187 }; 7926 9188 Box::pin(fut) 7927 9189 } ··· 7948 9210 }; 7949 9211 Box::pin(fut) 7950 9212 } 7951 - _ => Box::pin(async move { 7952 - let mut response = http::Response::new(empty_body()); 7953 - let headers = response.headers_mut(); 7954 - headers.insert( 7955 - tonic::Status::GRPC_STATUS, 7956 - (tonic::Code::Unimplemented as i32).into(), 7957 - ); 7958 - headers.insert( 7959 - http::header::CONTENT_TYPE, 7960 - tonic::metadata::GRPC_CONTENT_TYPE, 7961 - ); 7962 - Ok(response) 7963 - }), 9213 + _ => { 9214 + Box::pin(async move { 9215 + let mut response = http::Response::new(empty_body()); 9216 + let headers = response.headers_mut(); 9217 + headers 9218 + .insert( 9219 + tonic::Status::GRPC_STATUS, 9220 + (tonic::Code::Unimplemented as i32).into(), 9221 + ); 9222 + headers 9223 + .insert( 9224 + http::header::CONTENT_TYPE, 9225 + tonic::metadata::GRPC_CONTENT_TYPE, 9226 + ); 9227 + Ok(response) 9228 + }) 9229 + } 7964 9230 } 7965 9231 } 7966 9232 }
+2649 -1316
crates/rpc/src/api/rockbox.v1alpha1.rs
··· 43 43 dead_code, 44 44 missing_docs, 45 45 clippy::wildcard_imports, 46 - clippy::let_unit_value 46 + clippy::let_unit_value, 47 47 )] 48 - use tonic::codegen::http::Uri; 49 48 use tonic::codegen::*; 49 + use tonic::codegen::http::Uri; 50 50 #[derive(Debug, Clone)] 51 51 pub struct BrowseServiceClient<T> { 52 52 inner: tonic::client::Grpc<T>, ··· 90 90 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody, 91 91 >, 92 92 >, 93 - <T as tonic::codegen::Service<http::Request<tonic::body::BoxBody>>>::Error: 94 - Into<StdError> + std::marker::Send + std::marker::Sync, 93 + <T as tonic::codegen::Service< 94 + http::Request<tonic::body::BoxBody>, 95 + >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync, 95 96 { 96 97 BrowseServiceClient::new(InterceptedService::new(inner, interceptor)) 97 98 } ··· 129 130 pub async fn tree_get_entries( 130 131 &mut self, 131 132 request: impl tonic::IntoRequest<super::TreeGetEntriesRequest>, 132 - ) -> std::result::Result<tonic::Response<super::TreeGetEntriesResponse>, tonic::Status> 133 - { 134 - self.inner.ready().await.map_err(|e| { 135 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 136 - })?; 133 + ) -> std::result::Result< 134 + tonic::Response<super::TreeGetEntriesResponse>, 135 + tonic::Status, 136 + > { 137 + self.inner 138 + .ready() 139 + .await 140 + .map_err(|e| { 141 + tonic::Status::unknown( 142 + format!("Service was not ready: {}", e.into()), 143 + ) 144 + })?; 137 145 let codec = tonic::codec::ProstCodec::default(); 138 146 let path = http::uri::PathAndQuery::from_static( 139 147 "/rockbox.v1alpha1.BrowseService/TreeGetEntries", 140 148 ); 141 149 let mut req = request.into_request(); 142 - req.extensions_mut().insert(GrpcMethod::new( 143 - "rockbox.v1alpha1.BrowseService", 144 - "TreeGetEntries", 145 - )); 150 + req.extensions_mut() 151 + .insert( 152 + GrpcMethod::new("rockbox.v1alpha1.BrowseService", "TreeGetEntries"), 153 + ); 146 154 self.inner.unary(req, path, codec).await 147 155 } 148 156 } ··· 154 162 dead_code, 155 163 missing_docs, 156 164 clippy::wildcard_imports, 157 - clippy::let_unit_value 165 + clippy::let_unit_value, 158 166 )] 159 167 use tonic::codegen::*; 160 168 /// Generated trait containing gRPC methods that should be implemented for use with BrowseServiceServer. ··· 163 171 async fn tree_get_entries( 164 172 &self, 165 173 request: tonic::Request<super::TreeGetEntriesRequest>, 166 - ) -> std::result::Result<tonic::Response<super::TreeGetEntriesResponse>, tonic::Status>; 174 + ) -> std::result::Result< 175 + tonic::Response<super::TreeGetEntriesResponse>, 176 + tonic::Status, 177 + >; 167 178 } 168 179 #[derive(Debug)] 169 180 pub struct BrowseServiceServer<T> { ··· 186 197 max_encoding_message_size: None, 187 198 } 188 199 } 189 - pub fn with_interceptor<F>(inner: T, interceptor: F) -> InterceptedService<Self, F> 200 + pub fn with_interceptor<F>( 201 + inner: T, 202 + interceptor: F, 203 + ) -> InterceptedService<Self, F> 190 204 where 191 205 F: tonic::service::Interceptor, 192 206 { ··· 241 255 "/rockbox.v1alpha1.BrowseService/TreeGetEntries" => { 242 256 #[allow(non_camel_case_types)] 243 257 struct TreeGetEntriesSvc<T: BrowseService>(pub Arc<T>); 244 - impl<T: BrowseService> tonic::server::UnaryService<super::TreeGetEntriesRequest> 245 - for TreeGetEntriesSvc<T> 246 - { 258 + impl< 259 + T: BrowseService, 260 + > tonic::server::UnaryService<super::TreeGetEntriesRequest> 261 + for TreeGetEntriesSvc<T> { 247 262 type Response = super::TreeGetEntriesResponse; 248 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 263 + type Future = BoxFuture< 264 + tonic::Response<Self::Response>, 265 + tonic::Status, 266 + >; 249 267 fn call( 250 268 &mut self, 251 269 request: tonic::Request<super::TreeGetEntriesRequest>, 252 270 ) -> Self::Future { 253 271 let inner = Arc::clone(&self.0); 254 272 let fut = async move { 255 - <T as BrowseService>::tree_get_entries(&inner, request).await 273 + <T as BrowseService>::tree_get_entries(&inner, request) 274 + .await 256 275 }; 257 276 Box::pin(fut) 258 277 } ··· 279 298 }; 280 299 Box::pin(fut) 281 300 } 282 - _ => Box::pin(async move { 283 - let mut response = http::Response::new(empty_body()); 284 - let headers = response.headers_mut(); 285 - headers.insert( 286 - tonic::Status::GRPC_STATUS, 287 - (tonic::Code::Unimplemented as i32).into(), 288 - ); 289 - headers.insert( 290 - http::header::CONTENT_TYPE, 291 - tonic::metadata::GRPC_CONTENT_TYPE, 292 - ); 293 - Ok(response) 294 - }), 301 + _ => { 302 + Box::pin(async move { 303 + let mut response = http::Response::new(empty_body()); 304 + let headers = response.headers_mut(); 305 + headers 306 + .insert( 307 + tonic::Status::GRPC_STATUS, 308 + (tonic::Code::Unimplemented as i32).into(), 309 + ); 310 + headers 311 + .insert( 312 + http::header::CONTENT_TYPE, 313 + tonic::metadata::GRPC_CONTENT_TYPE, 314 + ); 315 + Ok(response) 316 + }) 317 + } 295 318 } 296 319 } 297 320 } ··· 384 407 dead_code, 385 408 missing_docs, 386 409 clippy::wildcard_imports, 387 - clippy::let_unit_value 410 + clippy::let_unit_value, 388 411 )] 389 - use tonic::codegen::http::Uri; 390 412 use tonic::codegen::*; 413 + use tonic::codegen::http::Uri; 391 414 #[derive(Debug, Clone)] 392 415 pub struct DeviceServiceClient<T> { 393 416 inner: tonic::client::Grpc<T>, ··· 431 454 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody, 432 455 >, 433 456 >, 434 - <T as tonic::codegen::Service<http::Request<tonic::body::BoxBody>>>::Error: 435 - Into<StdError> + std::marker::Send + std::marker::Sync, 457 + <T as tonic::codegen::Service< 458 + http::Request<tonic::body::BoxBody>, 459 + >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync, 436 460 { 437 461 DeviceServiceClient::new(InterceptedService::new(inner, interceptor)) 438 462 } ··· 470 494 pub async fn get_devices( 471 495 &mut self, 472 496 request: impl tonic::IntoRequest<super::GetDevicesRequest>, 473 - ) -> std::result::Result<tonic::Response<super::GetDevicesResponse>, tonic::Status> 474 - { 475 - self.inner.ready().await.map_err(|e| { 476 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 477 - })?; 497 + ) -> std::result::Result< 498 + tonic::Response<super::GetDevicesResponse>, 499 + tonic::Status, 500 + > { 501 + self.inner 502 + .ready() 503 + .await 504 + .map_err(|e| { 505 + tonic::Status::unknown( 506 + format!("Service was not ready: {}", e.into()), 507 + ) 508 + })?; 478 509 let codec = tonic::codec::ProstCodec::default(); 479 - let path = 480 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.DeviceService/GetDevices"); 510 + let path = http::uri::PathAndQuery::from_static( 511 + "/rockbox.v1alpha1.DeviceService/GetDevices", 512 + ); 481 513 let mut req = request.into_request(); 482 - req.extensions_mut().insert(GrpcMethod::new( 483 - "rockbox.v1alpha1.DeviceService", 484 - "GetDevices", 485 - )); 514 + req.extensions_mut() 515 + .insert(GrpcMethod::new("rockbox.v1alpha1.DeviceService", "GetDevices")); 486 516 self.inner.unary(req, path, codec).await 487 517 } 488 518 pub async fn get_device( 489 519 &mut self, 490 520 request: impl tonic::IntoRequest<super::GetDeviceRequest>, 491 - ) -> std::result::Result<tonic::Response<super::GetDeviceResponse>, tonic::Status> { 492 - self.inner.ready().await.map_err(|e| { 493 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 494 - })?; 521 + ) -> std::result::Result< 522 + tonic::Response<super::GetDeviceResponse>, 523 + tonic::Status, 524 + > { 525 + self.inner 526 + .ready() 527 + .await 528 + .map_err(|e| { 529 + tonic::Status::unknown( 530 + format!("Service was not ready: {}", e.into()), 531 + ) 532 + })?; 495 533 let codec = tonic::codec::ProstCodec::default(); 496 - let path = 497 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.DeviceService/GetDevice"); 534 + let path = http::uri::PathAndQuery::from_static( 535 + "/rockbox.v1alpha1.DeviceService/GetDevice", 536 + ); 498 537 let mut req = request.into_request(); 499 - req.extensions_mut().insert(GrpcMethod::new( 500 - "rockbox.v1alpha1.DeviceService", 501 - "GetDevice", 502 - )); 538 + req.extensions_mut() 539 + .insert(GrpcMethod::new("rockbox.v1alpha1.DeviceService", "GetDevice")); 503 540 self.inner.unary(req, path, codec).await 504 541 } 505 542 pub async fn connect_device( 506 543 &mut self, 507 544 request: impl tonic::IntoRequest<super::ConnectDeviceRequest>, 508 - ) -> std::result::Result<tonic::Response<super::ConnectDeviceResponse>, tonic::Status> 509 - { 510 - self.inner.ready().await.map_err(|e| { 511 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 512 - })?; 545 + ) -> std::result::Result< 546 + tonic::Response<super::ConnectDeviceResponse>, 547 + tonic::Status, 548 + > { 549 + self.inner 550 + .ready() 551 + .await 552 + .map_err(|e| { 553 + tonic::Status::unknown( 554 + format!("Service was not ready: {}", e.into()), 555 + ) 556 + })?; 513 557 let codec = tonic::codec::ProstCodec::default(); 514 558 let path = http::uri::PathAndQuery::from_static( 515 559 "/rockbox.v1alpha1.DeviceService/ConnectDevice", 516 560 ); 517 561 let mut req = request.into_request(); 518 - req.extensions_mut().insert(GrpcMethod::new( 519 - "rockbox.v1alpha1.DeviceService", 520 - "ConnectDevice", 521 - )); 562 + req.extensions_mut() 563 + .insert( 564 + GrpcMethod::new("rockbox.v1alpha1.DeviceService", "ConnectDevice"), 565 + ); 522 566 self.inner.unary(req, path, codec).await 523 567 } 524 568 pub async fn disconnect_device( 525 569 &mut self, 526 570 request: impl tonic::IntoRequest<super::DisconnectDeviceRequest>, 527 - ) -> std::result::Result<tonic::Response<super::DisconnectDeviceResponse>, tonic::Status> 528 - { 529 - self.inner.ready().await.map_err(|e| { 530 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 531 - })?; 571 + ) -> std::result::Result< 572 + tonic::Response<super::DisconnectDeviceResponse>, 573 + tonic::Status, 574 + > { 575 + self.inner 576 + .ready() 577 + .await 578 + .map_err(|e| { 579 + tonic::Status::unknown( 580 + format!("Service was not ready: {}", e.into()), 581 + ) 582 + })?; 532 583 let codec = tonic::codec::ProstCodec::default(); 533 584 let path = http::uri::PathAndQuery::from_static( 534 585 "/rockbox.v1alpha1.DeviceService/DisconnectDevice", 535 586 ); 536 587 let mut req = request.into_request(); 537 - req.extensions_mut().insert(GrpcMethod::new( 538 - "rockbox.v1alpha1.DeviceService", 539 - "DisconnectDevice", 540 - )); 588 + req.extensions_mut() 589 + .insert( 590 + GrpcMethod::new("rockbox.v1alpha1.DeviceService", "DisconnectDevice"), 591 + ); 541 592 self.inner.unary(req, path, codec).await 542 593 } 543 594 } ··· 549 600 dead_code, 550 601 missing_docs, 551 602 clippy::wildcard_imports, 552 - clippy::let_unit_value 603 + clippy::let_unit_value, 553 604 )] 554 605 use tonic::codegen::*; 555 606 /// Generated trait containing gRPC methods that should be implemented for use with DeviceServiceServer. ··· 558 609 async fn get_devices( 559 610 &self, 560 611 request: tonic::Request<super::GetDevicesRequest>, 561 - ) -> std::result::Result<tonic::Response<super::GetDevicesResponse>, tonic::Status>; 612 + ) -> std::result::Result< 613 + tonic::Response<super::GetDevicesResponse>, 614 + tonic::Status, 615 + >; 562 616 async fn get_device( 563 617 &self, 564 618 request: tonic::Request<super::GetDeviceRequest>, 565 - ) -> std::result::Result<tonic::Response<super::GetDeviceResponse>, tonic::Status>; 619 + ) -> std::result::Result< 620 + tonic::Response<super::GetDeviceResponse>, 621 + tonic::Status, 622 + >; 566 623 async fn connect_device( 567 624 &self, 568 625 request: tonic::Request<super::ConnectDeviceRequest>, 569 - ) -> std::result::Result<tonic::Response<super::ConnectDeviceResponse>, tonic::Status>; 626 + ) -> std::result::Result< 627 + tonic::Response<super::ConnectDeviceResponse>, 628 + tonic::Status, 629 + >; 570 630 async fn disconnect_device( 571 631 &self, 572 632 request: tonic::Request<super::DisconnectDeviceRequest>, 573 - ) -> std::result::Result<tonic::Response<super::DisconnectDeviceResponse>, tonic::Status>; 633 + ) -> std::result::Result< 634 + tonic::Response<super::DisconnectDeviceResponse>, 635 + tonic::Status, 636 + >; 574 637 } 575 638 #[derive(Debug)] 576 639 pub struct DeviceServiceServer<T> { ··· 593 656 max_encoding_message_size: None, 594 657 } 595 658 } 596 - pub fn with_interceptor<F>(inner: T, interceptor: F) -> InterceptedService<Self, F> 659 + pub fn with_interceptor<F>( 660 + inner: T, 661 + interceptor: F, 662 + ) -> InterceptedService<Self, F> 597 663 where 598 664 F: tonic::service::Interceptor, 599 665 { ··· 648 714 "/rockbox.v1alpha1.DeviceService/GetDevices" => { 649 715 #[allow(non_camel_case_types)] 650 716 struct GetDevicesSvc<T: DeviceService>(pub Arc<T>); 651 - impl<T: DeviceService> tonic::server::UnaryService<super::GetDevicesRequest> for GetDevicesSvc<T> { 717 + impl< 718 + T: DeviceService, 719 + > tonic::server::UnaryService<super::GetDevicesRequest> 720 + for GetDevicesSvc<T> { 652 721 type Response = super::GetDevicesResponse; 653 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 722 + type Future = BoxFuture< 723 + tonic::Response<Self::Response>, 724 + tonic::Status, 725 + >; 654 726 fn call( 655 727 &mut self, 656 728 request: tonic::Request<super::GetDevicesRequest>, ··· 687 759 "/rockbox.v1alpha1.DeviceService/GetDevice" => { 688 760 #[allow(non_camel_case_types)] 689 761 struct GetDeviceSvc<T: DeviceService>(pub Arc<T>); 690 - impl<T: DeviceService> tonic::server::UnaryService<super::GetDeviceRequest> for GetDeviceSvc<T> { 762 + impl< 763 + T: DeviceService, 764 + > tonic::server::UnaryService<super::GetDeviceRequest> 765 + for GetDeviceSvc<T> { 691 766 type Response = super::GetDeviceResponse; 692 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 767 + type Future = BoxFuture< 768 + tonic::Response<Self::Response>, 769 + tonic::Status, 770 + >; 693 771 fn call( 694 772 &mut self, 695 773 request: tonic::Request<super::GetDeviceRequest>, ··· 726 804 "/rockbox.v1alpha1.DeviceService/ConnectDevice" => { 727 805 #[allow(non_camel_case_types)] 728 806 struct ConnectDeviceSvc<T: DeviceService>(pub Arc<T>); 729 - impl<T: DeviceService> tonic::server::UnaryService<super::ConnectDeviceRequest> 730 - for ConnectDeviceSvc<T> 731 - { 807 + impl< 808 + T: DeviceService, 809 + > tonic::server::UnaryService<super::ConnectDeviceRequest> 810 + for ConnectDeviceSvc<T> { 732 811 type Response = super::ConnectDeviceResponse; 733 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 812 + type Future = BoxFuture< 813 + tonic::Response<Self::Response>, 814 + tonic::Status, 815 + >; 734 816 fn call( 735 817 &mut self, 736 818 request: tonic::Request<super::ConnectDeviceRequest>, ··· 767 849 "/rockbox.v1alpha1.DeviceService/DisconnectDevice" => { 768 850 #[allow(non_camel_case_types)] 769 851 struct DisconnectDeviceSvc<T: DeviceService>(pub Arc<T>); 770 - impl<T: DeviceService> 771 - tonic::server::UnaryService<super::DisconnectDeviceRequest> 772 - for DisconnectDeviceSvc<T> 773 - { 852 + impl< 853 + T: DeviceService, 854 + > tonic::server::UnaryService<super::DisconnectDeviceRequest> 855 + for DisconnectDeviceSvc<T> { 774 856 type Response = super::DisconnectDeviceResponse; 775 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 857 + type Future = BoxFuture< 858 + tonic::Response<Self::Response>, 859 + tonic::Status, 860 + >; 776 861 fn call( 777 862 &mut self, 778 863 request: tonic::Request<super::DisconnectDeviceRequest>, 779 864 ) -> Self::Future { 780 865 let inner = Arc::clone(&self.0); 781 866 let fut = async move { 782 - <T as DeviceService>::disconnect_device(&inner, request).await 867 + <T as DeviceService>::disconnect_device(&inner, request) 868 + .await 783 869 }; 784 870 Box::pin(fut) 785 871 } ··· 806 892 }; 807 893 Box::pin(fut) 808 894 } 809 - _ => Box::pin(async move { 810 - let mut response = http::Response::new(empty_body()); 811 - let headers = response.headers_mut(); 812 - headers.insert( 813 - tonic::Status::GRPC_STATUS, 814 - (tonic::Code::Unimplemented as i32).into(), 815 - ); 816 - headers.insert( 817 - http::header::CONTENT_TYPE, 818 - tonic::metadata::GRPC_CONTENT_TYPE, 819 - ); 820 - Ok(response) 821 - }), 895 + _ => { 896 + Box::pin(async move { 897 + let mut response = http::Response::new(empty_body()); 898 + let headers = response.headers_mut(); 899 + headers 900 + .insert( 901 + tonic::Status::GRPC_STATUS, 902 + (tonic::Code::Unimplemented as i32).into(), 903 + ); 904 + headers 905 + .insert( 906 + http::header::CONTENT_TYPE, 907 + tonic::metadata::GRPC_CONTENT_TYPE, 908 + ); 909 + Ok(response) 910 + }) 911 + } 822 912 } 823 913 } 824 914 } ··· 1054 1144 dead_code, 1055 1145 missing_docs, 1056 1146 clippy::wildcard_imports, 1057 - clippy::let_unit_value 1147 + clippy::let_unit_value, 1058 1148 )] 1059 - use tonic::codegen::http::Uri; 1060 1149 use tonic::codegen::*; 1150 + use tonic::codegen::http::Uri; 1061 1151 #[derive(Debug, Clone)] 1062 1152 pub struct LibraryServiceClient<T> { 1063 1153 inner: tonic::client::Grpc<T>, ··· 1101 1191 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody, 1102 1192 >, 1103 1193 >, 1104 - <T as tonic::codegen::Service<http::Request<tonic::body::BoxBody>>>::Error: 1105 - Into<StdError> + std::marker::Send + std::marker::Sync, 1194 + <T as tonic::codegen::Service< 1195 + http::Request<tonic::body::BoxBody>, 1196 + >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync, 1106 1197 { 1107 1198 LibraryServiceClient::new(InterceptedService::new(inner, interceptor)) 1108 1199 } ··· 1140 1231 pub async fn get_albums( 1141 1232 &mut self, 1142 1233 request: impl tonic::IntoRequest<super::GetAlbumsRequest>, 1143 - ) -> std::result::Result<tonic::Response<super::GetAlbumsResponse>, tonic::Status> { 1144 - self.inner.ready().await.map_err(|e| { 1145 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 1146 - })?; 1234 + ) -> std::result::Result< 1235 + tonic::Response<super::GetAlbumsResponse>, 1236 + tonic::Status, 1237 + > { 1238 + self.inner 1239 + .ready() 1240 + .await 1241 + .map_err(|e| { 1242 + tonic::Status::unknown( 1243 + format!("Service was not ready: {}", e.into()), 1244 + ) 1245 + })?; 1147 1246 let codec = tonic::codec::ProstCodec::default(); 1148 - let path = 1149 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.LibraryService/GetAlbums"); 1247 + let path = http::uri::PathAndQuery::from_static( 1248 + "/rockbox.v1alpha1.LibraryService/GetAlbums", 1249 + ); 1150 1250 let mut req = request.into_request(); 1151 - req.extensions_mut().insert(GrpcMethod::new( 1152 - "rockbox.v1alpha1.LibraryService", 1153 - "GetAlbums", 1154 - )); 1251 + req.extensions_mut() 1252 + .insert(GrpcMethod::new("rockbox.v1alpha1.LibraryService", "GetAlbums")); 1155 1253 self.inner.unary(req, path, codec).await 1156 1254 } 1157 1255 pub async fn get_artists( 1158 1256 &mut self, 1159 1257 request: impl tonic::IntoRequest<super::GetArtistsRequest>, 1160 - ) -> std::result::Result<tonic::Response<super::GetArtistsResponse>, tonic::Status> 1161 - { 1162 - self.inner.ready().await.map_err(|e| { 1163 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 1164 - })?; 1258 + ) -> std::result::Result< 1259 + tonic::Response<super::GetArtistsResponse>, 1260 + tonic::Status, 1261 + > { 1262 + self.inner 1263 + .ready() 1264 + .await 1265 + .map_err(|e| { 1266 + tonic::Status::unknown( 1267 + format!("Service was not ready: {}", e.into()), 1268 + ) 1269 + })?; 1165 1270 let codec = tonic::codec::ProstCodec::default(); 1166 - let path = 1167 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.LibraryService/GetArtists"); 1271 + let path = http::uri::PathAndQuery::from_static( 1272 + "/rockbox.v1alpha1.LibraryService/GetArtists", 1273 + ); 1168 1274 let mut req = request.into_request(); 1169 - req.extensions_mut().insert(GrpcMethod::new( 1170 - "rockbox.v1alpha1.LibraryService", 1171 - "GetArtists", 1172 - )); 1275 + req.extensions_mut() 1276 + .insert( 1277 + GrpcMethod::new("rockbox.v1alpha1.LibraryService", "GetArtists"), 1278 + ); 1173 1279 self.inner.unary(req, path, codec).await 1174 1280 } 1175 1281 pub async fn get_tracks( 1176 1282 &mut self, 1177 1283 request: impl tonic::IntoRequest<super::GetTracksRequest>, 1178 - ) -> std::result::Result<tonic::Response<super::GetTracksResponse>, tonic::Status> { 1179 - self.inner.ready().await.map_err(|e| { 1180 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 1181 - })?; 1284 + ) -> std::result::Result< 1285 + tonic::Response<super::GetTracksResponse>, 1286 + tonic::Status, 1287 + > { 1288 + self.inner 1289 + .ready() 1290 + .await 1291 + .map_err(|e| { 1292 + tonic::Status::unknown( 1293 + format!("Service was not ready: {}", e.into()), 1294 + ) 1295 + })?; 1182 1296 let codec = tonic::codec::ProstCodec::default(); 1183 - let path = 1184 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.LibraryService/GetTracks"); 1297 + let path = http::uri::PathAndQuery::from_static( 1298 + "/rockbox.v1alpha1.LibraryService/GetTracks", 1299 + ); 1185 1300 let mut req = request.into_request(); 1186 - req.extensions_mut().insert(GrpcMethod::new( 1187 - "rockbox.v1alpha1.LibraryService", 1188 - "GetTracks", 1189 - )); 1301 + req.extensions_mut() 1302 + .insert(GrpcMethod::new("rockbox.v1alpha1.LibraryService", "GetTracks")); 1190 1303 self.inner.unary(req, path, codec).await 1191 1304 } 1192 1305 pub async fn get_album( 1193 1306 &mut self, 1194 1307 request: impl tonic::IntoRequest<super::GetAlbumRequest>, 1195 - ) -> std::result::Result<tonic::Response<super::GetAlbumResponse>, tonic::Status> { 1196 - self.inner.ready().await.map_err(|e| { 1197 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 1198 - })?; 1308 + ) -> std::result::Result< 1309 + tonic::Response<super::GetAlbumResponse>, 1310 + tonic::Status, 1311 + > { 1312 + self.inner 1313 + .ready() 1314 + .await 1315 + .map_err(|e| { 1316 + tonic::Status::unknown( 1317 + format!("Service was not ready: {}", e.into()), 1318 + ) 1319 + })?; 1199 1320 let codec = tonic::codec::ProstCodec::default(); 1200 - let path = 1201 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.LibraryService/GetAlbum"); 1321 + let path = http::uri::PathAndQuery::from_static( 1322 + "/rockbox.v1alpha1.LibraryService/GetAlbum", 1323 + ); 1202 1324 let mut req = request.into_request(); 1203 - req.extensions_mut().insert(GrpcMethod::new( 1204 - "rockbox.v1alpha1.LibraryService", 1205 - "GetAlbum", 1206 - )); 1325 + req.extensions_mut() 1326 + .insert(GrpcMethod::new("rockbox.v1alpha1.LibraryService", "GetAlbum")); 1207 1327 self.inner.unary(req, path, codec).await 1208 1328 } 1209 1329 pub async fn get_artist( 1210 1330 &mut self, 1211 1331 request: impl tonic::IntoRequest<super::GetArtistRequest>, 1212 - ) -> std::result::Result<tonic::Response<super::GetArtistResponse>, tonic::Status> { 1213 - self.inner.ready().await.map_err(|e| { 1214 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 1215 - })?; 1332 + ) -> std::result::Result< 1333 + tonic::Response<super::GetArtistResponse>, 1334 + tonic::Status, 1335 + > { 1336 + self.inner 1337 + .ready() 1338 + .await 1339 + .map_err(|e| { 1340 + tonic::Status::unknown( 1341 + format!("Service was not ready: {}", e.into()), 1342 + ) 1343 + })?; 1216 1344 let codec = tonic::codec::ProstCodec::default(); 1217 - let path = 1218 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.LibraryService/GetArtist"); 1345 + let path = http::uri::PathAndQuery::from_static( 1346 + "/rockbox.v1alpha1.LibraryService/GetArtist", 1347 + ); 1219 1348 let mut req = request.into_request(); 1220 - req.extensions_mut().insert(GrpcMethod::new( 1221 - "rockbox.v1alpha1.LibraryService", 1222 - "GetArtist", 1223 - )); 1349 + req.extensions_mut() 1350 + .insert(GrpcMethod::new("rockbox.v1alpha1.LibraryService", "GetArtist")); 1224 1351 self.inner.unary(req, path, codec).await 1225 1352 } 1226 1353 pub async fn get_track( 1227 1354 &mut self, 1228 1355 request: impl tonic::IntoRequest<super::GetTrackRequest>, 1229 - ) -> std::result::Result<tonic::Response<super::GetTrackResponse>, tonic::Status> { 1230 - self.inner.ready().await.map_err(|e| { 1231 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 1232 - })?; 1356 + ) -> std::result::Result< 1357 + tonic::Response<super::GetTrackResponse>, 1358 + tonic::Status, 1359 + > { 1360 + self.inner 1361 + .ready() 1362 + .await 1363 + .map_err(|e| { 1364 + tonic::Status::unknown( 1365 + format!("Service was not ready: {}", e.into()), 1366 + ) 1367 + })?; 1233 1368 let codec = tonic::codec::ProstCodec::default(); 1234 - let path = 1235 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.LibraryService/GetTrack"); 1369 + let path = http::uri::PathAndQuery::from_static( 1370 + "/rockbox.v1alpha1.LibraryService/GetTrack", 1371 + ); 1236 1372 let mut req = request.into_request(); 1237 - req.extensions_mut().insert(GrpcMethod::new( 1238 - "rockbox.v1alpha1.LibraryService", 1239 - "GetTrack", 1240 - )); 1373 + req.extensions_mut() 1374 + .insert(GrpcMethod::new("rockbox.v1alpha1.LibraryService", "GetTrack")); 1241 1375 self.inner.unary(req, path, codec).await 1242 1376 } 1243 1377 pub async fn like_track( 1244 1378 &mut self, 1245 1379 request: impl tonic::IntoRequest<super::LikeTrackRequest>, 1246 - ) -> std::result::Result<tonic::Response<super::LikeTrackResponse>, tonic::Status> { 1247 - self.inner.ready().await.map_err(|e| { 1248 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 1249 - })?; 1380 + ) -> std::result::Result< 1381 + tonic::Response<super::LikeTrackResponse>, 1382 + tonic::Status, 1383 + > { 1384 + self.inner 1385 + .ready() 1386 + .await 1387 + .map_err(|e| { 1388 + tonic::Status::unknown( 1389 + format!("Service was not ready: {}", e.into()), 1390 + ) 1391 + })?; 1250 1392 let codec = tonic::codec::ProstCodec::default(); 1251 - let path = 1252 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.LibraryService/LikeTrack"); 1393 + let path = http::uri::PathAndQuery::from_static( 1394 + "/rockbox.v1alpha1.LibraryService/LikeTrack", 1395 + ); 1253 1396 let mut req = request.into_request(); 1254 - req.extensions_mut().insert(GrpcMethod::new( 1255 - "rockbox.v1alpha1.LibraryService", 1256 - "LikeTrack", 1257 - )); 1397 + req.extensions_mut() 1398 + .insert(GrpcMethod::new("rockbox.v1alpha1.LibraryService", "LikeTrack")); 1258 1399 self.inner.unary(req, path, codec).await 1259 1400 } 1260 1401 pub async fn unlike_track( 1261 1402 &mut self, 1262 1403 request: impl tonic::IntoRequest<super::UnlikeTrackRequest>, 1263 - ) -> std::result::Result<tonic::Response<super::UnlikeTrackResponse>, tonic::Status> 1264 - { 1265 - self.inner.ready().await.map_err(|e| { 1266 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 1267 - })?; 1404 + ) -> std::result::Result< 1405 + tonic::Response<super::UnlikeTrackResponse>, 1406 + tonic::Status, 1407 + > { 1408 + self.inner 1409 + .ready() 1410 + .await 1411 + .map_err(|e| { 1412 + tonic::Status::unknown( 1413 + format!("Service was not ready: {}", e.into()), 1414 + ) 1415 + })?; 1268 1416 let codec = tonic::codec::ProstCodec::default(); 1269 1417 let path = http::uri::PathAndQuery::from_static( 1270 1418 "/rockbox.v1alpha1.LibraryService/UnlikeTrack", 1271 1419 ); 1272 1420 let mut req = request.into_request(); 1273 - req.extensions_mut().insert(GrpcMethod::new( 1274 - "rockbox.v1alpha1.LibraryService", 1275 - "UnlikeTrack", 1276 - )); 1421 + req.extensions_mut() 1422 + .insert( 1423 + GrpcMethod::new("rockbox.v1alpha1.LibraryService", "UnlikeTrack"), 1424 + ); 1277 1425 self.inner.unary(req, path, codec).await 1278 1426 } 1279 1427 pub async fn like_album( 1280 1428 &mut self, 1281 1429 request: impl tonic::IntoRequest<super::LikeAlbumRequest>, 1282 - ) -> std::result::Result<tonic::Response<super::LikeAlbumResponse>, tonic::Status> { 1283 - self.inner.ready().await.map_err(|e| { 1284 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 1285 - })?; 1430 + ) -> std::result::Result< 1431 + tonic::Response<super::LikeAlbumResponse>, 1432 + tonic::Status, 1433 + > { 1434 + self.inner 1435 + .ready() 1436 + .await 1437 + .map_err(|e| { 1438 + tonic::Status::unknown( 1439 + format!("Service was not ready: {}", e.into()), 1440 + ) 1441 + })?; 1286 1442 let codec = tonic::codec::ProstCodec::default(); 1287 - let path = 1288 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.LibraryService/LikeAlbum"); 1443 + let path = http::uri::PathAndQuery::from_static( 1444 + "/rockbox.v1alpha1.LibraryService/LikeAlbum", 1445 + ); 1289 1446 let mut req = request.into_request(); 1290 - req.extensions_mut().insert(GrpcMethod::new( 1291 - "rockbox.v1alpha1.LibraryService", 1292 - "LikeAlbum", 1293 - )); 1447 + req.extensions_mut() 1448 + .insert(GrpcMethod::new("rockbox.v1alpha1.LibraryService", "LikeAlbum")); 1294 1449 self.inner.unary(req, path, codec).await 1295 1450 } 1296 1451 pub async fn unlike_album( 1297 1452 &mut self, 1298 1453 request: impl tonic::IntoRequest<super::UnlikeAlbumRequest>, 1299 - ) -> std::result::Result<tonic::Response<super::UnlikeAlbumResponse>, tonic::Status> 1300 - { 1301 - self.inner.ready().await.map_err(|e| { 1302 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 1303 - })?; 1454 + ) -> std::result::Result< 1455 + tonic::Response<super::UnlikeAlbumResponse>, 1456 + tonic::Status, 1457 + > { 1458 + self.inner 1459 + .ready() 1460 + .await 1461 + .map_err(|e| { 1462 + tonic::Status::unknown( 1463 + format!("Service was not ready: {}", e.into()), 1464 + ) 1465 + })?; 1304 1466 let codec = tonic::codec::ProstCodec::default(); 1305 1467 let path = http::uri::PathAndQuery::from_static( 1306 1468 "/rockbox.v1alpha1.LibraryService/UnlikeAlbum", 1307 1469 ); 1308 1470 let mut req = request.into_request(); 1309 - req.extensions_mut().insert(GrpcMethod::new( 1310 - "rockbox.v1alpha1.LibraryService", 1311 - "UnlikeAlbum", 1312 - )); 1471 + req.extensions_mut() 1472 + .insert( 1473 + GrpcMethod::new("rockbox.v1alpha1.LibraryService", "UnlikeAlbum"), 1474 + ); 1313 1475 self.inner.unary(req, path, codec).await 1314 1476 } 1315 1477 pub async fn get_liked_tracks( 1316 1478 &mut self, 1317 1479 request: impl tonic::IntoRequest<super::GetLikedTracksRequest>, 1318 - ) -> std::result::Result<tonic::Response<super::GetLikedTracksResponse>, tonic::Status> 1319 - { 1320 - self.inner.ready().await.map_err(|e| { 1321 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 1322 - })?; 1480 + ) -> std::result::Result< 1481 + tonic::Response<super::GetLikedTracksResponse>, 1482 + tonic::Status, 1483 + > { 1484 + self.inner 1485 + .ready() 1486 + .await 1487 + .map_err(|e| { 1488 + tonic::Status::unknown( 1489 + format!("Service was not ready: {}", e.into()), 1490 + ) 1491 + })?; 1323 1492 let codec = tonic::codec::ProstCodec::default(); 1324 1493 let path = http::uri::PathAndQuery::from_static( 1325 1494 "/rockbox.v1alpha1.LibraryService/GetLikedTracks", 1326 1495 ); 1327 1496 let mut req = request.into_request(); 1328 - req.extensions_mut().insert(GrpcMethod::new( 1329 - "rockbox.v1alpha1.LibraryService", 1330 - "GetLikedTracks", 1331 - )); 1497 + req.extensions_mut() 1498 + .insert( 1499 + GrpcMethod::new("rockbox.v1alpha1.LibraryService", "GetLikedTracks"), 1500 + ); 1332 1501 self.inner.unary(req, path, codec).await 1333 1502 } 1334 1503 pub async fn get_liked_albums( 1335 1504 &mut self, 1336 1505 request: impl tonic::IntoRequest<super::GetLikedAlbumsRequest>, 1337 - ) -> std::result::Result<tonic::Response<super::GetLikedAlbumsResponse>, tonic::Status> 1338 - { 1339 - self.inner.ready().await.map_err(|e| { 1340 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 1341 - })?; 1506 + ) -> std::result::Result< 1507 + tonic::Response<super::GetLikedAlbumsResponse>, 1508 + tonic::Status, 1509 + > { 1510 + self.inner 1511 + .ready() 1512 + .await 1513 + .map_err(|e| { 1514 + tonic::Status::unknown( 1515 + format!("Service was not ready: {}", e.into()), 1516 + ) 1517 + })?; 1342 1518 let codec = tonic::codec::ProstCodec::default(); 1343 1519 let path = http::uri::PathAndQuery::from_static( 1344 1520 "/rockbox.v1alpha1.LibraryService/GetLikedAlbums", 1345 1521 ); 1346 1522 let mut req = request.into_request(); 1347 - req.extensions_mut().insert(GrpcMethod::new( 1348 - "rockbox.v1alpha1.LibraryService", 1349 - "GetLikedAlbums", 1350 - )); 1523 + req.extensions_mut() 1524 + .insert( 1525 + GrpcMethod::new("rockbox.v1alpha1.LibraryService", "GetLikedAlbums"), 1526 + ); 1351 1527 self.inner.unary(req, path, codec).await 1352 1528 } 1353 1529 pub async fn scan_library( 1354 1530 &mut self, 1355 1531 request: impl tonic::IntoRequest<super::ScanLibraryRequest>, 1356 - ) -> std::result::Result<tonic::Response<super::ScanLibraryResponse>, tonic::Status> 1357 - { 1358 - self.inner.ready().await.map_err(|e| { 1359 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 1360 - })?; 1532 + ) -> std::result::Result< 1533 + tonic::Response<super::ScanLibraryResponse>, 1534 + tonic::Status, 1535 + > { 1536 + self.inner 1537 + .ready() 1538 + .await 1539 + .map_err(|e| { 1540 + tonic::Status::unknown( 1541 + format!("Service was not ready: {}", e.into()), 1542 + ) 1543 + })?; 1361 1544 let codec = tonic::codec::ProstCodec::default(); 1362 1545 let path = http::uri::PathAndQuery::from_static( 1363 1546 "/rockbox.v1alpha1.LibraryService/ScanLibrary", 1364 1547 ); 1365 1548 let mut req = request.into_request(); 1366 - req.extensions_mut().insert(GrpcMethod::new( 1367 - "rockbox.v1alpha1.LibraryService", 1368 - "ScanLibrary", 1369 - )); 1549 + req.extensions_mut() 1550 + .insert( 1551 + GrpcMethod::new("rockbox.v1alpha1.LibraryService", "ScanLibrary"), 1552 + ); 1370 1553 self.inner.unary(req, path, codec).await 1371 1554 } 1372 1555 pub async fn search( 1373 1556 &mut self, 1374 1557 request: impl tonic::IntoRequest<super::SearchRequest>, 1375 1558 ) -> std::result::Result<tonic::Response<super::SearchResponse>, tonic::Status> { 1376 - self.inner.ready().await.map_err(|e| { 1377 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 1378 - })?; 1559 + self.inner 1560 + .ready() 1561 + .await 1562 + .map_err(|e| { 1563 + tonic::Status::unknown( 1564 + format!("Service was not ready: {}", e.into()), 1565 + ) 1566 + })?; 1379 1567 let codec = tonic::codec::ProstCodec::default(); 1380 - let path = 1381 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.LibraryService/Search"); 1568 + let path = http::uri::PathAndQuery::from_static( 1569 + "/rockbox.v1alpha1.LibraryService/Search", 1570 + ); 1382 1571 let mut req = request.into_request(); 1383 1572 req.extensions_mut() 1384 1573 .insert(GrpcMethod::new("rockbox.v1alpha1.LibraryService", "Search")); ··· 1393 1582 dead_code, 1394 1583 missing_docs, 1395 1584 clippy::wildcard_imports, 1396 - clippy::let_unit_value 1585 + clippy::let_unit_value, 1397 1586 )] 1398 1587 use tonic::codegen::*; 1399 1588 /// Generated trait containing gRPC methods that should be implemented for use with LibraryServiceServer. ··· 1402 1591 async fn get_albums( 1403 1592 &self, 1404 1593 request: tonic::Request<super::GetAlbumsRequest>, 1405 - ) -> std::result::Result<tonic::Response<super::GetAlbumsResponse>, tonic::Status>; 1594 + ) -> std::result::Result< 1595 + tonic::Response<super::GetAlbumsResponse>, 1596 + tonic::Status, 1597 + >; 1406 1598 async fn get_artists( 1407 1599 &self, 1408 1600 request: tonic::Request<super::GetArtistsRequest>, 1409 - ) -> std::result::Result<tonic::Response<super::GetArtistsResponse>, tonic::Status>; 1601 + ) -> std::result::Result< 1602 + tonic::Response<super::GetArtistsResponse>, 1603 + tonic::Status, 1604 + >; 1410 1605 async fn get_tracks( 1411 1606 &self, 1412 1607 request: tonic::Request<super::GetTracksRequest>, 1413 - ) -> std::result::Result<tonic::Response<super::GetTracksResponse>, tonic::Status>; 1608 + ) -> std::result::Result< 1609 + tonic::Response<super::GetTracksResponse>, 1610 + tonic::Status, 1611 + >; 1414 1612 async fn get_album( 1415 1613 &self, 1416 1614 request: tonic::Request<super::GetAlbumRequest>, 1417 - ) -> std::result::Result<tonic::Response<super::GetAlbumResponse>, tonic::Status>; 1615 + ) -> std::result::Result< 1616 + tonic::Response<super::GetAlbumResponse>, 1617 + tonic::Status, 1618 + >; 1418 1619 async fn get_artist( 1419 1620 &self, 1420 1621 request: tonic::Request<super::GetArtistRequest>, 1421 - ) -> std::result::Result<tonic::Response<super::GetArtistResponse>, tonic::Status>; 1622 + ) -> std::result::Result< 1623 + tonic::Response<super::GetArtistResponse>, 1624 + tonic::Status, 1625 + >; 1422 1626 async fn get_track( 1423 1627 &self, 1424 1628 request: tonic::Request<super::GetTrackRequest>, 1425 - ) -> std::result::Result<tonic::Response<super::GetTrackResponse>, tonic::Status>; 1629 + ) -> std::result::Result< 1630 + tonic::Response<super::GetTrackResponse>, 1631 + tonic::Status, 1632 + >; 1426 1633 async fn like_track( 1427 1634 &self, 1428 1635 request: tonic::Request<super::LikeTrackRequest>, 1429 - ) -> std::result::Result<tonic::Response<super::LikeTrackResponse>, tonic::Status>; 1636 + ) -> std::result::Result< 1637 + tonic::Response<super::LikeTrackResponse>, 1638 + tonic::Status, 1639 + >; 1430 1640 async fn unlike_track( 1431 1641 &self, 1432 1642 request: tonic::Request<super::UnlikeTrackRequest>, 1433 - ) -> std::result::Result<tonic::Response<super::UnlikeTrackResponse>, tonic::Status>; 1643 + ) -> std::result::Result< 1644 + tonic::Response<super::UnlikeTrackResponse>, 1645 + tonic::Status, 1646 + >; 1434 1647 async fn like_album( 1435 1648 &self, 1436 1649 request: tonic::Request<super::LikeAlbumRequest>, 1437 - ) -> std::result::Result<tonic::Response<super::LikeAlbumResponse>, tonic::Status>; 1650 + ) -> std::result::Result< 1651 + tonic::Response<super::LikeAlbumResponse>, 1652 + tonic::Status, 1653 + >; 1438 1654 async fn unlike_album( 1439 1655 &self, 1440 1656 request: tonic::Request<super::UnlikeAlbumRequest>, 1441 - ) -> std::result::Result<tonic::Response<super::UnlikeAlbumResponse>, tonic::Status>; 1657 + ) -> std::result::Result< 1658 + tonic::Response<super::UnlikeAlbumResponse>, 1659 + tonic::Status, 1660 + >; 1442 1661 async fn get_liked_tracks( 1443 1662 &self, 1444 1663 request: tonic::Request<super::GetLikedTracksRequest>, 1445 - ) -> std::result::Result<tonic::Response<super::GetLikedTracksResponse>, tonic::Status>; 1664 + ) -> std::result::Result< 1665 + tonic::Response<super::GetLikedTracksResponse>, 1666 + tonic::Status, 1667 + >; 1446 1668 async fn get_liked_albums( 1447 1669 &self, 1448 1670 request: tonic::Request<super::GetLikedAlbumsRequest>, 1449 - ) -> std::result::Result<tonic::Response<super::GetLikedAlbumsResponse>, tonic::Status>; 1671 + ) -> std::result::Result< 1672 + tonic::Response<super::GetLikedAlbumsResponse>, 1673 + tonic::Status, 1674 + >; 1450 1675 async fn scan_library( 1451 1676 &self, 1452 1677 request: tonic::Request<super::ScanLibraryRequest>, 1453 - ) -> std::result::Result<tonic::Response<super::ScanLibraryResponse>, tonic::Status>; 1678 + ) -> std::result::Result< 1679 + tonic::Response<super::ScanLibraryResponse>, 1680 + tonic::Status, 1681 + >; 1454 1682 async fn search( 1455 1683 &self, 1456 1684 request: tonic::Request<super::SearchRequest>, ··· 1477 1705 max_encoding_message_size: None, 1478 1706 } 1479 1707 } 1480 - pub fn with_interceptor<F>(inner: T, interceptor: F) -> InterceptedService<Self, F> 1708 + pub fn with_interceptor<F>( 1709 + inner: T, 1710 + interceptor: F, 1711 + ) -> InterceptedService<Self, F> 1481 1712 where 1482 1713 F: tonic::service::Interceptor, 1483 1714 { ··· 1532 1763 "/rockbox.v1alpha1.LibraryService/GetAlbums" => { 1533 1764 #[allow(non_camel_case_types)] 1534 1765 struct GetAlbumsSvc<T: LibraryService>(pub Arc<T>); 1535 - impl<T: LibraryService> tonic::server::UnaryService<super::GetAlbumsRequest> for GetAlbumsSvc<T> { 1766 + impl< 1767 + T: LibraryService, 1768 + > tonic::server::UnaryService<super::GetAlbumsRequest> 1769 + for GetAlbumsSvc<T> { 1536 1770 type Response = super::GetAlbumsResponse; 1537 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1771 + type Future = BoxFuture< 1772 + tonic::Response<Self::Response>, 1773 + tonic::Status, 1774 + >; 1538 1775 fn call( 1539 1776 &mut self, 1540 1777 request: tonic::Request<super::GetAlbumsRequest>, ··· 1571 1808 "/rockbox.v1alpha1.LibraryService/GetArtists" => { 1572 1809 #[allow(non_camel_case_types)] 1573 1810 struct GetArtistsSvc<T: LibraryService>(pub Arc<T>); 1574 - impl<T: LibraryService> tonic::server::UnaryService<super::GetArtistsRequest> for GetArtistsSvc<T> { 1811 + impl< 1812 + T: LibraryService, 1813 + > tonic::server::UnaryService<super::GetArtistsRequest> 1814 + for GetArtistsSvc<T> { 1575 1815 type Response = super::GetArtistsResponse; 1576 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1816 + type Future = BoxFuture< 1817 + tonic::Response<Self::Response>, 1818 + tonic::Status, 1819 + >; 1577 1820 fn call( 1578 1821 &mut self, 1579 1822 request: tonic::Request<super::GetArtistsRequest>, ··· 1610 1853 "/rockbox.v1alpha1.LibraryService/GetTracks" => { 1611 1854 #[allow(non_camel_case_types)] 1612 1855 struct GetTracksSvc<T: LibraryService>(pub Arc<T>); 1613 - impl<T: LibraryService> tonic::server::UnaryService<super::GetTracksRequest> for GetTracksSvc<T> { 1856 + impl< 1857 + T: LibraryService, 1858 + > tonic::server::UnaryService<super::GetTracksRequest> 1859 + for GetTracksSvc<T> { 1614 1860 type Response = super::GetTracksResponse; 1615 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1861 + type Future = BoxFuture< 1862 + tonic::Response<Self::Response>, 1863 + tonic::Status, 1864 + >; 1616 1865 fn call( 1617 1866 &mut self, 1618 1867 request: tonic::Request<super::GetTracksRequest>, ··· 1649 1898 "/rockbox.v1alpha1.LibraryService/GetAlbum" => { 1650 1899 #[allow(non_camel_case_types)] 1651 1900 struct GetAlbumSvc<T: LibraryService>(pub Arc<T>); 1652 - impl<T: LibraryService> tonic::server::UnaryService<super::GetAlbumRequest> for GetAlbumSvc<T> { 1901 + impl< 1902 + T: LibraryService, 1903 + > tonic::server::UnaryService<super::GetAlbumRequest> 1904 + for GetAlbumSvc<T> { 1653 1905 type Response = super::GetAlbumResponse; 1654 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1906 + type Future = BoxFuture< 1907 + tonic::Response<Self::Response>, 1908 + tonic::Status, 1909 + >; 1655 1910 fn call( 1656 1911 &mut self, 1657 1912 request: tonic::Request<super::GetAlbumRequest>, ··· 1688 1943 "/rockbox.v1alpha1.LibraryService/GetArtist" => { 1689 1944 #[allow(non_camel_case_types)] 1690 1945 struct GetArtistSvc<T: LibraryService>(pub Arc<T>); 1691 - impl<T: LibraryService> tonic::server::UnaryService<super::GetArtistRequest> for GetArtistSvc<T> { 1946 + impl< 1947 + T: LibraryService, 1948 + > tonic::server::UnaryService<super::GetArtistRequest> 1949 + for GetArtistSvc<T> { 1692 1950 type Response = super::GetArtistResponse; 1693 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1951 + type Future = BoxFuture< 1952 + tonic::Response<Self::Response>, 1953 + tonic::Status, 1954 + >; 1694 1955 fn call( 1695 1956 &mut self, 1696 1957 request: tonic::Request<super::GetArtistRequest>, ··· 1727 1988 "/rockbox.v1alpha1.LibraryService/GetTrack" => { 1728 1989 #[allow(non_camel_case_types)] 1729 1990 struct GetTrackSvc<T: LibraryService>(pub Arc<T>); 1730 - impl<T: LibraryService> tonic::server::UnaryService<super::GetTrackRequest> for GetTrackSvc<T> { 1991 + impl< 1992 + T: LibraryService, 1993 + > tonic::server::UnaryService<super::GetTrackRequest> 1994 + for GetTrackSvc<T> { 1731 1995 type Response = super::GetTrackResponse; 1732 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 1996 + type Future = BoxFuture< 1997 + tonic::Response<Self::Response>, 1998 + tonic::Status, 1999 + >; 1733 2000 fn call( 1734 2001 &mut self, 1735 2002 request: tonic::Request<super::GetTrackRequest>, ··· 1766 2033 "/rockbox.v1alpha1.LibraryService/LikeTrack" => { 1767 2034 #[allow(non_camel_case_types)] 1768 2035 struct LikeTrackSvc<T: LibraryService>(pub Arc<T>); 1769 - impl<T: LibraryService> tonic::server::UnaryService<super::LikeTrackRequest> for LikeTrackSvc<T> { 2036 + impl< 2037 + T: LibraryService, 2038 + > tonic::server::UnaryService<super::LikeTrackRequest> 2039 + for LikeTrackSvc<T> { 1770 2040 type Response = super::LikeTrackResponse; 1771 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 2041 + type Future = BoxFuture< 2042 + tonic::Response<Self::Response>, 2043 + tonic::Status, 2044 + >; 1772 2045 fn call( 1773 2046 &mut self, 1774 2047 request: tonic::Request<super::LikeTrackRequest>, ··· 1805 2078 "/rockbox.v1alpha1.LibraryService/UnlikeTrack" => { 1806 2079 #[allow(non_camel_case_types)] 1807 2080 struct UnlikeTrackSvc<T: LibraryService>(pub Arc<T>); 1808 - impl<T: LibraryService> tonic::server::UnaryService<super::UnlikeTrackRequest> 1809 - for UnlikeTrackSvc<T> 1810 - { 2081 + impl< 2082 + T: LibraryService, 2083 + > tonic::server::UnaryService<super::UnlikeTrackRequest> 2084 + for UnlikeTrackSvc<T> { 1811 2085 type Response = super::UnlikeTrackResponse; 1812 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 2086 + type Future = BoxFuture< 2087 + tonic::Response<Self::Response>, 2088 + tonic::Status, 2089 + >; 1813 2090 fn call( 1814 2091 &mut self, 1815 2092 request: tonic::Request<super::UnlikeTrackRequest>, ··· 1846 2123 "/rockbox.v1alpha1.LibraryService/LikeAlbum" => { 1847 2124 #[allow(non_camel_case_types)] 1848 2125 struct LikeAlbumSvc<T: LibraryService>(pub Arc<T>); 1849 - impl<T: LibraryService> tonic::server::UnaryService<super::LikeAlbumRequest> for LikeAlbumSvc<T> { 2126 + impl< 2127 + T: LibraryService, 2128 + > tonic::server::UnaryService<super::LikeAlbumRequest> 2129 + for LikeAlbumSvc<T> { 1850 2130 type Response = super::LikeAlbumResponse; 1851 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 2131 + type Future = BoxFuture< 2132 + tonic::Response<Self::Response>, 2133 + tonic::Status, 2134 + >; 1852 2135 fn call( 1853 2136 &mut self, 1854 2137 request: tonic::Request<super::LikeAlbumRequest>, ··· 1885 2168 "/rockbox.v1alpha1.LibraryService/UnlikeAlbum" => { 1886 2169 #[allow(non_camel_case_types)] 1887 2170 struct UnlikeAlbumSvc<T: LibraryService>(pub Arc<T>); 1888 - impl<T: LibraryService> tonic::server::UnaryService<super::UnlikeAlbumRequest> 1889 - for UnlikeAlbumSvc<T> 1890 - { 2171 + impl< 2172 + T: LibraryService, 2173 + > tonic::server::UnaryService<super::UnlikeAlbumRequest> 2174 + for UnlikeAlbumSvc<T> { 1891 2175 type Response = super::UnlikeAlbumResponse; 1892 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 2176 + type Future = BoxFuture< 2177 + tonic::Response<Self::Response>, 2178 + tonic::Status, 2179 + >; 1893 2180 fn call( 1894 2181 &mut self, 1895 2182 request: tonic::Request<super::UnlikeAlbumRequest>, ··· 1926 2213 "/rockbox.v1alpha1.LibraryService/GetLikedTracks" => { 1927 2214 #[allow(non_camel_case_types)] 1928 2215 struct GetLikedTracksSvc<T: LibraryService>(pub Arc<T>); 1929 - impl<T: LibraryService> 1930 - tonic::server::UnaryService<super::GetLikedTracksRequest> 1931 - for GetLikedTracksSvc<T> 1932 - { 2216 + impl< 2217 + T: LibraryService, 2218 + > tonic::server::UnaryService<super::GetLikedTracksRequest> 2219 + for GetLikedTracksSvc<T> { 1933 2220 type Response = super::GetLikedTracksResponse; 1934 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 2221 + type Future = BoxFuture< 2222 + tonic::Response<Self::Response>, 2223 + tonic::Status, 2224 + >; 1935 2225 fn call( 1936 2226 &mut self, 1937 2227 request: tonic::Request<super::GetLikedTracksRequest>, 1938 2228 ) -> Self::Future { 1939 2229 let inner = Arc::clone(&self.0); 1940 2230 let fut = async move { 1941 - <T as LibraryService>::get_liked_tracks(&inner, request).await 2231 + <T as LibraryService>::get_liked_tracks(&inner, request) 2232 + .await 1942 2233 }; 1943 2234 Box::pin(fut) 1944 2235 } ··· 1968 2259 "/rockbox.v1alpha1.LibraryService/GetLikedAlbums" => { 1969 2260 #[allow(non_camel_case_types)] 1970 2261 struct GetLikedAlbumsSvc<T: LibraryService>(pub Arc<T>); 1971 - impl<T: LibraryService> 1972 - tonic::server::UnaryService<super::GetLikedAlbumsRequest> 1973 - for GetLikedAlbumsSvc<T> 1974 - { 2262 + impl< 2263 + T: LibraryService, 2264 + > tonic::server::UnaryService<super::GetLikedAlbumsRequest> 2265 + for GetLikedAlbumsSvc<T> { 1975 2266 type Response = super::GetLikedAlbumsResponse; 1976 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 2267 + type Future = BoxFuture< 2268 + tonic::Response<Self::Response>, 2269 + tonic::Status, 2270 + >; 1977 2271 fn call( 1978 2272 &mut self, 1979 2273 request: tonic::Request<super::GetLikedAlbumsRequest>, 1980 2274 ) -> Self::Future { 1981 2275 let inner = Arc::clone(&self.0); 1982 2276 let fut = async move { 1983 - <T as LibraryService>::get_liked_albums(&inner, request).await 2277 + <T as LibraryService>::get_liked_albums(&inner, request) 2278 + .await 1984 2279 }; 1985 2280 Box::pin(fut) 1986 2281 } ··· 2010 2305 "/rockbox.v1alpha1.LibraryService/ScanLibrary" => { 2011 2306 #[allow(non_camel_case_types)] 2012 2307 struct ScanLibrarySvc<T: LibraryService>(pub Arc<T>); 2013 - impl<T: LibraryService> tonic::server::UnaryService<super::ScanLibraryRequest> 2014 - for ScanLibrarySvc<T> 2015 - { 2308 + impl< 2309 + T: LibraryService, 2310 + > tonic::server::UnaryService<super::ScanLibraryRequest> 2311 + for ScanLibrarySvc<T> { 2016 2312 type Response = super::ScanLibraryResponse; 2017 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 2313 + type Future = BoxFuture< 2314 + tonic::Response<Self::Response>, 2315 + tonic::Status, 2316 + >; 2018 2317 fn call( 2019 2318 &mut self, 2020 2319 request: tonic::Request<super::ScanLibraryRequest>, ··· 2051 2350 "/rockbox.v1alpha1.LibraryService/Search" => { 2052 2351 #[allow(non_camel_case_types)] 2053 2352 struct SearchSvc<T: LibraryService>(pub Arc<T>); 2054 - impl<T: LibraryService> tonic::server::UnaryService<super::SearchRequest> for SearchSvc<T> { 2353 + impl< 2354 + T: LibraryService, 2355 + > tonic::server::UnaryService<super::SearchRequest> 2356 + for SearchSvc<T> { 2055 2357 type Response = super::SearchResponse; 2056 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 2358 + type Future = BoxFuture< 2359 + tonic::Response<Self::Response>, 2360 + tonic::Status, 2361 + >; 2057 2362 fn call( 2058 2363 &mut self, 2059 2364 request: tonic::Request<super::SearchRequest>, 2060 2365 ) -> Self::Future { 2061 2366 let inner = Arc::clone(&self.0); 2062 - let fut = 2063 - async move { <T as LibraryService>::search(&inner, request).await }; 2367 + let fut = async move { 2368 + <T as LibraryService>::search(&inner, request).await 2369 + }; 2064 2370 Box::pin(fut) 2065 2371 } 2066 2372 } ··· 2086 2392 }; 2087 2393 Box::pin(fut) 2088 2394 } 2089 - _ => Box::pin(async move { 2090 - let mut response = http::Response::new(empty_body()); 2091 - let headers = response.headers_mut(); 2092 - headers.insert( 2093 - tonic::Status::GRPC_STATUS, 2094 - (tonic::Code::Unimplemented as i32).into(), 2095 - ); 2096 - headers.insert( 2097 - http::header::CONTENT_TYPE, 2098 - tonic::metadata::GRPC_CONTENT_TYPE, 2099 - ); 2100 - Ok(response) 2101 - }), 2395 + _ => { 2396 + Box::pin(async move { 2397 + let mut response = http::Response::new(empty_body()); 2398 + let headers = response.headers_mut(); 2399 + headers 2400 + .insert( 2401 + tonic::Status::GRPC_STATUS, 2402 + (tonic::Code::Unimplemented as i32).into(), 2403 + ); 2404 + headers 2405 + .insert( 2406 + http::header::CONTENT_TYPE, 2407 + tonic::metadata::GRPC_CONTENT_TYPE, 2408 + ); 2409 + Ok(response) 2410 + }) 2411 + } 2102 2412 } 2103 2413 } 2104 2414 } ··· 2127 2437 dead_code, 2128 2438 missing_docs, 2129 2439 clippy::wildcard_imports, 2130 - clippy::let_unit_value 2440 + clippy::let_unit_value, 2131 2441 )] 2442 + use tonic::codegen::*; 2132 2443 use tonic::codegen::http::Uri; 2133 - use tonic::codegen::*; 2134 2444 #[derive(Debug, Clone)] 2135 2445 pub struct MetadataServiceClient<T> { 2136 2446 inner: tonic::client::Grpc<T>, ··· 2174 2484 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody, 2175 2485 >, 2176 2486 >, 2177 - <T as tonic::codegen::Service<http::Request<tonic::body::BoxBody>>>::Error: 2178 - Into<StdError> + std::marker::Send + std::marker::Sync, 2487 + <T as tonic::codegen::Service< 2488 + http::Request<tonic::body::BoxBody>, 2489 + >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync, 2179 2490 { 2180 2491 MetadataServiceClient::new(InterceptedService::new(inner, interceptor)) 2181 2492 } ··· 2219 2530 dead_code, 2220 2531 missing_docs, 2221 2532 clippy::wildcard_imports, 2222 - clippy::let_unit_value 2533 + clippy::let_unit_value, 2223 2534 )] 2224 2535 use tonic::codegen::*; 2225 2536 /// Generated trait containing gRPC methods that should be implemented for use with MetadataServiceServer. ··· 2246 2557 max_encoding_message_size: None, 2247 2558 } 2248 2559 } 2249 - pub fn with_interceptor<F>(inner: T, interceptor: F) -> InterceptedService<Self, F> 2560 + pub fn with_interceptor<F>( 2561 + inner: T, 2562 + interceptor: F, 2563 + ) -> InterceptedService<Self, F> 2250 2564 where 2251 2565 F: tonic::service::Interceptor, 2252 2566 { ··· 2298 2612 } 2299 2613 fn call(&mut self, req: http::Request<B>) -> Self::Future { 2300 2614 match req.uri().path() { 2301 - _ => Box::pin(async move { 2302 - let mut response = http::Response::new(empty_body()); 2303 - let headers = response.headers_mut(); 2304 - headers.insert( 2305 - tonic::Status::GRPC_STATUS, 2306 - (tonic::Code::Unimplemented as i32).into(), 2307 - ); 2308 - headers.insert( 2309 - http::header::CONTENT_TYPE, 2310 - tonic::metadata::GRPC_CONTENT_TYPE, 2311 - ); 2312 - Ok(response) 2313 - }), 2615 + _ => { 2616 + Box::pin(async move { 2617 + let mut response = http::Response::new(empty_body()); 2618 + let headers = response.headers_mut(); 2619 + headers 2620 + .insert( 2621 + tonic::Status::GRPC_STATUS, 2622 + (tonic::Code::Unimplemented as i32).into(), 2623 + ); 2624 + headers 2625 + .insert( 2626 + http::header::CONTENT_TYPE, 2627 + tonic::metadata::GRPC_CONTENT_TYPE, 2628 + ); 2629 + Ok(response) 2630 + }) 2631 + } 2314 2632 } 2315 2633 } 2316 2634 } ··· 2594 2912 dead_code, 2595 2913 missing_docs, 2596 2914 clippy::wildcard_imports, 2597 - clippy::let_unit_value 2915 + clippy::let_unit_value, 2598 2916 )] 2599 - use tonic::codegen::http::Uri; 2600 2917 use tonic::codegen::*; 2918 + use tonic::codegen::http::Uri; 2601 2919 #[derive(Debug, Clone)] 2602 2920 pub struct PlaybackServiceClient<T> { 2603 2921 inner: tonic::client::Grpc<T>, ··· 2641 2959 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody, 2642 2960 >, 2643 2961 >, 2644 - <T as tonic::codegen::Service<http::Request<tonic::body::BoxBody>>>::Error: 2645 - Into<StdError> + std::marker::Send + std::marker::Sync, 2962 + <T as tonic::codegen::Service< 2963 + http::Request<tonic::body::BoxBody>, 2964 + >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync, 2646 2965 { 2647 2966 PlaybackServiceClient::new(InterceptedService::new(inner, interceptor)) 2648 2967 } ··· 2681 3000 &mut self, 2682 3001 request: impl tonic::IntoRequest<super::PlayRequest>, 2683 3002 ) -> std::result::Result<tonic::Response<super::PlayResponse>, tonic::Status> { 2684 - self.inner.ready().await.map_err(|e| { 2685 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2686 - })?; 3003 + self.inner 3004 + .ready() 3005 + .await 3006 + .map_err(|e| { 3007 + tonic::Status::unknown( 3008 + format!("Service was not ready: {}", e.into()), 3009 + ) 3010 + })?; 2687 3011 let codec = tonic::codec::ProstCodec::default(); 2688 - let path = 2689 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/Play"); 3012 + let path = http::uri::PathAndQuery::from_static( 3013 + "/rockbox.v1alpha1.PlaybackService/Play", 3014 + ); 2690 3015 let mut req = request.into_request(); 2691 3016 req.extensions_mut() 2692 3017 .insert(GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "Play")); ··· 2696 3021 &mut self, 2697 3022 request: impl tonic::IntoRequest<super::PauseRequest>, 2698 3023 ) -> std::result::Result<tonic::Response<super::PauseResponse>, tonic::Status> { 2699 - self.inner.ready().await.map_err(|e| { 2700 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2701 - })?; 3024 + self.inner 3025 + .ready() 3026 + .await 3027 + .map_err(|e| { 3028 + tonic::Status::unknown( 3029 + format!("Service was not ready: {}", e.into()), 3030 + ) 3031 + })?; 2702 3032 let codec = tonic::codec::ProstCodec::default(); 2703 - let path = 2704 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/Pause"); 3033 + let path = http::uri::PathAndQuery::from_static( 3034 + "/rockbox.v1alpha1.PlaybackService/Pause", 3035 + ); 2705 3036 let mut req = request.into_request(); 2706 3037 req.extensions_mut() 2707 3038 .insert(GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "Pause")); ··· 2710 3041 pub async fn play_or_pause( 2711 3042 &mut self, 2712 3043 request: impl tonic::IntoRequest<super::PlayOrPauseRequest>, 2713 - ) -> std::result::Result<tonic::Response<super::PlayOrPauseResponse>, tonic::Status> 2714 - { 2715 - self.inner.ready().await.map_err(|e| { 2716 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2717 - })?; 3044 + ) -> std::result::Result< 3045 + tonic::Response<super::PlayOrPauseResponse>, 3046 + tonic::Status, 3047 + > { 3048 + self.inner 3049 + .ready() 3050 + .await 3051 + .map_err(|e| { 3052 + tonic::Status::unknown( 3053 + format!("Service was not ready: {}", e.into()), 3054 + ) 3055 + })?; 2718 3056 let codec = tonic::codec::ProstCodec::default(); 2719 3057 let path = http::uri::PathAndQuery::from_static( 2720 3058 "/rockbox.v1alpha1.PlaybackService/PlayOrPause", 2721 3059 ); 2722 3060 let mut req = request.into_request(); 2723 - req.extensions_mut().insert(GrpcMethod::new( 2724 - "rockbox.v1alpha1.PlaybackService", 2725 - "PlayOrPause", 2726 - )); 3061 + req.extensions_mut() 3062 + .insert( 3063 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "PlayOrPause"), 3064 + ); 2727 3065 self.inner.unary(req, path, codec).await 2728 3066 } 2729 3067 pub async fn resume( 2730 3068 &mut self, 2731 3069 request: impl tonic::IntoRequest<super::ResumeRequest>, 2732 3070 ) -> std::result::Result<tonic::Response<super::ResumeResponse>, tonic::Status> { 2733 - self.inner.ready().await.map_err(|e| { 2734 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2735 - })?; 3071 + self.inner 3072 + .ready() 3073 + .await 3074 + .map_err(|e| { 3075 + tonic::Status::unknown( 3076 + format!("Service was not ready: {}", e.into()), 3077 + ) 3078 + })?; 2736 3079 let codec = tonic::codec::ProstCodec::default(); 2737 - let path = 2738 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/Resume"); 3080 + let path = http::uri::PathAndQuery::from_static( 3081 + "/rockbox.v1alpha1.PlaybackService/Resume", 3082 + ); 2739 3083 let mut req = request.into_request(); 2740 - req.extensions_mut().insert(GrpcMethod::new( 2741 - "rockbox.v1alpha1.PlaybackService", 2742 - "Resume", 2743 - )); 3084 + req.extensions_mut() 3085 + .insert(GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "Resume")); 2744 3086 self.inner.unary(req, path, codec).await 2745 3087 } 2746 3088 pub async fn next( 2747 3089 &mut self, 2748 3090 request: impl tonic::IntoRequest<super::NextRequest>, 2749 3091 ) -> std::result::Result<tonic::Response<super::NextResponse>, tonic::Status> { 2750 - self.inner.ready().await.map_err(|e| { 2751 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2752 - })?; 3092 + self.inner 3093 + .ready() 3094 + .await 3095 + .map_err(|e| { 3096 + tonic::Status::unknown( 3097 + format!("Service was not ready: {}", e.into()), 3098 + ) 3099 + })?; 2753 3100 let codec = tonic::codec::ProstCodec::default(); 2754 - let path = 2755 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/Next"); 3101 + let path = http::uri::PathAndQuery::from_static( 3102 + "/rockbox.v1alpha1.PlaybackService/Next", 3103 + ); 2756 3104 let mut req = request.into_request(); 2757 3105 req.extensions_mut() 2758 3106 .insert(GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "Next")); ··· 2761 3109 pub async fn previous( 2762 3110 &mut self, 2763 3111 request: impl tonic::IntoRequest<super::PreviousRequest>, 2764 - ) -> std::result::Result<tonic::Response<super::PreviousResponse>, tonic::Status> { 2765 - self.inner.ready().await.map_err(|e| { 2766 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2767 - })?; 3112 + ) -> std::result::Result< 3113 + tonic::Response<super::PreviousResponse>, 3114 + tonic::Status, 3115 + > { 3116 + self.inner 3117 + .ready() 3118 + .await 3119 + .map_err(|e| { 3120 + tonic::Status::unknown( 3121 + format!("Service was not ready: {}", e.into()), 3122 + ) 3123 + })?; 2768 3124 let codec = tonic::codec::ProstCodec::default(); 2769 - let path = 2770 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/Previous"); 3125 + let path = http::uri::PathAndQuery::from_static( 3126 + "/rockbox.v1alpha1.PlaybackService/Previous", 3127 + ); 2771 3128 let mut req = request.into_request(); 2772 - req.extensions_mut().insert(GrpcMethod::new( 2773 - "rockbox.v1alpha1.PlaybackService", 2774 - "Previous", 2775 - )); 3129 + req.extensions_mut() 3130 + .insert(GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "Previous")); 2776 3131 self.inner.unary(req, path, codec).await 2777 3132 } 2778 3133 pub async fn fast_forward_rewind( 2779 3134 &mut self, 2780 3135 request: impl tonic::IntoRequest<super::FastForwardRewindRequest>, 2781 - ) -> std::result::Result<tonic::Response<super::FastForwardRewindResponse>, tonic::Status> 2782 - { 2783 - self.inner.ready().await.map_err(|e| { 2784 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2785 - })?; 3136 + ) -> std::result::Result< 3137 + tonic::Response<super::FastForwardRewindResponse>, 3138 + tonic::Status, 3139 + > { 3140 + self.inner 3141 + .ready() 3142 + .await 3143 + .map_err(|e| { 3144 + tonic::Status::unknown( 3145 + format!("Service was not ready: {}", e.into()), 3146 + ) 3147 + })?; 2786 3148 let codec = tonic::codec::ProstCodec::default(); 2787 3149 let path = http::uri::PathAndQuery::from_static( 2788 3150 "/rockbox.v1alpha1.PlaybackService/FastForwardRewind", 2789 3151 ); 2790 3152 let mut req = request.into_request(); 2791 - req.extensions_mut().insert(GrpcMethod::new( 2792 - "rockbox.v1alpha1.PlaybackService", 2793 - "FastForwardRewind", 2794 - )); 3153 + req.extensions_mut() 3154 + .insert( 3155 + GrpcMethod::new( 3156 + "rockbox.v1alpha1.PlaybackService", 3157 + "FastForwardRewind", 3158 + ), 3159 + ); 2795 3160 self.inner.unary(req, path, codec).await 2796 3161 } 2797 3162 pub async fn status( 2798 3163 &mut self, 2799 3164 request: impl tonic::IntoRequest<super::StatusRequest>, 2800 3165 ) -> std::result::Result<tonic::Response<super::StatusResponse>, tonic::Status> { 2801 - self.inner.ready().await.map_err(|e| { 2802 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2803 - })?; 3166 + self.inner 3167 + .ready() 3168 + .await 3169 + .map_err(|e| { 3170 + tonic::Status::unknown( 3171 + format!("Service was not ready: {}", e.into()), 3172 + ) 3173 + })?; 2804 3174 let codec = tonic::codec::ProstCodec::default(); 2805 - let path = 2806 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/Status"); 3175 + let path = http::uri::PathAndQuery::from_static( 3176 + "/rockbox.v1alpha1.PlaybackService/Status", 3177 + ); 2807 3178 let mut req = request.into_request(); 2808 - req.extensions_mut().insert(GrpcMethod::new( 2809 - "rockbox.v1alpha1.PlaybackService", 2810 - "Status", 2811 - )); 3179 + req.extensions_mut() 3180 + .insert(GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "Status")); 2812 3181 self.inner.unary(req, path, codec).await 2813 3182 } 2814 3183 pub async fn current_track( 2815 3184 &mut self, 2816 3185 request: impl tonic::IntoRequest<super::CurrentTrackRequest>, 2817 - ) -> std::result::Result<tonic::Response<super::CurrentTrackResponse>, tonic::Status> 2818 - { 2819 - self.inner.ready().await.map_err(|e| { 2820 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2821 - })?; 3186 + ) -> std::result::Result< 3187 + tonic::Response<super::CurrentTrackResponse>, 3188 + tonic::Status, 3189 + > { 3190 + self.inner 3191 + .ready() 3192 + .await 3193 + .map_err(|e| { 3194 + tonic::Status::unknown( 3195 + format!("Service was not ready: {}", e.into()), 3196 + ) 3197 + })?; 2822 3198 let codec = tonic::codec::ProstCodec::default(); 2823 3199 let path = http::uri::PathAndQuery::from_static( 2824 3200 "/rockbox.v1alpha1.PlaybackService/CurrentTrack", 2825 3201 ); 2826 3202 let mut req = request.into_request(); 2827 - req.extensions_mut().insert(GrpcMethod::new( 2828 - "rockbox.v1alpha1.PlaybackService", 2829 - "CurrentTrack", 2830 - )); 3203 + req.extensions_mut() 3204 + .insert( 3205 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "CurrentTrack"), 3206 + ); 2831 3207 self.inner.unary(req, path, codec).await 2832 3208 } 2833 3209 pub async fn next_track( 2834 3210 &mut self, 2835 3211 request: impl tonic::IntoRequest<super::NextTrackRequest>, 2836 - ) -> std::result::Result<tonic::Response<super::NextTrackResponse>, tonic::Status> { 2837 - self.inner.ready().await.map_err(|e| { 2838 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2839 - })?; 3212 + ) -> std::result::Result< 3213 + tonic::Response<super::NextTrackResponse>, 3214 + tonic::Status, 3215 + > { 3216 + self.inner 3217 + .ready() 3218 + .await 3219 + .map_err(|e| { 3220 + tonic::Status::unknown( 3221 + format!("Service was not ready: {}", e.into()), 3222 + ) 3223 + })?; 2840 3224 let codec = tonic::codec::ProstCodec::default(); 2841 - let path = 2842 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/NextTrack"); 3225 + let path = http::uri::PathAndQuery::from_static( 3226 + "/rockbox.v1alpha1.PlaybackService/NextTrack", 3227 + ); 2843 3228 let mut req = request.into_request(); 2844 - req.extensions_mut().insert(GrpcMethod::new( 2845 - "rockbox.v1alpha1.PlaybackService", 2846 - "NextTrack", 2847 - )); 3229 + req.extensions_mut() 3230 + .insert( 3231 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "NextTrack"), 3232 + ); 2848 3233 self.inner.unary(req, path, codec).await 2849 3234 } 2850 3235 pub async fn flush_and_reload_tracks( 2851 3236 &mut self, 2852 3237 request: impl tonic::IntoRequest<super::FlushAndReloadTracksRequest>, 2853 - ) -> std::result::Result<tonic::Response<super::FlushAndReloadTracksResponse>, tonic::Status> 2854 - { 2855 - self.inner.ready().await.map_err(|e| { 2856 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2857 - })?; 3238 + ) -> std::result::Result< 3239 + tonic::Response<super::FlushAndReloadTracksResponse>, 3240 + tonic::Status, 3241 + > { 3242 + self.inner 3243 + .ready() 3244 + .await 3245 + .map_err(|e| { 3246 + tonic::Status::unknown( 3247 + format!("Service was not ready: {}", e.into()), 3248 + ) 3249 + })?; 2858 3250 let codec = tonic::codec::ProstCodec::default(); 2859 3251 let path = http::uri::PathAndQuery::from_static( 2860 3252 "/rockbox.v1alpha1.PlaybackService/FlushAndReloadTracks", 2861 3253 ); 2862 3254 let mut req = request.into_request(); 2863 - req.extensions_mut().insert(GrpcMethod::new( 2864 - "rockbox.v1alpha1.PlaybackService", 2865 - "FlushAndReloadTracks", 2866 - )); 3255 + req.extensions_mut() 3256 + .insert( 3257 + GrpcMethod::new( 3258 + "rockbox.v1alpha1.PlaybackService", 3259 + "FlushAndReloadTracks", 3260 + ), 3261 + ); 2867 3262 self.inner.unary(req, path, codec).await 2868 3263 } 2869 3264 pub async fn get_file_position( 2870 3265 &mut self, 2871 3266 request: impl tonic::IntoRequest<super::GetFilePositionRequest>, 2872 - ) -> std::result::Result<tonic::Response<super::GetFilePositionResponse>, tonic::Status> 2873 - { 2874 - self.inner.ready().await.map_err(|e| { 2875 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2876 - })?; 3267 + ) -> std::result::Result< 3268 + tonic::Response<super::GetFilePositionResponse>, 3269 + tonic::Status, 3270 + > { 3271 + self.inner 3272 + .ready() 3273 + .await 3274 + .map_err(|e| { 3275 + tonic::Status::unknown( 3276 + format!("Service was not ready: {}", e.into()), 3277 + ) 3278 + })?; 2877 3279 let codec = tonic::codec::ProstCodec::default(); 2878 3280 let path = http::uri::PathAndQuery::from_static( 2879 3281 "/rockbox.v1alpha1.PlaybackService/GetFilePosition", 2880 3282 ); 2881 3283 let mut req = request.into_request(); 2882 - req.extensions_mut().insert(GrpcMethod::new( 2883 - "rockbox.v1alpha1.PlaybackService", 2884 - "GetFilePosition", 2885 - )); 3284 + req.extensions_mut() 3285 + .insert( 3286 + GrpcMethod::new( 3287 + "rockbox.v1alpha1.PlaybackService", 3288 + "GetFilePosition", 3289 + ), 3290 + ); 2886 3291 self.inner.unary(req, path, codec).await 2887 3292 } 2888 3293 pub async fn hard_stop( 2889 3294 &mut self, 2890 3295 request: impl tonic::IntoRequest<super::HardStopRequest>, 2891 - ) -> std::result::Result<tonic::Response<super::HardStopResponse>, tonic::Status> { 2892 - self.inner.ready().await.map_err(|e| { 2893 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2894 - })?; 3296 + ) -> std::result::Result< 3297 + tonic::Response<super::HardStopResponse>, 3298 + tonic::Status, 3299 + > { 3300 + self.inner 3301 + .ready() 3302 + .await 3303 + .map_err(|e| { 3304 + tonic::Status::unknown( 3305 + format!("Service was not ready: {}", e.into()), 3306 + ) 3307 + })?; 2895 3308 let codec = tonic::codec::ProstCodec::default(); 2896 - let path = 2897 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/HardStop"); 3309 + let path = http::uri::PathAndQuery::from_static( 3310 + "/rockbox.v1alpha1.PlaybackService/HardStop", 3311 + ); 2898 3312 let mut req = request.into_request(); 2899 - req.extensions_mut().insert(GrpcMethod::new( 2900 - "rockbox.v1alpha1.PlaybackService", 2901 - "HardStop", 2902 - )); 3313 + req.extensions_mut() 3314 + .insert(GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "HardStop")); 2903 3315 self.inner.unary(req, path, codec).await 2904 3316 } 2905 3317 pub async fn play_album( 2906 3318 &mut self, 2907 3319 request: impl tonic::IntoRequest<super::PlayAlbumRequest>, 2908 - ) -> std::result::Result<tonic::Response<super::PlayAlbumResponse>, tonic::Status> { 2909 - self.inner.ready().await.map_err(|e| { 2910 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2911 - })?; 3320 + ) -> std::result::Result< 3321 + tonic::Response<super::PlayAlbumResponse>, 3322 + tonic::Status, 3323 + > { 3324 + self.inner 3325 + .ready() 3326 + .await 3327 + .map_err(|e| { 3328 + tonic::Status::unknown( 3329 + format!("Service was not ready: {}", e.into()), 3330 + ) 3331 + })?; 2912 3332 let codec = tonic::codec::ProstCodec::default(); 2913 - let path = 2914 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/PlayAlbum"); 3333 + let path = http::uri::PathAndQuery::from_static( 3334 + "/rockbox.v1alpha1.PlaybackService/PlayAlbum", 3335 + ); 2915 3336 let mut req = request.into_request(); 2916 - req.extensions_mut().insert(GrpcMethod::new( 2917 - "rockbox.v1alpha1.PlaybackService", 2918 - "PlayAlbum", 2919 - )); 3337 + req.extensions_mut() 3338 + .insert( 3339 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "PlayAlbum"), 3340 + ); 2920 3341 self.inner.unary(req, path, codec).await 2921 3342 } 2922 3343 pub async fn play_artist_tracks( 2923 3344 &mut self, 2924 3345 request: impl tonic::IntoRequest<super::PlayArtistTracksRequest>, 2925 - ) -> std::result::Result<tonic::Response<super::PlayArtistTracksResponse>, tonic::Status> 2926 - { 2927 - self.inner.ready().await.map_err(|e| { 2928 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2929 - })?; 3346 + ) -> std::result::Result< 3347 + tonic::Response<super::PlayArtistTracksResponse>, 3348 + tonic::Status, 3349 + > { 3350 + self.inner 3351 + .ready() 3352 + .await 3353 + .map_err(|e| { 3354 + tonic::Status::unknown( 3355 + format!("Service was not ready: {}", e.into()), 3356 + ) 3357 + })?; 2930 3358 let codec = tonic::codec::ProstCodec::default(); 2931 3359 let path = http::uri::PathAndQuery::from_static( 2932 3360 "/rockbox.v1alpha1.PlaybackService/PlayArtistTracks", 2933 3361 ); 2934 3362 let mut req = request.into_request(); 2935 - req.extensions_mut().insert(GrpcMethod::new( 2936 - "rockbox.v1alpha1.PlaybackService", 2937 - "PlayArtistTracks", 2938 - )); 3363 + req.extensions_mut() 3364 + .insert( 3365 + GrpcMethod::new( 3366 + "rockbox.v1alpha1.PlaybackService", 3367 + "PlayArtistTracks", 3368 + ), 3369 + ); 2939 3370 self.inner.unary(req, path, codec).await 2940 3371 } 2941 3372 pub async fn play_playlist( 2942 3373 &mut self, 2943 3374 request: impl tonic::IntoRequest<super::PlayPlaylistRequest>, 2944 - ) -> std::result::Result<tonic::Response<super::PlayPlaylistResponse>, tonic::Status> 2945 - { 2946 - self.inner.ready().await.map_err(|e| { 2947 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2948 - })?; 3375 + ) -> std::result::Result< 3376 + tonic::Response<super::PlayPlaylistResponse>, 3377 + tonic::Status, 3378 + > { 3379 + self.inner 3380 + .ready() 3381 + .await 3382 + .map_err(|e| { 3383 + tonic::Status::unknown( 3384 + format!("Service was not ready: {}", e.into()), 3385 + ) 3386 + })?; 2949 3387 let codec = tonic::codec::ProstCodec::default(); 2950 3388 let path = http::uri::PathAndQuery::from_static( 2951 3389 "/rockbox.v1alpha1.PlaybackService/PlayPlaylist", 2952 3390 ); 2953 3391 let mut req = request.into_request(); 2954 - req.extensions_mut().insert(GrpcMethod::new( 2955 - "rockbox.v1alpha1.PlaybackService", 2956 - "PlayPlaylist", 2957 - )); 3392 + req.extensions_mut() 3393 + .insert( 3394 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "PlayPlaylist"), 3395 + ); 2958 3396 self.inner.unary(req, path, codec).await 2959 3397 } 2960 3398 pub async fn play_directory( 2961 3399 &mut self, 2962 3400 request: impl tonic::IntoRequest<super::PlayDirectoryRequest>, 2963 - ) -> std::result::Result<tonic::Response<super::PlayDirectoryResponse>, tonic::Status> 2964 - { 2965 - self.inner.ready().await.map_err(|e| { 2966 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2967 - })?; 3401 + ) -> std::result::Result< 3402 + tonic::Response<super::PlayDirectoryResponse>, 3403 + tonic::Status, 3404 + > { 3405 + self.inner 3406 + .ready() 3407 + .await 3408 + .map_err(|e| { 3409 + tonic::Status::unknown( 3410 + format!("Service was not ready: {}", e.into()), 3411 + ) 3412 + })?; 2968 3413 let codec = tonic::codec::ProstCodec::default(); 2969 3414 let path = http::uri::PathAndQuery::from_static( 2970 3415 "/rockbox.v1alpha1.PlaybackService/PlayDirectory", 2971 3416 ); 2972 3417 let mut req = request.into_request(); 2973 - req.extensions_mut().insert(GrpcMethod::new( 2974 - "rockbox.v1alpha1.PlaybackService", 2975 - "PlayDirectory", 2976 - )); 3418 + req.extensions_mut() 3419 + .insert( 3420 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "PlayDirectory"), 3421 + ); 2977 3422 self.inner.unary(req, path, codec).await 2978 3423 } 2979 3424 pub async fn play_music_directory( 2980 3425 &mut self, 2981 3426 request: impl tonic::IntoRequest<super::PlayMusicDirectoryRequest>, 2982 - ) -> std::result::Result<tonic::Response<super::PlayMusicDirectoryResponse>, tonic::Status> 2983 - { 2984 - self.inner.ready().await.map_err(|e| { 2985 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 2986 - })?; 3427 + ) -> std::result::Result< 3428 + tonic::Response<super::PlayMusicDirectoryResponse>, 3429 + tonic::Status, 3430 + > { 3431 + self.inner 3432 + .ready() 3433 + .await 3434 + .map_err(|e| { 3435 + tonic::Status::unknown( 3436 + format!("Service was not ready: {}", e.into()), 3437 + ) 3438 + })?; 2987 3439 let codec = tonic::codec::ProstCodec::default(); 2988 3440 let path = http::uri::PathAndQuery::from_static( 2989 3441 "/rockbox.v1alpha1.PlaybackService/PlayMusicDirectory", 2990 3442 ); 2991 3443 let mut req = request.into_request(); 2992 - req.extensions_mut().insert(GrpcMethod::new( 2993 - "rockbox.v1alpha1.PlaybackService", 2994 - "PlayMusicDirectory", 2995 - )); 3444 + req.extensions_mut() 3445 + .insert( 3446 + GrpcMethod::new( 3447 + "rockbox.v1alpha1.PlaybackService", 3448 + "PlayMusicDirectory", 3449 + ), 3450 + ); 2996 3451 self.inner.unary(req, path, codec).await 2997 3452 } 2998 3453 pub async fn play_track( 2999 3454 &mut self, 3000 3455 request: impl tonic::IntoRequest<super::PlayTrackRequest>, 3001 - ) -> std::result::Result<tonic::Response<super::PlayTrackResponse>, tonic::Status> { 3002 - self.inner.ready().await.map_err(|e| { 3003 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 3004 - })?; 3456 + ) -> std::result::Result< 3457 + tonic::Response<super::PlayTrackResponse>, 3458 + tonic::Status, 3459 + > { 3460 + self.inner 3461 + .ready() 3462 + .await 3463 + .map_err(|e| { 3464 + tonic::Status::unknown( 3465 + format!("Service was not ready: {}", e.into()), 3466 + ) 3467 + })?; 3005 3468 let codec = tonic::codec::ProstCodec::default(); 3006 - let path = 3007 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaybackService/PlayTrack"); 3469 + let path = http::uri::PathAndQuery::from_static( 3470 + "/rockbox.v1alpha1.PlaybackService/PlayTrack", 3471 + ); 3008 3472 let mut req = request.into_request(); 3009 - req.extensions_mut().insert(GrpcMethod::new( 3010 - "rockbox.v1alpha1.PlaybackService", 3011 - "PlayTrack", 3012 - )); 3473 + req.extensions_mut() 3474 + .insert( 3475 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "PlayTrack"), 3476 + ); 3013 3477 self.inner.unary(req, path, codec).await 3014 3478 } 3015 3479 pub async fn play_liked_tracks( 3016 3480 &mut self, 3017 3481 request: impl tonic::IntoRequest<super::PlayLikedTracksRequest>, 3018 - ) -> std::result::Result<tonic::Response<super::PlayLikedTracksResponse>, tonic::Status> 3019 - { 3020 - self.inner.ready().await.map_err(|e| { 3021 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 3022 - })?; 3482 + ) -> std::result::Result< 3483 + tonic::Response<super::PlayLikedTracksResponse>, 3484 + tonic::Status, 3485 + > { 3486 + self.inner 3487 + .ready() 3488 + .await 3489 + .map_err(|e| { 3490 + tonic::Status::unknown( 3491 + format!("Service was not ready: {}", e.into()), 3492 + ) 3493 + })?; 3023 3494 let codec = tonic::codec::ProstCodec::default(); 3024 3495 let path = http::uri::PathAndQuery::from_static( 3025 3496 "/rockbox.v1alpha1.PlaybackService/PlayLikedTracks", 3026 3497 ); 3027 3498 let mut req = request.into_request(); 3028 - req.extensions_mut().insert(GrpcMethod::new( 3029 - "rockbox.v1alpha1.PlaybackService", 3030 - "PlayLikedTracks", 3031 - )); 3499 + req.extensions_mut() 3500 + .insert( 3501 + GrpcMethod::new( 3502 + "rockbox.v1alpha1.PlaybackService", 3503 + "PlayLikedTracks", 3504 + ), 3505 + ); 3032 3506 self.inner.unary(req, path, codec).await 3033 3507 } 3034 3508 pub async fn play_all_tracks( 3035 3509 &mut self, 3036 3510 request: impl tonic::IntoRequest<super::PlayAllTracksRequest>, 3037 - ) -> std::result::Result<tonic::Response<super::PlayAllTracksResponse>, tonic::Status> 3038 - { 3039 - self.inner.ready().await.map_err(|e| { 3040 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 3041 - })?; 3511 + ) -> std::result::Result< 3512 + tonic::Response<super::PlayAllTracksResponse>, 3513 + tonic::Status, 3514 + > { 3515 + self.inner 3516 + .ready() 3517 + .await 3518 + .map_err(|e| { 3519 + tonic::Status::unknown( 3520 + format!("Service was not ready: {}", e.into()), 3521 + ) 3522 + })?; 3042 3523 let codec = tonic::codec::ProstCodec::default(); 3043 3524 let path = http::uri::PathAndQuery::from_static( 3044 3525 "/rockbox.v1alpha1.PlaybackService/PlayAllTracks", 3045 3526 ); 3046 3527 let mut req = request.into_request(); 3047 - req.extensions_mut().insert(GrpcMethod::new( 3048 - "rockbox.v1alpha1.PlaybackService", 3049 - "PlayAllTracks", 3050 - )); 3528 + req.extensions_mut() 3529 + .insert( 3530 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "PlayAllTracks"), 3531 + ); 3051 3532 self.inner.unary(req, path, codec).await 3052 3533 } 3053 3534 pub async fn stream_current_track( ··· 3057 3538 tonic::Response<tonic::codec::Streaming<super::CurrentTrackResponse>>, 3058 3539 tonic::Status, 3059 3540 > { 3060 - self.inner.ready().await.map_err(|e| { 3061 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 3062 - })?; 3541 + self.inner 3542 + .ready() 3543 + .await 3544 + .map_err(|e| { 3545 + tonic::Status::unknown( 3546 + format!("Service was not ready: {}", e.into()), 3547 + ) 3548 + })?; 3063 3549 let codec = tonic::codec::ProstCodec::default(); 3064 3550 let path = http::uri::PathAndQuery::from_static( 3065 3551 "/rockbox.v1alpha1.PlaybackService/StreamCurrentTrack", 3066 3552 ); 3067 3553 let mut req = request.into_request(); 3068 - req.extensions_mut().insert(GrpcMethod::new( 3069 - "rockbox.v1alpha1.PlaybackService", 3070 - "StreamCurrentTrack", 3071 - )); 3554 + req.extensions_mut() 3555 + .insert( 3556 + GrpcMethod::new( 3557 + "rockbox.v1alpha1.PlaybackService", 3558 + "StreamCurrentTrack", 3559 + ), 3560 + ); 3072 3561 self.inner.server_streaming(req, path, codec).await 3073 3562 } 3074 3563 pub async fn stream_status( ··· 3078 3567 tonic::Response<tonic::codec::Streaming<super::StatusResponse>>, 3079 3568 tonic::Status, 3080 3569 > { 3081 - self.inner.ready().await.map_err(|e| { 3082 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 3083 - })?; 3570 + self.inner 3571 + .ready() 3572 + .await 3573 + .map_err(|e| { 3574 + tonic::Status::unknown( 3575 + format!("Service was not ready: {}", e.into()), 3576 + ) 3577 + })?; 3084 3578 let codec = tonic::codec::ProstCodec::default(); 3085 3579 let path = http::uri::PathAndQuery::from_static( 3086 3580 "/rockbox.v1alpha1.PlaybackService/StreamStatus", 3087 3581 ); 3088 3582 let mut req = request.into_request(); 3089 - req.extensions_mut().insert(GrpcMethod::new( 3090 - "rockbox.v1alpha1.PlaybackService", 3091 - "StreamStatus", 3092 - )); 3583 + req.extensions_mut() 3584 + .insert( 3585 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "StreamStatus"), 3586 + ); 3093 3587 self.inner.server_streaming(req, path, codec).await 3094 3588 } 3095 3589 pub async fn stream_playlist( ··· 3099 3593 tonic::Response<tonic::codec::Streaming<super::PlaylistResponse>>, 3100 3594 tonic::Status, 3101 3595 > { 3102 - self.inner.ready().await.map_err(|e| { 3103 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 3104 - })?; 3596 + self.inner 3597 + .ready() 3598 + .await 3599 + .map_err(|e| { 3600 + tonic::Status::unknown( 3601 + format!("Service was not ready: {}", e.into()), 3602 + ) 3603 + })?; 3105 3604 let codec = tonic::codec::ProstCodec::default(); 3106 3605 let path = http::uri::PathAndQuery::from_static( 3107 3606 "/rockbox.v1alpha1.PlaybackService/StreamPlaylist", 3108 3607 ); 3109 3608 let mut req = request.into_request(); 3110 - req.extensions_mut().insert(GrpcMethod::new( 3111 - "rockbox.v1alpha1.PlaybackService", 3112 - "StreamPlaylist", 3113 - )); 3609 + req.extensions_mut() 3610 + .insert( 3611 + GrpcMethod::new("rockbox.v1alpha1.PlaybackService", "StreamPlaylist"), 3612 + ); 3114 3613 self.inner.server_streaming(req, path, codec).await 3115 3614 } 3116 3615 } ··· 3122 3621 dead_code, 3123 3622 missing_docs, 3124 3623 clippy::wildcard_imports, 3125 - clippy::let_unit_value 3624 + clippy::let_unit_value, 3126 3625 )] 3127 3626 use tonic::codegen::*; 3128 3627 /// Generated trait containing gRPC methods that should be implemented for use with PlaybackServiceServer. ··· 3139 3638 async fn play_or_pause( 3140 3639 &self, 3141 3640 request: tonic::Request<super::PlayOrPauseRequest>, 3142 - ) -> std::result::Result<tonic::Response<super::PlayOrPauseResponse>, tonic::Status>; 3641 + ) -> std::result::Result< 3642 + tonic::Response<super::PlayOrPauseResponse>, 3643 + tonic::Status, 3644 + >; 3143 3645 async fn resume( 3144 3646 &self, 3145 3647 request: tonic::Request<super::ResumeRequest>, ··· 3151 3653 async fn previous( 3152 3654 &self, 3153 3655 request: tonic::Request<super::PreviousRequest>, 3154 - ) -> std::result::Result<tonic::Response<super::PreviousResponse>, tonic::Status>; 3656 + ) -> std::result::Result< 3657 + tonic::Response<super::PreviousResponse>, 3658 + tonic::Status, 3659 + >; 3155 3660 async fn fast_forward_rewind( 3156 3661 &self, 3157 3662 request: tonic::Request<super::FastForwardRewindRequest>, 3158 - ) -> std::result::Result<tonic::Response<super::FastForwardRewindResponse>, tonic::Status>; 3663 + ) -> std::result::Result< 3664 + tonic::Response<super::FastForwardRewindResponse>, 3665 + tonic::Status, 3666 + >; 3159 3667 async fn status( 3160 3668 &self, 3161 3669 request: tonic::Request<super::StatusRequest>, ··· 3163 3671 async fn current_track( 3164 3672 &self, 3165 3673 request: tonic::Request<super::CurrentTrackRequest>, 3166 - ) -> std::result::Result<tonic::Response<super::CurrentTrackResponse>, tonic::Status>; 3674 + ) -> std::result::Result< 3675 + tonic::Response<super::CurrentTrackResponse>, 3676 + tonic::Status, 3677 + >; 3167 3678 async fn next_track( 3168 3679 &self, 3169 3680 request: tonic::Request<super::NextTrackRequest>, 3170 - ) -> std::result::Result<tonic::Response<super::NextTrackResponse>, tonic::Status>; 3681 + ) -> std::result::Result< 3682 + tonic::Response<super::NextTrackResponse>, 3683 + tonic::Status, 3684 + >; 3171 3685 async fn flush_and_reload_tracks( 3172 3686 &self, 3173 3687 request: tonic::Request<super::FlushAndReloadTracksRequest>, 3174 - ) -> std::result::Result<tonic::Response<super::FlushAndReloadTracksResponse>, tonic::Status>; 3688 + ) -> std::result::Result< 3689 + tonic::Response<super::FlushAndReloadTracksResponse>, 3690 + tonic::Status, 3691 + >; 3175 3692 async fn get_file_position( 3176 3693 &self, 3177 3694 request: tonic::Request<super::GetFilePositionRequest>, 3178 - ) -> std::result::Result<tonic::Response<super::GetFilePositionResponse>, tonic::Status>; 3695 + ) -> std::result::Result< 3696 + tonic::Response<super::GetFilePositionResponse>, 3697 + tonic::Status, 3698 + >; 3179 3699 async fn hard_stop( 3180 3700 &self, 3181 3701 request: tonic::Request<super::HardStopRequest>, 3182 - ) -> std::result::Result<tonic::Response<super::HardStopResponse>, tonic::Status>; 3702 + ) -> std::result::Result< 3703 + tonic::Response<super::HardStopResponse>, 3704 + tonic::Status, 3705 + >; 3183 3706 async fn play_album( 3184 3707 &self, 3185 3708 request: tonic::Request<super::PlayAlbumRequest>, 3186 - ) -> std::result::Result<tonic::Response<super::PlayAlbumResponse>, tonic::Status>; 3709 + ) -> std::result::Result< 3710 + tonic::Response<super::PlayAlbumResponse>, 3711 + tonic::Status, 3712 + >; 3187 3713 async fn play_artist_tracks( 3188 3714 &self, 3189 3715 request: tonic::Request<super::PlayArtistTracksRequest>, 3190 - ) -> std::result::Result<tonic::Response<super::PlayArtistTracksResponse>, tonic::Status>; 3716 + ) -> std::result::Result< 3717 + tonic::Response<super::PlayArtistTracksResponse>, 3718 + tonic::Status, 3719 + >; 3191 3720 async fn play_playlist( 3192 3721 &self, 3193 3722 request: tonic::Request<super::PlayPlaylistRequest>, 3194 - ) -> std::result::Result<tonic::Response<super::PlayPlaylistResponse>, tonic::Status>; 3723 + ) -> std::result::Result< 3724 + tonic::Response<super::PlayPlaylistResponse>, 3725 + tonic::Status, 3726 + >; 3195 3727 async fn play_directory( 3196 3728 &self, 3197 3729 request: tonic::Request<super::PlayDirectoryRequest>, 3198 - ) -> std::result::Result<tonic::Response<super::PlayDirectoryResponse>, tonic::Status>; 3730 + ) -> std::result::Result< 3731 + tonic::Response<super::PlayDirectoryResponse>, 3732 + tonic::Status, 3733 + >; 3199 3734 async fn play_music_directory( 3200 3735 &self, 3201 3736 request: tonic::Request<super::PlayMusicDirectoryRequest>, 3202 - ) -> std::result::Result<tonic::Response<super::PlayMusicDirectoryResponse>, tonic::Status>; 3737 + ) -> std::result::Result< 3738 + tonic::Response<super::PlayMusicDirectoryResponse>, 3739 + tonic::Status, 3740 + >; 3203 3741 async fn play_track( 3204 3742 &self, 3205 3743 request: tonic::Request<super::PlayTrackRequest>, 3206 - ) -> std::result::Result<tonic::Response<super::PlayTrackResponse>, tonic::Status>; 3744 + ) -> std::result::Result< 3745 + tonic::Response<super::PlayTrackResponse>, 3746 + tonic::Status, 3747 + >; 3207 3748 async fn play_liked_tracks( 3208 3749 &self, 3209 3750 request: tonic::Request<super::PlayLikedTracksRequest>, 3210 - ) -> std::result::Result<tonic::Response<super::PlayLikedTracksResponse>, tonic::Status>; 3751 + ) -> std::result::Result< 3752 + tonic::Response<super::PlayLikedTracksResponse>, 3753 + tonic::Status, 3754 + >; 3211 3755 async fn play_all_tracks( 3212 3756 &self, 3213 3757 request: tonic::Request<super::PlayAllTracksRequest>, 3214 - ) -> std::result::Result<tonic::Response<super::PlayAllTracksResponse>, tonic::Status>; 3758 + ) -> std::result::Result< 3759 + tonic::Response<super::PlayAllTracksResponse>, 3760 + tonic::Status, 3761 + >; 3215 3762 /// Server streaming response type for the StreamCurrentTrack method. 3216 3763 type StreamCurrentTrackStream: tonic::codegen::tokio_stream::Stream< 3217 3764 Item = std::result::Result<super::CurrentTrackResponse, tonic::Status>, 3218 - > + std::marker::Send 3765 + > 3766 + + std::marker::Send 3219 3767 + 'static; 3220 3768 async fn stream_current_track( 3221 3769 &self, 3222 3770 request: tonic::Request<super::StreamCurrentTrackRequest>, 3223 - ) -> std::result::Result<tonic::Response<Self::StreamCurrentTrackStream>, tonic::Status>; 3771 + ) -> std::result::Result< 3772 + tonic::Response<Self::StreamCurrentTrackStream>, 3773 + tonic::Status, 3774 + >; 3224 3775 /// Server streaming response type for the StreamStatus method. 3225 3776 type StreamStatusStream: tonic::codegen::tokio_stream::Stream< 3226 3777 Item = std::result::Result<super::StatusResponse, tonic::Status>, 3227 - > + std::marker::Send 3778 + > 3779 + + std::marker::Send 3228 3780 + 'static; 3229 3781 async fn stream_status( 3230 3782 &self, 3231 3783 request: tonic::Request<super::StreamStatusRequest>, 3232 - ) -> std::result::Result<tonic::Response<Self::StreamStatusStream>, tonic::Status>; 3784 + ) -> std::result::Result< 3785 + tonic::Response<Self::StreamStatusStream>, 3786 + tonic::Status, 3787 + >; 3233 3788 /// Server streaming response type for the StreamPlaylist method. 3234 3789 type StreamPlaylistStream: tonic::codegen::tokio_stream::Stream< 3235 3790 Item = std::result::Result<super::PlaylistResponse, tonic::Status>, 3236 - > + std::marker::Send 3791 + > 3792 + + std::marker::Send 3237 3793 + 'static; 3238 3794 async fn stream_playlist( 3239 3795 &self, 3240 3796 request: tonic::Request<super::StreamPlaylistRequest>, 3241 - ) -> std::result::Result<tonic::Response<Self::StreamPlaylistStream>, tonic::Status>; 3797 + ) -> std::result::Result< 3798 + tonic::Response<Self::StreamPlaylistStream>, 3799 + tonic::Status, 3800 + >; 3242 3801 } 3243 3802 #[derive(Debug)] 3244 3803 pub struct PlaybackServiceServer<T> { ··· 3261 3820 max_encoding_message_size: None, 3262 3821 } 3263 3822 } 3264 - pub fn with_interceptor<F>(inner: T, interceptor: F) -> InterceptedService<Self, F> 3823 + pub fn with_interceptor<F>( 3824 + inner: T, 3825 + interceptor: F, 3826 + ) -> InterceptedService<Self, F> 3265 3827 where 3266 3828 F: tonic::service::Interceptor, 3267 3829 { ··· 3316 3878 "/rockbox.v1alpha1.PlaybackService/Play" => { 3317 3879 #[allow(non_camel_case_types)] 3318 3880 struct PlaySvc<T: PlaybackService>(pub Arc<T>); 3319 - impl<T: PlaybackService> tonic::server::UnaryService<super::PlayRequest> for PlaySvc<T> { 3881 + impl< 3882 + T: PlaybackService, 3883 + > tonic::server::UnaryService<super::PlayRequest> for PlaySvc<T> { 3320 3884 type Response = super::PlayResponse; 3321 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 3885 + type Future = BoxFuture< 3886 + tonic::Response<Self::Response>, 3887 + tonic::Status, 3888 + >; 3322 3889 fn call( 3323 3890 &mut self, 3324 3891 request: tonic::Request<super::PlayRequest>, 3325 3892 ) -> Self::Future { 3326 3893 let inner = Arc::clone(&self.0); 3327 - let fut = 3328 - async move { <T as PlaybackService>::play(&inner, request).await }; 3894 + let fut = async move { 3895 + <T as PlaybackService>::play(&inner, request).await 3896 + }; 3329 3897 Box::pin(fut) 3330 3898 } 3331 3899 } ··· 3354 3922 "/rockbox.v1alpha1.PlaybackService/Pause" => { 3355 3923 #[allow(non_camel_case_types)] 3356 3924 struct PauseSvc<T: PlaybackService>(pub Arc<T>); 3357 - impl<T: PlaybackService> tonic::server::UnaryService<super::PauseRequest> for PauseSvc<T> { 3925 + impl< 3926 + T: PlaybackService, 3927 + > tonic::server::UnaryService<super::PauseRequest> for PauseSvc<T> { 3358 3928 type Response = super::PauseResponse; 3359 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 3929 + type Future = BoxFuture< 3930 + tonic::Response<Self::Response>, 3931 + tonic::Status, 3932 + >; 3360 3933 fn call( 3361 3934 &mut self, 3362 3935 request: tonic::Request<super::PauseRequest>, 3363 3936 ) -> Self::Future { 3364 3937 let inner = Arc::clone(&self.0); 3365 - let fut = 3366 - async move { <T as PlaybackService>::pause(&inner, request).await }; 3938 + let fut = async move { 3939 + <T as PlaybackService>::pause(&inner, request).await 3940 + }; 3367 3941 Box::pin(fut) 3368 3942 } 3369 3943 } ··· 3392 3966 "/rockbox.v1alpha1.PlaybackService/PlayOrPause" => { 3393 3967 #[allow(non_camel_case_types)] 3394 3968 struct PlayOrPauseSvc<T: PlaybackService>(pub Arc<T>); 3395 - impl<T: PlaybackService> tonic::server::UnaryService<super::PlayOrPauseRequest> 3396 - for PlayOrPauseSvc<T> 3397 - { 3969 + impl< 3970 + T: PlaybackService, 3971 + > tonic::server::UnaryService<super::PlayOrPauseRequest> 3972 + for PlayOrPauseSvc<T> { 3398 3973 type Response = super::PlayOrPauseResponse; 3399 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 3974 + type Future = BoxFuture< 3975 + tonic::Response<Self::Response>, 3976 + tonic::Status, 3977 + >; 3400 3978 fn call( 3401 3979 &mut self, 3402 3980 request: tonic::Request<super::PlayOrPauseRequest>, ··· 3433 4011 "/rockbox.v1alpha1.PlaybackService/Resume" => { 3434 4012 #[allow(non_camel_case_types)] 3435 4013 struct ResumeSvc<T: PlaybackService>(pub Arc<T>); 3436 - impl<T: PlaybackService> tonic::server::UnaryService<super::ResumeRequest> for ResumeSvc<T> { 4014 + impl< 4015 + T: PlaybackService, 4016 + > tonic::server::UnaryService<super::ResumeRequest> 4017 + for ResumeSvc<T> { 3437 4018 type Response = super::ResumeResponse; 3438 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4019 + type Future = BoxFuture< 4020 + tonic::Response<Self::Response>, 4021 + tonic::Status, 4022 + >; 3439 4023 fn call( 3440 4024 &mut self, 3441 4025 request: tonic::Request<super::ResumeRequest>, ··· 3472 4056 "/rockbox.v1alpha1.PlaybackService/Next" => { 3473 4057 #[allow(non_camel_case_types)] 3474 4058 struct NextSvc<T: PlaybackService>(pub Arc<T>); 3475 - impl<T: PlaybackService> tonic::server::UnaryService<super::NextRequest> for NextSvc<T> { 4059 + impl< 4060 + T: PlaybackService, 4061 + > tonic::server::UnaryService<super::NextRequest> for NextSvc<T> { 3476 4062 type Response = super::NextResponse; 3477 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4063 + type Future = BoxFuture< 4064 + tonic::Response<Self::Response>, 4065 + tonic::Status, 4066 + >; 3478 4067 fn call( 3479 4068 &mut self, 3480 4069 request: tonic::Request<super::NextRequest>, 3481 4070 ) -> Self::Future { 3482 4071 let inner = Arc::clone(&self.0); 3483 - let fut = 3484 - async move { <T as PlaybackService>::next(&inner, request).await }; 4072 + let fut = async move { 4073 + <T as PlaybackService>::next(&inner, request).await 4074 + }; 3485 4075 Box::pin(fut) 3486 4076 } 3487 4077 } ··· 3510 4100 "/rockbox.v1alpha1.PlaybackService/Previous" => { 3511 4101 #[allow(non_camel_case_types)] 3512 4102 struct PreviousSvc<T: PlaybackService>(pub Arc<T>); 3513 - impl<T: PlaybackService> tonic::server::UnaryService<super::PreviousRequest> for PreviousSvc<T> { 4103 + impl< 4104 + T: PlaybackService, 4105 + > tonic::server::UnaryService<super::PreviousRequest> 4106 + for PreviousSvc<T> { 3514 4107 type Response = super::PreviousResponse; 3515 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4108 + type Future = BoxFuture< 4109 + tonic::Response<Self::Response>, 4110 + tonic::Status, 4111 + >; 3516 4112 fn call( 3517 4113 &mut self, 3518 4114 request: tonic::Request<super::PreviousRequest>, ··· 3549 4145 "/rockbox.v1alpha1.PlaybackService/FastForwardRewind" => { 3550 4146 #[allow(non_camel_case_types)] 3551 4147 struct FastForwardRewindSvc<T: PlaybackService>(pub Arc<T>); 3552 - impl<T: PlaybackService> 3553 - tonic::server::UnaryService<super::FastForwardRewindRequest> 3554 - for FastForwardRewindSvc<T> 3555 - { 4148 + impl< 4149 + T: PlaybackService, 4150 + > tonic::server::UnaryService<super::FastForwardRewindRequest> 4151 + for FastForwardRewindSvc<T> { 3556 4152 type Response = super::FastForwardRewindResponse; 3557 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4153 + type Future = BoxFuture< 4154 + tonic::Response<Self::Response>, 4155 + tonic::Status, 4156 + >; 3558 4157 fn call( 3559 4158 &mut self, 3560 4159 request: tonic::Request<super::FastForwardRewindRequest>, 3561 4160 ) -> Self::Future { 3562 4161 let inner = Arc::clone(&self.0); 3563 4162 let fut = async move { 3564 - <T as PlaybackService>::fast_forward_rewind(&inner, request).await 4163 + <T as PlaybackService>::fast_forward_rewind(&inner, request) 4164 + .await 3565 4165 }; 3566 4166 Box::pin(fut) 3567 4167 } ··· 3591 4191 "/rockbox.v1alpha1.PlaybackService/Status" => { 3592 4192 #[allow(non_camel_case_types)] 3593 4193 struct StatusSvc<T: PlaybackService>(pub Arc<T>); 3594 - impl<T: PlaybackService> tonic::server::UnaryService<super::StatusRequest> for StatusSvc<T> { 4194 + impl< 4195 + T: PlaybackService, 4196 + > tonic::server::UnaryService<super::StatusRequest> 4197 + for StatusSvc<T> { 3595 4198 type Response = super::StatusResponse; 3596 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4199 + type Future = BoxFuture< 4200 + tonic::Response<Self::Response>, 4201 + tonic::Status, 4202 + >; 3597 4203 fn call( 3598 4204 &mut self, 3599 4205 request: tonic::Request<super::StatusRequest>, ··· 3630 4236 "/rockbox.v1alpha1.PlaybackService/CurrentTrack" => { 3631 4237 #[allow(non_camel_case_types)] 3632 4238 struct CurrentTrackSvc<T: PlaybackService>(pub Arc<T>); 3633 - impl<T: PlaybackService> tonic::server::UnaryService<super::CurrentTrackRequest> 3634 - for CurrentTrackSvc<T> 3635 - { 4239 + impl< 4240 + T: PlaybackService, 4241 + > tonic::server::UnaryService<super::CurrentTrackRequest> 4242 + for CurrentTrackSvc<T> { 3636 4243 type Response = super::CurrentTrackResponse; 3637 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4244 + type Future = BoxFuture< 4245 + tonic::Response<Self::Response>, 4246 + tonic::Status, 4247 + >; 3638 4248 fn call( 3639 4249 &mut self, 3640 4250 request: tonic::Request<super::CurrentTrackRequest>, ··· 3671 4281 "/rockbox.v1alpha1.PlaybackService/NextTrack" => { 3672 4282 #[allow(non_camel_case_types)] 3673 4283 struct NextTrackSvc<T: PlaybackService>(pub Arc<T>); 3674 - impl<T: PlaybackService> tonic::server::UnaryService<super::NextTrackRequest> for NextTrackSvc<T> { 4284 + impl< 4285 + T: PlaybackService, 4286 + > tonic::server::UnaryService<super::NextTrackRequest> 4287 + for NextTrackSvc<T> { 3675 4288 type Response = super::NextTrackResponse; 3676 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4289 + type Future = BoxFuture< 4290 + tonic::Response<Self::Response>, 4291 + tonic::Status, 4292 + >; 3677 4293 fn call( 3678 4294 &mut self, 3679 4295 request: tonic::Request<super::NextTrackRequest>, ··· 3710 4326 "/rockbox.v1alpha1.PlaybackService/FlushAndReloadTracks" => { 3711 4327 #[allow(non_camel_case_types)] 3712 4328 struct FlushAndReloadTracksSvc<T: PlaybackService>(pub Arc<T>); 3713 - impl<T: PlaybackService> 3714 - tonic::server::UnaryService<super::FlushAndReloadTracksRequest> 3715 - for FlushAndReloadTracksSvc<T> 3716 - { 4329 + impl< 4330 + T: PlaybackService, 4331 + > tonic::server::UnaryService<super::FlushAndReloadTracksRequest> 4332 + for FlushAndReloadTracksSvc<T> { 3717 4333 type Response = super::FlushAndReloadTracksResponse; 3718 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4334 + type Future = BoxFuture< 4335 + tonic::Response<Self::Response>, 4336 + tonic::Status, 4337 + >; 3719 4338 fn call( 3720 4339 &mut self, 3721 4340 request: tonic::Request<super::FlushAndReloadTracksRequest>, 3722 4341 ) -> Self::Future { 3723 4342 let inner = Arc::clone(&self.0); 3724 4343 let fut = async move { 3725 - <T as PlaybackService>::flush_and_reload_tracks(&inner, request) 4344 + <T as PlaybackService>::flush_and_reload_tracks( 4345 + &inner, 4346 + request, 4347 + ) 3726 4348 .await 3727 4349 }; 3728 4350 Box::pin(fut) ··· 3753 4375 "/rockbox.v1alpha1.PlaybackService/GetFilePosition" => { 3754 4376 #[allow(non_camel_case_types)] 3755 4377 struct GetFilePositionSvc<T: PlaybackService>(pub Arc<T>); 3756 - impl<T: PlaybackService> 3757 - tonic::server::UnaryService<super::GetFilePositionRequest> 3758 - for GetFilePositionSvc<T> 3759 - { 4378 + impl< 4379 + T: PlaybackService, 4380 + > tonic::server::UnaryService<super::GetFilePositionRequest> 4381 + for GetFilePositionSvc<T> { 3760 4382 type Response = super::GetFilePositionResponse; 3761 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4383 + type Future = BoxFuture< 4384 + tonic::Response<Self::Response>, 4385 + tonic::Status, 4386 + >; 3762 4387 fn call( 3763 4388 &mut self, 3764 4389 request: tonic::Request<super::GetFilePositionRequest>, 3765 4390 ) -> Self::Future { 3766 4391 let inner = Arc::clone(&self.0); 3767 4392 let fut = async move { 3768 - <T as PlaybackService>::get_file_position(&inner, request).await 4393 + <T as PlaybackService>::get_file_position(&inner, request) 4394 + .await 3769 4395 }; 3770 4396 Box::pin(fut) 3771 4397 } ··· 3795 4421 "/rockbox.v1alpha1.PlaybackService/HardStop" => { 3796 4422 #[allow(non_camel_case_types)] 3797 4423 struct HardStopSvc<T: PlaybackService>(pub Arc<T>); 3798 - impl<T: PlaybackService> tonic::server::UnaryService<super::HardStopRequest> for HardStopSvc<T> { 4424 + impl< 4425 + T: PlaybackService, 4426 + > tonic::server::UnaryService<super::HardStopRequest> 4427 + for HardStopSvc<T> { 3799 4428 type Response = super::HardStopResponse; 3800 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4429 + type Future = BoxFuture< 4430 + tonic::Response<Self::Response>, 4431 + tonic::Status, 4432 + >; 3801 4433 fn call( 3802 4434 &mut self, 3803 4435 request: tonic::Request<super::HardStopRequest>, ··· 3834 4466 "/rockbox.v1alpha1.PlaybackService/PlayAlbum" => { 3835 4467 #[allow(non_camel_case_types)] 3836 4468 struct PlayAlbumSvc<T: PlaybackService>(pub Arc<T>); 3837 - impl<T: PlaybackService> tonic::server::UnaryService<super::PlayAlbumRequest> for PlayAlbumSvc<T> { 4469 + impl< 4470 + T: PlaybackService, 4471 + > tonic::server::UnaryService<super::PlayAlbumRequest> 4472 + for PlayAlbumSvc<T> { 3838 4473 type Response = super::PlayAlbumResponse; 3839 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4474 + type Future = BoxFuture< 4475 + tonic::Response<Self::Response>, 4476 + tonic::Status, 4477 + >; 3840 4478 fn call( 3841 4479 &mut self, 3842 4480 request: tonic::Request<super::PlayAlbumRequest>, ··· 3873 4511 "/rockbox.v1alpha1.PlaybackService/PlayArtistTracks" => { 3874 4512 #[allow(non_camel_case_types)] 3875 4513 struct PlayArtistTracksSvc<T: PlaybackService>(pub Arc<T>); 3876 - impl<T: PlaybackService> 3877 - tonic::server::UnaryService<super::PlayArtistTracksRequest> 3878 - for PlayArtistTracksSvc<T> 3879 - { 4514 + impl< 4515 + T: PlaybackService, 4516 + > tonic::server::UnaryService<super::PlayArtistTracksRequest> 4517 + for PlayArtistTracksSvc<T> { 3880 4518 type Response = super::PlayArtistTracksResponse; 3881 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4519 + type Future = BoxFuture< 4520 + tonic::Response<Self::Response>, 4521 + tonic::Status, 4522 + >; 3882 4523 fn call( 3883 4524 &mut self, 3884 4525 request: tonic::Request<super::PlayArtistTracksRequest>, 3885 4526 ) -> Self::Future { 3886 4527 let inner = Arc::clone(&self.0); 3887 4528 let fut = async move { 3888 - <T as PlaybackService>::play_artist_tracks(&inner, request).await 4529 + <T as PlaybackService>::play_artist_tracks(&inner, request) 4530 + .await 3889 4531 }; 3890 4532 Box::pin(fut) 3891 4533 } ··· 3915 4557 "/rockbox.v1alpha1.PlaybackService/PlayPlaylist" => { 3916 4558 #[allow(non_camel_case_types)] 3917 4559 struct PlayPlaylistSvc<T: PlaybackService>(pub Arc<T>); 3918 - impl<T: PlaybackService> tonic::server::UnaryService<super::PlayPlaylistRequest> 3919 - for PlayPlaylistSvc<T> 3920 - { 4560 + impl< 4561 + T: PlaybackService, 4562 + > tonic::server::UnaryService<super::PlayPlaylistRequest> 4563 + for PlayPlaylistSvc<T> { 3921 4564 type Response = super::PlayPlaylistResponse; 3922 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4565 + type Future = BoxFuture< 4566 + tonic::Response<Self::Response>, 4567 + tonic::Status, 4568 + >; 3923 4569 fn call( 3924 4570 &mut self, 3925 4571 request: tonic::Request<super::PlayPlaylistRequest>, ··· 3956 4602 "/rockbox.v1alpha1.PlaybackService/PlayDirectory" => { 3957 4603 #[allow(non_camel_case_types)] 3958 4604 struct PlayDirectorySvc<T: PlaybackService>(pub Arc<T>); 3959 - impl<T: PlaybackService> 3960 - tonic::server::UnaryService<super::PlayDirectoryRequest> 3961 - for PlayDirectorySvc<T> 3962 - { 4605 + impl< 4606 + T: PlaybackService, 4607 + > tonic::server::UnaryService<super::PlayDirectoryRequest> 4608 + for PlayDirectorySvc<T> { 3963 4609 type Response = super::PlayDirectoryResponse; 3964 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4610 + type Future = BoxFuture< 4611 + tonic::Response<Self::Response>, 4612 + tonic::Status, 4613 + >; 3965 4614 fn call( 3966 4615 &mut self, 3967 4616 request: tonic::Request<super::PlayDirectoryRequest>, 3968 4617 ) -> Self::Future { 3969 4618 let inner = Arc::clone(&self.0); 3970 4619 let fut = async move { 3971 - <T as PlaybackService>::play_directory(&inner, request).await 4620 + <T as PlaybackService>::play_directory(&inner, request) 4621 + .await 3972 4622 }; 3973 4623 Box::pin(fut) 3974 4624 } ··· 3998 4648 "/rockbox.v1alpha1.PlaybackService/PlayMusicDirectory" => { 3999 4649 #[allow(non_camel_case_types)] 4000 4650 struct PlayMusicDirectorySvc<T: PlaybackService>(pub Arc<T>); 4001 - impl<T: PlaybackService> 4002 - tonic::server::UnaryService<super::PlayMusicDirectoryRequest> 4003 - for PlayMusicDirectorySvc<T> 4004 - { 4651 + impl< 4652 + T: PlaybackService, 4653 + > tonic::server::UnaryService<super::PlayMusicDirectoryRequest> 4654 + for PlayMusicDirectorySvc<T> { 4005 4655 type Response = super::PlayMusicDirectoryResponse; 4006 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4656 + type Future = BoxFuture< 4657 + tonic::Response<Self::Response>, 4658 + tonic::Status, 4659 + >; 4007 4660 fn call( 4008 4661 &mut self, 4009 4662 request: tonic::Request<super::PlayMusicDirectoryRequest>, 4010 4663 ) -> Self::Future { 4011 4664 let inner = Arc::clone(&self.0); 4012 4665 let fut = async move { 4013 - <T as PlaybackService>::play_music_directory(&inner, request).await 4666 + <T as PlaybackService>::play_music_directory( 4667 + &inner, 4668 + request, 4669 + ) 4670 + .await 4014 4671 }; 4015 4672 Box::pin(fut) 4016 4673 } ··· 4040 4697 "/rockbox.v1alpha1.PlaybackService/PlayTrack" => { 4041 4698 #[allow(non_camel_case_types)] 4042 4699 struct PlayTrackSvc<T: PlaybackService>(pub Arc<T>); 4043 - impl<T: PlaybackService> tonic::server::UnaryService<super::PlayTrackRequest> for PlayTrackSvc<T> { 4700 + impl< 4701 + T: PlaybackService, 4702 + > tonic::server::UnaryService<super::PlayTrackRequest> 4703 + for PlayTrackSvc<T> { 4044 4704 type Response = super::PlayTrackResponse; 4045 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4705 + type Future = BoxFuture< 4706 + tonic::Response<Self::Response>, 4707 + tonic::Status, 4708 + >; 4046 4709 fn call( 4047 4710 &mut self, 4048 4711 request: tonic::Request<super::PlayTrackRequest>, ··· 4079 4742 "/rockbox.v1alpha1.PlaybackService/PlayLikedTracks" => { 4080 4743 #[allow(non_camel_case_types)] 4081 4744 struct PlayLikedTracksSvc<T: PlaybackService>(pub Arc<T>); 4082 - impl<T: PlaybackService> 4083 - tonic::server::UnaryService<super::PlayLikedTracksRequest> 4084 - for PlayLikedTracksSvc<T> 4085 - { 4745 + impl< 4746 + T: PlaybackService, 4747 + > tonic::server::UnaryService<super::PlayLikedTracksRequest> 4748 + for PlayLikedTracksSvc<T> { 4086 4749 type Response = super::PlayLikedTracksResponse; 4087 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4750 + type Future = BoxFuture< 4751 + tonic::Response<Self::Response>, 4752 + tonic::Status, 4753 + >; 4088 4754 fn call( 4089 4755 &mut self, 4090 4756 request: tonic::Request<super::PlayLikedTracksRequest>, 4091 4757 ) -> Self::Future { 4092 4758 let inner = Arc::clone(&self.0); 4093 4759 let fut = async move { 4094 - <T as PlaybackService>::play_liked_tracks(&inner, request).await 4760 + <T as PlaybackService>::play_liked_tracks(&inner, request) 4761 + .await 4095 4762 }; 4096 4763 Box::pin(fut) 4097 4764 } ··· 4121 4788 "/rockbox.v1alpha1.PlaybackService/PlayAllTracks" => { 4122 4789 #[allow(non_camel_case_types)] 4123 4790 struct PlayAllTracksSvc<T: PlaybackService>(pub Arc<T>); 4124 - impl<T: PlaybackService> 4125 - tonic::server::UnaryService<super::PlayAllTracksRequest> 4126 - for PlayAllTracksSvc<T> 4127 - { 4791 + impl< 4792 + T: PlaybackService, 4793 + > tonic::server::UnaryService<super::PlayAllTracksRequest> 4794 + for PlayAllTracksSvc<T> { 4128 4795 type Response = super::PlayAllTracksResponse; 4129 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 4796 + type Future = BoxFuture< 4797 + tonic::Response<Self::Response>, 4798 + tonic::Status, 4799 + >; 4130 4800 fn call( 4131 4801 &mut self, 4132 4802 request: tonic::Request<super::PlayAllTracksRequest>, 4133 4803 ) -> Self::Future { 4134 4804 let inner = Arc::clone(&self.0); 4135 4805 let fut = async move { 4136 - <T as PlaybackService>::play_all_tracks(&inner, request).await 4806 + <T as PlaybackService>::play_all_tracks(&inner, request) 4807 + .await 4137 4808 }; 4138 4809 Box::pin(fut) 4139 4810 } ··· 4163 4834 "/rockbox.v1alpha1.PlaybackService/StreamCurrentTrack" => { 4164 4835 #[allow(non_camel_case_types)] 4165 4836 struct StreamCurrentTrackSvc<T: PlaybackService>(pub Arc<T>); 4166 - impl<T: PlaybackService> 4167 - tonic::server::ServerStreamingService<super::StreamCurrentTrackRequest> 4168 - for StreamCurrentTrackSvc<T> 4169 - { 4837 + impl< 4838 + T: PlaybackService, 4839 + > tonic::server::ServerStreamingService< 4840 + super::StreamCurrentTrackRequest, 4841 + > for StreamCurrentTrackSvc<T> { 4170 4842 type Response = super::CurrentTrackResponse; 4171 4843 type ResponseStream = T::StreamCurrentTrackStream; 4172 - type Future = 4173 - BoxFuture<tonic::Response<Self::ResponseStream>, tonic::Status>; 4844 + type Future = BoxFuture< 4845 + tonic::Response<Self::ResponseStream>, 4846 + tonic::Status, 4847 + >; 4174 4848 fn call( 4175 4849 &mut self, 4176 4850 request: tonic::Request<super::StreamCurrentTrackRequest>, 4177 4851 ) -> Self::Future { 4178 4852 let inner = Arc::clone(&self.0); 4179 4853 let fut = async move { 4180 - <T as PlaybackService>::stream_current_track(&inner, request).await 4854 + <T as PlaybackService>::stream_current_track( 4855 + &inner, 4856 + request, 4857 + ) 4858 + .await 4181 4859 }; 4182 4860 Box::pin(fut) 4183 4861 } ··· 4207 4885 "/rockbox.v1alpha1.PlaybackService/StreamStatus" => { 4208 4886 #[allow(non_camel_case_types)] 4209 4887 struct StreamStatusSvc<T: PlaybackService>(pub Arc<T>); 4210 - impl<T: PlaybackService> 4211 - tonic::server::ServerStreamingService<super::StreamStatusRequest> 4212 - for StreamStatusSvc<T> 4213 - { 4888 + impl< 4889 + T: PlaybackService, 4890 + > tonic::server::ServerStreamingService<super::StreamStatusRequest> 4891 + for StreamStatusSvc<T> { 4214 4892 type Response = super::StatusResponse; 4215 4893 type ResponseStream = T::StreamStatusStream; 4216 - type Future = 4217 - BoxFuture<tonic::Response<Self::ResponseStream>, tonic::Status>; 4894 + type Future = BoxFuture< 4895 + tonic::Response<Self::ResponseStream>, 4896 + tonic::Status, 4897 + >; 4218 4898 fn call( 4219 4899 &mut self, 4220 4900 request: tonic::Request<super::StreamStatusRequest>, ··· 4251 4931 "/rockbox.v1alpha1.PlaybackService/StreamPlaylist" => { 4252 4932 #[allow(non_camel_case_types)] 4253 4933 struct StreamPlaylistSvc<T: PlaybackService>(pub Arc<T>); 4254 - impl<T: PlaybackService> 4255 - tonic::server::ServerStreamingService<super::StreamPlaylistRequest> 4256 - for StreamPlaylistSvc<T> 4257 - { 4934 + impl< 4935 + T: PlaybackService, 4936 + > tonic::server::ServerStreamingService<super::StreamPlaylistRequest> 4937 + for StreamPlaylistSvc<T> { 4258 4938 type Response = super::PlaylistResponse; 4259 4939 type ResponseStream = T::StreamPlaylistStream; 4260 - type Future = 4261 - BoxFuture<tonic::Response<Self::ResponseStream>, tonic::Status>; 4940 + type Future = BoxFuture< 4941 + tonic::Response<Self::ResponseStream>, 4942 + tonic::Status, 4943 + >; 4262 4944 fn call( 4263 4945 &mut self, 4264 4946 request: tonic::Request<super::StreamPlaylistRequest>, 4265 4947 ) -> Self::Future { 4266 4948 let inner = Arc::clone(&self.0); 4267 4949 let fut = async move { 4268 - <T as PlaybackService>::stream_playlist(&inner, request).await 4950 + <T as PlaybackService>::stream_playlist(&inner, request) 4951 + .await 4269 4952 }; 4270 4953 Box::pin(fut) 4271 4954 } ··· 4292 4975 }; 4293 4976 Box::pin(fut) 4294 4977 } 4295 - _ => Box::pin(async move { 4296 - let mut response = http::Response::new(empty_body()); 4297 - let headers = response.headers_mut(); 4298 - headers.insert( 4299 - tonic::Status::GRPC_STATUS, 4300 - (tonic::Code::Unimplemented as i32).into(), 4301 - ); 4302 - headers.insert( 4303 - http::header::CONTENT_TYPE, 4304 - tonic::metadata::GRPC_CONTENT_TYPE, 4305 - ); 4306 - Ok(response) 4307 - }), 4978 + _ => { 4979 + Box::pin(async move { 4980 + let mut response = http::Response::new(empty_body()); 4981 + let headers = response.headers_mut(); 4982 + headers 4983 + .insert( 4984 + tonic::Status::GRPC_STATUS, 4985 + (tonic::Code::Unimplemented as i32).into(), 4986 + ); 4987 + headers 4988 + .insert( 4989 + http::header::CONTENT_TYPE, 4990 + tonic::metadata::GRPC_CONTENT_TYPE, 4991 + ); 4992 + Ok(response) 4993 + }) 4994 + } 4308 4995 } 4309 4996 } 4310 4997 } ··· 4511 5198 dead_code, 4512 5199 missing_docs, 4513 5200 clippy::wildcard_imports, 4514 - clippy::let_unit_value 5201 + clippy::let_unit_value, 4515 5202 )] 4516 - use tonic::codegen::http::Uri; 4517 5203 use tonic::codegen::*; 5204 + use tonic::codegen::http::Uri; 4518 5205 #[derive(Debug, Clone)] 4519 5206 pub struct PlaylistServiceClient<T> { 4520 5207 inner: tonic::client::Grpc<T>, ··· 4558 5245 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody, 4559 5246 >, 4560 5247 >, 4561 - <T as tonic::codegen::Service<http::Request<tonic::body::BoxBody>>>::Error: 4562 - Into<StdError> + std::marker::Send + std::marker::Sync, 5248 + <T as tonic::codegen::Service< 5249 + http::Request<tonic::body::BoxBody>, 5250 + >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync, 4563 5251 { 4564 5252 PlaylistServiceClient::new(InterceptedService::new(inner, interceptor)) 4565 5253 } ··· 4597 5285 pub async fn get_current( 4598 5286 &mut self, 4599 5287 request: impl tonic::IntoRequest<super::GetCurrentRequest>, 4600 - ) -> std::result::Result<tonic::Response<super::GetCurrentResponse>, tonic::Status> 4601 - { 4602 - self.inner.ready().await.map_err(|e| { 4603 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4604 - })?; 5288 + ) -> std::result::Result< 5289 + tonic::Response<super::GetCurrentResponse>, 5290 + tonic::Status, 5291 + > { 5292 + self.inner 5293 + .ready() 5294 + .await 5295 + .map_err(|e| { 5296 + tonic::Status::unknown( 5297 + format!("Service was not ready: {}", e.into()), 5298 + ) 5299 + })?; 4605 5300 let codec = tonic::codec::ProstCodec::default(); 4606 5301 let path = http::uri::PathAndQuery::from_static( 4607 5302 "/rockbox.v1alpha1.PlaylistService/GetCurrent", 4608 5303 ); 4609 5304 let mut req = request.into_request(); 4610 - req.extensions_mut().insert(GrpcMethod::new( 4611 - "rockbox.v1alpha1.PlaylistService", 4612 - "GetCurrent", 4613 - )); 5305 + req.extensions_mut() 5306 + .insert( 5307 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "GetCurrent"), 5308 + ); 4614 5309 self.inner.unary(req, path, codec).await 4615 5310 } 4616 5311 pub async fn get_resume_info( 4617 5312 &mut self, 4618 5313 request: impl tonic::IntoRequest<super::GetResumeInfoRequest>, 4619 - ) -> std::result::Result<tonic::Response<super::GetResumeInfoResponse>, tonic::Status> 4620 - { 4621 - self.inner.ready().await.map_err(|e| { 4622 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4623 - })?; 5314 + ) -> std::result::Result< 5315 + tonic::Response<super::GetResumeInfoResponse>, 5316 + tonic::Status, 5317 + > { 5318 + self.inner 5319 + .ready() 5320 + .await 5321 + .map_err(|e| { 5322 + tonic::Status::unknown( 5323 + format!("Service was not ready: {}", e.into()), 5324 + ) 5325 + })?; 4624 5326 let codec = tonic::codec::ProstCodec::default(); 4625 5327 let path = http::uri::PathAndQuery::from_static( 4626 5328 "/rockbox.v1alpha1.PlaylistService/GetResumeInfo", 4627 5329 ); 4628 5330 let mut req = request.into_request(); 4629 - req.extensions_mut().insert(GrpcMethod::new( 4630 - "rockbox.v1alpha1.PlaylistService", 4631 - "GetResumeInfo", 4632 - )); 5331 + req.extensions_mut() 5332 + .insert( 5333 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "GetResumeInfo"), 5334 + ); 4633 5335 self.inner.unary(req, path, codec).await 4634 5336 } 4635 5337 pub async fn get_track_info( 4636 5338 &mut self, 4637 5339 request: impl tonic::IntoRequest<super::GetTrackInfoRequest>, 4638 - ) -> std::result::Result<tonic::Response<super::GetTrackInfoResponse>, tonic::Status> 4639 - { 4640 - self.inner.ready().await.map_err(|e| { 4641 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4642 - })?; 5340 + ) -> std::result::Result< 5341 + tonic::Response<super::GetTrackInfoResponse>, 5342 + tonic::Status, 5343 + > { 5344 + self.inner 5345 + .ready() 5346 + .await 5347 + .map_err(|e| { 5348 + tonic::Status::unknown( 5349 + format!("Service was not ready: {}", e.into()), 5350 + ) 5351 + })?; 4643 5352 let codec = tonic::codec::ProstCodec::default(); 4644 5353 let path = http::uri::PathAndQuery::from_static( 4645 5354 "/rockbox.v1alpha1.PlaylistService/GetTrackInfo", 4646 5355 ); 4647 5356 let mut req = request.into_request(); 4648 - req.extensions_mut().insert(GrpcMethod::new( 4649 - "rockbox.v1alpha1.PlaylistService", 4650 - "GetTrackInfo", 4651 - )); 5357 + req.extensions_mut() 5358 + .insert( 5359 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "GetTrackInfo"), 5360 + ); 4652 5361 self.inner.unary(req, path, codec).await 4653 5362 } 4654 5363 pub async fn get_first_index( 4655 5364 &mut self, 4656 5365 request: impl tonic::IntoRequest<super::GetFirstIndexRequest>, 4657 - ) -> std::result::Result<tonic::Response<super::GetFirstIndexResponse>, tonic::Status> 4658 - { 4659 - self.inner.ready().await.map_err(|e| { 4660 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4661 - })?; 5366 + ) -> std::result::Result< 5367 + tonic::Response<super::GetFirstIndexResponse>, 5368 + tonic::Status, 5369 + > { 5370 + self.inner 5371 + .ready() 5372 + .await 5373 + .map_err(|e| { 5374 + tonic::Status::unknown( 5375 + format!("Service was not ready: {}", e.into()), 5376 + ) 5377 + })?; 4662 5378 let codec = tonic::codec::ProstCodec::default(); 4663 5379 let path = http::uri::PathAndQuery::from_static( 4664 5380 "/rockbox.v1alpha1.PlaylistService/GetFirstIndex", 4665 5381 ); 4666 5382 let mut req = request.into_request(); 4667 - req.extensions_mut().insert(GrpcMethod::new( 4668 - "rockbox.v1alpha1.PlaylistService", 4669 - "GetFirstIndex", 4670 - )); 5383 + req.extensions_mut() 5384 + .insert( 5385 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "GetFirstIndex"), 5386 + ); 4671 5387 self.inner.unary(req, path, codec).await 4672 5388 } 4673 5389 pub async fn get_display_index( 4674 5390 &mut self, 4675 5391 request: impl tonic::IntoRequest<super::GetDisplayIndexRequest>, 4676 - ) -> std::result::Result<tonic::Response<super::GetDisplayIndexResponse>, tonic::Status> 4677 - { 4678 - self.inner.ready().await.map_err(|e| { 4679 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4680 - })?; 5392 + ) -> std::result::Result< 5393 + tonic::Response<super::GetDisplayIndexResponse>, 5394 + tonic::Status, 5395 + > { 5396 + self.inner 5397 + .ready() 5398 + .await 5399 + .map_err(|e| { 5400 + tonic::Status::unknown( 5401 + format!("Service was not ready: {}", e.into()), 5402 + ) 5403 + })?; 4681 5404 let codec = tonic::codec::ProstCodec::default(); 4682 5405 let path = http::uri::PathAndQuery::from_static( 4683 5406 "/rockbox.v1alpha1.PlaylistService/GetDisplayIndex", 4684 5407 ); 4685 5408 let mut req = request.into_request(); 4686 - req.extensions_mut().insert(GrpcMethod::new( 4687 - "rockbox.v1alpha1.PlaylistService", 4688 - "GetDisplayIndex", 4689 - )); 5409 + req.extensions_mut() 5410 + .insert( 5411 + GrpcMethod::new( 5412 + "rockbox.v1alpha1.PlaylistService", 5413 + "GetDisplayIndex", 5414 + ), 5415 + ); 4690 5416 self.inner.unary(req, path, codec).await 4691 5417 } 4692 5418 pub async fn amount( 4693 5419 &mut self, 4694 5420 request: impl tonic::IntoRequest<super::AmountRequest>, 4695 5421 ) -> std::result::Result<tonic::Response<super::AmountResponse>, tonic::Status> { 4696 - self.inner.ready().await.map_err(|e| { 4697 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4698 - })?; 5422 + self.inner 5423 + .ready() 5424 + .await 5425 + .map_err(|e| { 5426 + tonic::Status::unknown( 5427 + format!("Service was not ready: {}", e.into()), 5428 + ) 5429 + })?; 4699 5430 let codec = tonic::codec::ProstCodec::default(); 4700 - let path = 4701 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaylistService/Amount"); 5431 + let path = http::uri::PathAndQuery::from_static( 5432 + "/rockbox.v1alpha1.PlaylistService/Amount", 5433 + ); 4702 5434 let mut req = request.into_request(); 4703 - req.extensions_mut().insert(GrpcMethod::new( 4704 - "rockbox.v1alpha1.PlaylistService", 4705 - "Amount", 4706 - )); 5435 + req.extensions_mut() 5436 + .insert(GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "Amount")); 4707 5437 self.inner.unary(req, path, codec).await 4708 5438 } 4709 5439 pub async fn playlist_resume( 4710 5440 &mut self, 4711 5441 request: impl tonic::IntoRequest<super::PlaylistResumeRequest>, 4712 - ) -> std::result::Result<tonic::Response<super::PlaylistResumeResponse>, tonic::Status> 4713 - { 4714 - self.inner.ready().await.map_err(|e| { 4715 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4716 - })?; 5442 + ) -> std::result::Result< 5443 + tonic::Response<super::PlaylistResumeResponse>, 5444 + tonic::Status, 5445 + > { 5446 + self.inner 5447 + .ready() 5448 + .await 5449 + .map_err(|e| { 5450 + tonic::Status::unknown( 5451 + format!("Service was not ready: {}", e.into()), 5452 + ) 5453 + })?; 4717 5454 let codec = tonic::codec::ProstCodec::default(); 4718 5455 let path = http::uri::PathAndQuery::from_static( 4719 5456 "/rockbox.v1alpha1.PlaylistService/PlaylistResume", 4720 5457 ); 4721 5458 let mut req = request.into_request(); 4722 - req.extensions_mut().insert(GrpcMethod::new( 4723 - "rockbox.v1alpha1.PlaylistService", 4724 - "PlaylistResume", 4725 - )); 5459 + req.extensions_mut() 5460 + .insert( 5461 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "PlaylistResume"), 5462 + ); 4726 5463 self.inner.unary(req, path, codec).await 4727 5464 } 4728 5465 pub async fn resume_track( 4729 5466 &mut self, 4730 5467 request: impl tonic::IntoRequest<super::ResumeTrackRequest>, 4731 - ) -> std::result::Result<tonic::Response<super::ResumeTrackResponse>, tonic::Status> 4732 - { 4733 - self.inner.ready().await.map_err(|e| { 4734 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4735 - })?; 5468 + ) -> std::result::Result< 5469 + tonic::Response<super::ResumeTrackResponse>, 5470 + tonic::Status, 5471 + > { 5472 + self.inner 5473 + .ready() 5474 + .await 5475 + .map_err(|e| { 5476 + tonic::Status::unknown( 5477 + format!("Service was not ready: {}", e.into()), 5478 + ) 5479 + })?; 4736 5480 let codec = tonic::codec::ProstCodec::default(); 4737 5481 let path = http::uri::PathAndQuery::from_static( 4738 5482 "/rockbox.v1alpha1.PlaylistService/ResumeTrack", 4739 5483 ); 4740 5484 let mut req = request.into_request(); 4741 - req.extensions_mut().insert(GrpcMethod::new( 4742 - "rockbox.v1alpha1.PlaylistService", 4743 - "ResumeTrack", 4744 - )); 5485 + req.extensions_mut() 5486 + .insert( 5487 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "ResumeTrack"), 5488 + ); 4745 5489 self.inner.unary(req, path, codec).await 4746 5490 } 4747 5491 pub async fn set_modified( 4748 5492 &mut self, 4749 5493 request: impl tonic::IntoRequest<super::SetModifiedRequest>, 4750 - ) -> std::result::Result<tonic::Response<super::SetModifiedResponse>, tonic::Status> 4751 - { 4752 - self.inner.ready().await.map_err(|e| { 4753 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4754 - })?; 5494 + ) -> std::result::Result< 5495 + tonic::Response<super::SetModifiedResponse>, 5496 + tonic::Status, 5497 + > { 5498 + self.inner 5499 + .ready() 5500 + .await 5501 + .map_err(|e| { 5502 + tonic::Status::unknown( 5503 + format!("Service was not ready: {}", e.into()), 5504 + ) 5505 + })?; 4755 5506 let codec = tonic::codec::ProstCodec::default(); 4756 5507 let path = http::uri::PathAndQuery::from_static( 4757 5508 "/rockbox.v1alpha1.PlaylistService/SetModified", 4758 5509 ); 4759 5510 let mut req = request.into_request(); 4760 - req.extensions_mut().insert(GrpcMethod::new( 4761 - "rockbox.v1alpha1.PlaylistService", 4762 - "SetModified", 4763 - )); 5511 + req.extensions_mut() 5512 + .insert( 5513 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "SetModified"), 5514 + ); 4764 5515 self.inner.unary(req, path, codec).await 4765 5516 } 4766 5517 pub async fn start( 4767 5518 &mut self, 4768 5519 request: impl tonic::IntoRequest<super::StartRequest>, 4769 5520 ) -> std::result::Result<tonic::Response<super::StartResponse>, tonic::Status> { 4770 - self.inner.ready().await.map_err(|e| { 4771 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4772 - })?; 5521 + self.inner 5522 + .ready() 5523 + .await 5524 + .map_err(|e| { 5525 + tonic::Status::unknown( 5526 + format!("Service was not ready: {}", e.into()), 5527 + ) 5528 + })?; 4773 5529 let codec = tonic::codec::ProstCodec::default(); 4774 - let path = 4775 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaylistService/Start"); 5530 + let path = http::uri::PathAndQuery::from_static( 5531 + "/rockbox.v1alpha1.PlaylistService/Start", 5532 + ); 4776 5533 let mut req = request.into_request(); 4777 5534 req.extensions_mut() 4778 5535 .insert(GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "Start")); ··· 4782 5539 &mut self, 4783 5540 request: impl tonic::IntoRequest<super::SyncRequest>, 4784 5541 ) -> std::result::Result<tonic::Response<super::SyncResponse>, tonic::Status> { 4785 - self.inner.ready().await.map_err(|e| { 4786 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4787 - })?; 5542 + self.inner 5543 + .ready() 5544 + .await 5545 + .map_err(|e| { 5546 + tonic::Status::unknown( 5547 + format!("Service was not ready: {}", e.into()), 5548 + ) 5549 + })?; 4788 5550 let codec = tonic::codec::ProstCodec::default(); 4789 - let path = 4790 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.PlaylistService/Sync"); 5551 + let path = http::uri::PathAndQuery::from_static( 5552 + "/rockbox.v1alpha1.PlaylistService/Sync", 5553 + ); 4791 5554 let mut req = request.into_request(); 4792 5555 req.extensions_mut() 4793 5556 .insert(GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "Sync")); ··· 4796 5559 pub async fn remove_all_tracks( 4797 5560 &mut self, 4798 5561 request: impl tonic::IntoRequest<super::RemoveAllTracksRequest>, 4799 - ) -> std::result::Result<tonic::Response<super::RemoveAllTracksResponse>, tonic::Status> 4800 - { 4801 - self.inner.ready().await.map_err(|e| { 4802 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4803 - })?; 5562 + ) -> std::result::Result< 5563 + tonic::Response<super::RemoveAllTracksResponse>, 5564 + tonic::Status, 5565 + > { 5566 + self.inner 5567 + .ready() 5568 + .await 5569 + .map_err(|e| { 5570 + tonic::Status::unknown( 5571 + format!("Service was not ready: {}", e.into()), 5572 + ) 5573 + })?; 4804 5574 let codec = tonic::codec::ProstCodec::default(); 4805 5575 let path = http::uri::PathAndQuery::from_static( 4806 5576 "/rockbox.v1alpha1.PlaylistService/RemoveAllTracks", 4807 5577 ); 4808 5578 let mut req = request.into_request(); 4809 - req.extensions_mut().insert(GrpcMethod::new( 4810 - "rockbox.v1alpha1.PlaylistService", 4811 - "RemoveAllTracks", 4812 - )); 5579 + req.extensions_mut() 5580 + .insert( 5581 + GrpcMethod::new( 5582 + "rockbox.v1alpha1.PlaylistService", 5583 + "RemoveAllTracks", 5584 + ), 5585 + ); 4813 5586 self.inner.unary(req, path, codec).await 4814 5587 } 4815 5588 pub async fn remove_tracks( 4816 5589 &mut self, 4817 5590 request: impl tonic::IntoRequest<super::RemoveTracksRequest>, 4818 - ) -> std::result::Result<tonic::Response<super::RemoveTracksResponse>, tonic::Status> 4819 - { 4820 - self.inner.ready().await.map_err(|e| { 4821 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4822 - })?; 5591 + ) -> std::result::Result< 5592 + tonic::Response<super::RemoveTracksResponse>, 5593 + tonic::Status, 5594 + > { 5595 + self.inner 5596 + .ready() 5597 + .await 5598 + .map_err(|e| { 5599 + tonic::Status::unknown( 5600 + format!("Service was not ready: {}", e.into()), 5601 + ) 5602 + })?; 4823 5603 let codec = tonic::codec::ProstCodec::default(); 4824 5604 let path = http::uri::PathAndQuery::from_static( 4825 5605 "/rockbox.v1alpha1.PlaylistService/RemoveTracks", 4826 5606 ); 4827 5607 let mut req = request.into_request(); 4828 - req.extensions_mut().insert(GrpcMethod::new( 4829 - "rockbox.v1alpha1.PlaylistService", 4830 - "RemoveTracks", 4831 - )); 5608 + req.extensions_mut() 5609 + .insert( 5610 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "RemoveTracks"), 5611 + ); 4832 5612 self.inner.unary(req, path, codec).await 4833 5613 } 4834 5614 pub async fn create_playlist( 4835 5615 &mut self, 4836 5616 request: impl tonic::IntoRequest<super::CreatePlaylistRequest>, 4837 - ) -> std::result::Result<tonic::Response<super::CreatePlaylistResponse>, tonic::Status> 4838 - { 4839 - self.inner.ready().await.map_err(|e| { 4840 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4841 - })?; 5617 + ) -> std::result::Result< 5618 + tonic::Response<super::CreatePlaylistResponse>, 5619 + tonic::Status, 5620 + > { 5621 + self.inner 5622 + .ready() 5623 + .await 5624 + .map_err(|e| { 5625 + tonic::Status::unknown( 5626 + format!("Service was not ready: {}", e.into()), 5627 + ) 5628 + })?; 4842 5629 let codec = tonic::codec::ProstCodec::default(); 4843 5630 let path = http::uri::PathAndQuery::from_static( 4844 5631 "/rockbox.v1alpha1.PlaylistService/CreatePlaylist", 4845 5632 ); 4846 5633 let mut req = request.into_request(); 4847 - req.extensions_mut().insert(GrpcMethod::new( 4848 - "rockbox.v1alpha1.PlaylistService", 4849 - "CreatePlaylist", 4850 - )); 5634 + req.extensions_mut() 5635 + .insert( 5636 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "CreatePlaylist"), 5637 + ); 4851 5638 self.inner.unary(req, path, codec).await 4852 5639 } 4853 5640 pub async fn insert_tracks( 4854 5641 &mut self, 4855 5642 request: impl tonic::IntoRequest<super::InsertTracksRequest>, 4856 - ) -> std::result::Result<tonic::Response<super::InsertTracksResponse>, tonic::Status> 4857 - { 4858 - self.inner.ready().await.map_err(|e| { 4859 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4860 - })?; 5643 + ) -> std::result::Result< 5644 + tonic::Response<super::InsertTracksResponse>, 5645 + tonic::Status, 5646 + > { 5647 + self.inner 5648 + .ready() 5649 + .await 5650 + .map_err(|e| { 5651 + tonic::Status::unknown( 5652 + format!("Service was not ready: {}", e.into()), 5653 + ) 5654 + })?; 4861 5655 let codec = tonic::codec::ProstCodec::default(); 4862 5656 let path = http::uri::PathAndQuery::from_static( 4863 5657 "/rockbox.v1alpha1.PlaylistService/InsertTracks", 4864 5658 ); 4865 5659 let mut req = request.into_request(); 4866 - req.extensions_mut().insert(GrpcMethod::new( 4867 - "rockbox.v1alpha1.PlaylistService", 4868 - "InsertTracks", 4869 - )); 5660 + req.extensions_mut() 5661 + .insert( 5662 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "InsertTracks"), 5663 + ); 4870 5664 self.inner.unary(req, path, codec).await 4871 5665 } 4872 5666 pub async fn insert_directory( 4873 5667 &mut self, 4874 5668 request: impl tonic::IntoRequest<super::InsertDirectoryRequest>, 4875 - ) -> std::result::Result<tonic::Response<super::InsertDirectoryResponse>, tonic::Status> 4876 - { 4877 - self.inner.ready().await.map_err(|e| { 4878 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4879 - })?; 5669 + ) -> std::result::Result< 5670 + tonic::Response<super::InsertDirectoryResponse>, 5671 + tonic::Status, 5672 + > { 5673 + self.inner 5674 + .ready() 5675 + .await 5676 + .map_err(|e| { 5677 + tonic::Status::unknown( 5678 + format!("Service was not ready: {}", e.into()), 5679 + ) 5680 + })?; 4880 5681 let codec = tonic::codec::ProstCodec::default(); 4881 5682 let path = http::uri::PathAndQuery::from_static( 4882 5683 "/rockbox.v1alpha1.PlaylistService/InsertDirectory", 4883 5684 ); 4884 5685 let mut req = request.into_request(); 4885 - req.extensions_mut().insert(GrpcMethod::new( 4886 - "rockbox.v1alpha1.PlaylistService", 4887 - "InsertDirectory", 4888 - )); 5686 + req.extensions_mut() 5687 + .insert( 5688 + GrpcMethod::new( 5689 + "rockbox.v1alpha1.PlaylistService", 5690 + "InsertDirectory", 5691 + ), 5692 + ); 4889 5693 self.inner.unary(req, path, codec).await 4890 5694 } 4891 5695 pub async fn insert_playlist( 4892 5696 &mut self, 4893 5697 request: impl tonic::IntoRequest<super::InsertPlaylistRequest>, 4894 - ) -> std::result::Result<tonic::Response<super::InsertPlaylistResponse>, tonic::Status> 4895 - { 4896 - self.inner.ready().await.map_err(|e| { 4897 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4898 - })?; 5698 + ) -> std::result::Result< 5699 + tonic::Response<super::InsertPlaylistResponse>, 5700 + tonic::Status, 5701 + > { 5702 + self.inner 5703 + .ready() 5704 + .await 5705 + .map_err(|e| { 5706 + tonic::Status::unknown( 5707 + format!("Service was not ready: {}", e.into()), 5708 + ) 5709 + })?; 4899 5710 let codec = tonic::codec::ProstCodec::default(); 4900 5711 let path = http::uri::PathAndQuery::from_static( 4901 5712 "/rockbox.v1alpha1.PlaylistService/InsertPlaylist", 4902 5713 ); 4903 5714 let mut req = request.into_request(); 4904 - req.extensions_mut().insert(GrpcMethod::new( 4905 - "rockbox.v1alpha1.PlaylistService", 4906 - "InsertPlaylist", 4907 - )); 5715 + req.extensions_mut() 5716 + .insert( 5717 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "InsertPlaylist"), 5718 + ); 4908 5719 self.inner.unary(req, path, codec).await 4909 5720 } 4910 5721 pub async fn insert_album( 4911 5722 &mut self, 4912 5723 request: impl tonic::IntoRequest<super::InsertAlbumRequest>, 4913 - ) -> std::result::Result<tonic::Response<super::InsertAlbumResponse>, tonic::Status> 4914 - { 4915 - self.inner.ready().await.map_err(|e| { 4916 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4917 - })?; 5724 + ) -> std::result::Result< 5725 + tonic::Response<super::InsertAlbumResponse>, 5726 + tonic::Status, 5727 + > { 5728 + self.inner 5729 + .ready() 5730 + .await 5731 + .map_err(|e| { 5732 + tonic::Status::unknown( 5733 + format!("Service was not ready: {}", e.into()), 5734 + ) 5735 + })?; 4918 5736 let codec = tonic::codec::ProstCodec::default(); 4919 5737 let path = http::uri::PathAndQuery::from_static( 4920 5738 "/rockbox.v1alpha1.PlaylistService/InsertAlbum", 4921 5739 ); 4922 5740 let mut req = request.into_request(); 4923 - req.extensions_mut().insert(GrpcMethod::new( 4924 - "rockbox.v1alpha1.PlaylistService", 4925 - "InsertAlbum", 4926 - )); 5741 + req.extensions_mut() 5742 + .insert( 5743 + GrpcMethod::new("rockbox.v1alpha1.PlaylistService", "InsertAlbum"), 5744 + ); 4927 5745 self.inner.unary(req, path, codec).await 4928 5746 } 4929 5747 pub async fn insert_artist_tracks( 4930 5748 &mut self, 4931 5749 request: impl tonic::IntoRequest<super::InsertArtistTracksRequest>, 4932 - ) -> std::result::Result<tonic::Response<super::InsertArtistTracksResponse>, tonic::Status> 4933 - { 4934 - self.inner.ready().await.map_err(|e| { 4935 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4936 - })?; 5750 + ) -> std::result::Result< 5751 + tonic::Response<super::InsertArtistTracksResponse>, 5752 + tonic::Status, 5753 + > { 5754 + self.inner 5755 + .ready() 5756 + .await 5757 + .map_err(|e| { 5758 + tonic::Status::unknown( 5759 + format!("Service was not ready: {}", e.into()), 5760 + ) 5761 + })?; 4937 5762 let codec = tonic::codec::ProstCodec::default(); 4938 5763 let path = http::uri::PathAndQuery::from_static( 4939 5764 "/rockbox.v1alpha1.PlaylistService/InsertArtistTracks", 4940 5765 ); 4941 5766 let mut req = request.into_request(); 4942 - req.extensions_mut().insert(GrpcMethod::new( 4943 - "rockbox.v1alpha1.PlaylistService", 4944 - "InsertArtistTracks", 4945 - )); 5767 + req.extensions_mut() 5768 + .insert( 5769 + GrpcMethod::new( 5770 + "rockbox.v1alpha1.PlaylistService", 5771 + "InsertArtistTracks", 5772 + ), 5773 + ); 4946 5774 self.inner.unary(req, path, codec).await 4947 5775 } 4948 5776 pub async fn shuffle_playlist( 4949 5777 &mut self, 4950 5778 request: impl tonic::IntoRequest<super::ShufflePlaylistRequest>, 4951 - ) -> std::result::Result<tonic::Response<super::ShufflePlaylistResponse>, tonic::Status> 4952 - { 4953 - self.inner.ready().await.map_err(|e| { 4954 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 4955 - })?; 5779 + ) -> std::result::Result< 5780 + tonic::Response<super::ShufflePlaylistResponse>, 5781 + tonic::Status, 5782 + > { 5783 + self.inner 5784 + .ready() 5785 + .await 5786 + .map_err(|e| { 5787 + tonic::Status::unknown( 5788 + format!("Service was not ready: {}", e.into()), 5789 + ) 5790 + })?; 4956 5791 let codec = tonic::codec::ProstCodec::default(); 4957 5792 let path = http::uri::PathAndQuery::from_static( 4958 5793 "/rockbox.v1alpha1.PlaylistService/ShufflePlaylist", 4959 5794 ); 4960 5795 let mut req = request.into_request(); 4961 - req.extensions_mut().insert(GrpcMethod::new( 4962 - "rockbox.v1alpha1.PlaylistService", 4963 - "ShufflePlaylist", 4964 - )); 5796 + req.extensions_mut() 5797 + .insert( 5798 + GrpcMethod::new( 5799 + "rockbox.v1alpha1.PlaylistService", 5800 + "ShufflePlaylist", 5801 + ), 5802 + ); 4965 5803 self.inner.unary(req, path, codec).await 4966 5804 } 4967 5805 } ··· 4973 5811 dead_code, 4974 5812 missing_docs, 4975 5813 clippy::wildcard_imports, 4976 - clippy::let_unit_value 5814 + clippy::let_unit_value, 4977 5815 )] 4978 5816 use tonic::codegen::*; 4979 5817 /// Generated trait containing gRPC methods that should be implemented for use with PlaylistServiceServer. ··· 4982 5820 async fn get_current( 4983 5821 &self, 4984 5822 request: tonic::Request<super::GetCurrentRequest>, 4985 - ) -> std::result::Result<tonic::Response<super::GetCurrentResponse>, tonic::Status>; 5823 + ) -> std::result::Result< 5824 + tonic::Response<super::GetCurrentResponse>, 5825 + tonic::Status, 5826 + >; 4986 5827 async fn get_resume_info( 4987 5828 &self, 4988 5829 request: tonic::Request<super::GetResumeInfoRequest>, 4989 - ) -> std::result::Result<tonic::Response<super::GetResumeInfoResponse>, tonic::Status>; 5830 + ) -> std::result::Result< 5831 + tonic::Response<super::GetResumeInfoResponse>, 5832 + tonic::Status, 5833 + >; 4990 5834 async fn get_track_info( 4991 5835 &self, 4992 5836 request: tonic::Request<super::GetTrackInfoRequest>, 4993 - ) -> std::result::Result<tonic::Response<super::GetTrackInfoResponse>, tonic::Status>; 5837 + ) -> std::result::Result< 5838 + tonic::Response<super::GetTrackInfoResponse>, 5839 + tonic::Status, 5840 + >; 4994 5841 async fn get_first_index( 4995 5842 &self, 4996 5843 request: tonic::Request<super::GetFirstIndexRequest>, 4997 - ) -> std::result::Result<tonic::Response<super::GetFirstIndexResponse>, tonic::Status>; 5844 + ) -> std::result::Result< 5845 + tonic::Response<super::GetFirstIndexResponse>, 5846 + tonic::Status, 5847 + >; 4998 5848 async fn get_display_index( 4999 5849 &self, 5000 5850 request: tonic::Request<super::GetDisplayIndexRequest>, 5001 - ) -> std::result::Result<tonic::Response<super::GetDisplayIndexResponse>, tonic::Status>; 5851 + ) -> std::result::Result< 5852 + tonic::Response<super::GetDisplayIndexResponse>, 5853 + tonic::Status, 5854 + >; 5002 5855 async fn amount( 5003 5856 &self, 5004 5857 request: tonic::Request<super::AmountRequest>, ··· 5006 5859 async fn playlist_resume( 5007 5860 &self, 5008 5861 request: tonic::Request<super::PlaylistResumeRequest>, 5009 - ) -> std::result::Result<tonic::Response<super::PlaylistResumeResponse>, tonic::Status>; 5862 + ) -> std::result::Result< 5863 + tonic::Response<super::PlaylistResumeResponse>, 5864 + tonic::Status, 5865 + >; 5010 5866 async fn resume_track( 5011 5867 &self, 5012 5868 request: tonic::Request<super::ResumeTrackRequest>, 5013 - ) -> std::result::Result<tonic::Response<super::ResumeTrackResponse>, tonic::Status>; 5869 + ) -> std::result::Result< 5870 + tonic::Response<super::ResumeTrackResponse>, 5871 + tonic::Status, 5872 + >; 5014 5873 async fn set_modified( 5015 5874 &self, 5016 5875 request: tonic::Request<super::SetModifiedRequest>, 5017 - ) -> std::result::Result<tonic::Response<super::SetModifiedResponse>, tonic::Status>; 5876 + ) -> std::result::Result< 5877 + tonic::Response<super::SetModifiedResponse>, 5878 + tonic::Status, 5879 + >; 5018 5880 async fn start( 5019 5881 &self, 5020 5882 request: tonic::Request<super::StartRequest>, ··· 5026 5888 async fn remove_all_tracks( 5027 5889 &self, 5028 5890 request: tonic::Request<super::RemoveAllTracksRequest>, 5029 - ) -> std::result::Result<tonic::Response<super::RemoveAllTracksResponse>, tonic::Status>; 5891 + ) -> std::result::Result< 5892 + tonic::Response<super::RemoveAllTracksResponse>, 5893 + tonic::Status, 5894 + >; 5030 5895 async fn remove_tracks( 5031 5896 &self, 5032 5897 request: tonic::Request<super::RemoveTracksRequest>, 5033 - ) -> std::result::Result<tonic::Response<super::RemoveTracksResponse>, tonic::Status>; 5898 + ) -> std::result::Result< 5899 + tonic::Response<super::RemoveTracksResponse>, 5900 + tonic::Status, 5901 + >; 5034 5902 async fn create_playlist( 5035 5903 &self, 5036 5904 request: tonic::Request<super::CreatePlaylistRequest>, 5037 - ) -> std::result::Result<tonic::Response<super::CreatePlaylistResponse>, tonic::Status>; 5905 + ) -> std::result::Result< 5906 + tonic::Response<super::CreatePlaylistResponse>, 5907 + tonic::Status, 5908 + >; 5038 5909 async fn insert_tracks( 5039 5910 &self, 5040 5911 request: tonic::Request<super::InsertTracksRequest>, 5041 - ) -> std::result::Result<tonic::Response<super::InsertTracksResponse>, tonic::Status>; 5912 + ) -> std::result::Result< 5913 + tonic::Response<super::InsertTracksResponse>, 5914 + tonic::Status, 5915 + >; 5042 5916 async fn insert_directory( 5043 5917 &self, 5044 5918 request: tonic::Request<super::InsertDirectoryRequest>, 5045 - ) -> std::result::Result<tonic::Response<super::InsertDirectoryResponse>, tonic::Status>; 5919 + ) -> std::result::Result< 5920 + tonic::Response<super::InsertDirectoryResponse>, 5921 + tonic::Status, 5922 + >; 5046 5923 async fn insert_playlist( 5047 5924 &self, 5048 5925 request: tonic::Request<super::InsertPlaylistRequest>, 5049 - ) -> std::result::Result<tonic::Response<super::InsertPlaylistResponse>, tonic::Status>; 5926 + ) -> std::result::Result< 5927 + tonic::Response<super::InsertPlaylistResponse>, 5928 + tonic::Status, 5929 + >; 5050 5930 async fn insert_album( 5051 5931 &self, 5052 5932 request: tonic::Request<super::InsertAlbumRequest>, 5053 - ) -> std::result::Result<tonic::Response<super::InsertAlbumResponse>, tonic::Status>; 5933 + ) -> std::result::Result< 5934 + tonic::Response<super::InsertAlbumResponse>, 5935 + tonic::Status, 5936 + >; 5054 5937 async fn insert_artist_tracks( 5055 5938 &self, 5056 5939 request: tonic::Request<super::InsertArtistTracksRequest>, 5057 - ) -> std::result::Result<tonic::Response<super::InsertArtistTracksResponse>, tonic::Status>; 5940 + ) -> std::result::Result< 5941 + tonic::Response<super::InsertArtistTracksResponse>, 5942 + tonic::Status, 5943 + >; 5058 5944 async fn shuffle_playlist( 5059 5945 &self, 5060 5946 request: tonic::Request<super::ShufflePlaylistRequest>, 5061 - ) -> std::result::Result<tonic::Response<super::ShufflePlaylistResponse>, tonic::Status>; 5947 + ) -> std::result::Result< 5948 + tonic::Response<super::ShufflePlaylistResponse>, 5949 + tonic::Status, 5950 + >; 5062 5951 } 5063 5952 #[derive(Debug)] 5064 5953 pub struct PlaylistServiceServer<T> { ··· 5081 5970 max_encoding_message_size: None, 5082 5971 } 5083 5972 } 5084 - pub fn with_interceptor<F>(inner: T, interceptor: F) -> InterceptedService<Self, F> 5973 + pub fn with_interceptor<F>( 5974 + inner: T, 5975 + interceptor: F, 5976 + ) -> InterceptedService<Self, F> 5085 5977 where 5086 5978 F: tonic::service::Interceptor, 5087 5979 { ··· 5136 6028 "/rockbox.v1alpha1.PlaylistService/GetCurrent" => { 5137 6029 #[allow(non_camel_case_types)] 5138 6030 struct GetCurrentSvc<T: PlaylistService>(pub Arc<T>); 5139 - impl<T: PlaylistService> tonic::server::UnaryService<super::GetCurrentRequest> 5140 - for GetCurrentSvc<T> 5141 - { 6031 + impl< 6032 + T: PlaylistService, 6033 + > tonic::server::UnaryService<super::GetCurrentRequest> 6034 + for GetCurrentSvc<T> { 5142 6035 type Response = super::GetCurrentResponse; 5143 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6036 + type Future = BoxFuture< 6037 + tonic::Response<Self::Response>, 6038 + tonic::Status, 6039 + >; 5144 6040 fn call( 5145 6041 &mut self, 5146 6042 request: tonic::Request<super::GetCurrentRequest>, ··· 5177 6073 "/rockbox.v1alpha1.PlaylistService/GetResumeInfo" => { 5178 6074 #[allow(non_camel_case_types)] 5179 6075 struct GetResumeInfoSvc<T: PlaylistService>(pub Arc<T>); 5180 - impl<T: PlaylistService> 5181 - tonic::server::UnaryService<super::GetResumeInfoRequest> 5182 - for GetResumeInfoSvc<T> 5183 - { 6076 + impl< 6077 + T: PlaylistService, 6078 + > tonic::server::UnaryService<super::GetResumeInfoRequest> 6079 + for GetResumeInfoSvc<T> { 5184 6080 type Response = super::GetResumeInfoResponse; 5185 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6081 + type Future = BoxFuture< 6082 + tonic::Response<Self::Response>, 6083 + tonic::Status, 6084 + >; 5186 6085 fn call( 5187 6086 &mut self, 5188 6087 request: tonic::Request<super::GetResumeInfoRequest>, 5189 6088 ) -> Self::Future { 5190 6089 let inner = Arc::clone(&self.0); 5191 6090 let fut = async move { 5192 - <T as PlaylistService>::get_resume_info(&inner, request).await 6091 + <T as PlaylistService>::get_resume_info(&inner, request) 6092 + .await 5193 6093 }; 5194 6094 Box::pin(fut) 5195 6095 } ··· 5219 6119 "/rockbox.v1alpha1.PlaylistService/GetTrackInfo" => { 5220 6120 #[allow(non_camel_case_types)] 5221 6121 struct GetTrackInfoSvc<T: PlaylistService>(pub Arc<T>); 5222 - impl<T: PlaylistService> tonic::server::UnaryService<super::GetTrackInfoRequest> 5223 - for GetTrackInfoSvc<T> 5224 - { 6122 + impl< 6123 + T: PlaylistService, 6124 + > tonic::server::UnaryService<super::GetTrackInfoRequest> 6125 + for GetTrackInfoSvc<T> { 5225 6126 type Response = super::GetTrackInfoResponse; 5226 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6127 + type Future = BoxFuture< 6128 + tonic::Response<Self::Response>, 6129 + tonic::Status, 6130 + >; 5227 6131 fn call( 5228 6132 &mut self, 5229 6133 request: tonic::Request<super::GetTrackInfoRequest>, 5230 6134 ) -> Self::Future { 5231 6135 let inner = Arc::clone(&self.0); 5232 6136 let fut = async move { 5233 - <T as PlaylistService>::get_track_info(&inner, request).await 6137 + <T as PlaylistService>::get_track_info(&inner, request) 6138 + .await 5234 6139 }; 5235 6140 Box::pin(fut) 5236 6141 } ··· 5260 6165 "/rockbox.v1alpha1.PlaylistService/GetFirstIndex" => { 5261 6166 #[allow(non_camel_case_types)] 5262 6167 struct GetFirstIndexSvc<T: PlaylistService>(pub Arc<T>); 5263 - impl<T: PlaylistService> 5264 - tonic::server::UnaryService<super::GetFirstIndexRequest> 5265 - for GetFirstIndexSvc<T> 5266 - { 6168 + impl< 6169 + T: PlaylistService, 6170 + > tonic::server::UnaryService<super::GetFirstIndexRequest> 6171 + for GetFirstIndexSvc<T> { 5267 6172 type Response = super::GetFirstIndexResponse; 5268 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6173 + type Future = BoxFuture< 6174 + tonic::Response<Self::Response>, 6175 + tonic::Status, 6176 + >; 5269 6177 fn call( 5270 6178 &mut self, 5271 6179 request: tonic::Request<super::GetFirstIndexRequest>, 5272 6180 ) -> Self::Future { 5273 6181 let inner = Arc::clone(&self.0); 5274 6182 let fut = async move { 5275 - <T as PlaylistService>::get_first_index(&inner, request).await 6183 + <T as PlaylistService>::get_first_index(&inner, request) 6184 + .await 5276 6185 }; 5277 6186 Box::pin(fut) 5278 6187 } ··· 5302 6211 "/rockbox.v1alpha1.PlaylistService/GetDisplayIndex" => { 5303 6212 #[allow(non_camel_case_types)] 5304 6213 struct GetDisplayIndexSvc<T: PlaylistService>(pub Arc<T>); 5305 - impl<T: PlaylistService> 5306 - tonic::server::UnaryService<super::GetDisplayIndexRequest> 5307 - for GetDisplayIndexSvc<T> 5308 - { 6214 + impl< 6215 + T: PlaylistService, 6216 + > tonic::server::UnaryService<super::GetDisplayIndexRequest> 6217 + for GetDisplayIndexSvc<T> { 5309 6218 type Response = super::GetDisplayIndexResponse; 5310 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6219 + type Future = BoxFuture< 6220 + tonic::Response<Self::Response>, 6221 + tonic::Status, 6222 + >; 5311 6223 fn call( 5312 6224 &mut self, 5313 6225 request: tonic::Request<super::GetDisplayIndexRequest>, 5314 6226 ) -> Self::Future { 5315 6227 let inner = Arc::clone(&self.0); 5316 6228 let fut = async move { 5317 - <T as PlaylistService>::get_display_index(&inner, request).await 6229 + <T as PlaylistService>::get_display_index(&inner, request) 6230 + .await 5318 6231 }; 5319 6232 Box::pin(fut) 5320 6233 } ··· 5344 6257 "/rockbox.v1alpha1.PlaylistService/Amount" => { 5345 6258 #[allow(non_camel_case_types)] 5346 6259 struct AmountSvc<T: PlaylistService>(pub Arc<T>); 5347 - impl<T: PlaylistService> tonic::server::UnaryService<super::AmountRequest> for AmountSvc<T> { 6260 + impl< 6261 + T: PlaylistService, 6262 + > tonic::server::UnaryService<super::AmountRequest> 6263 + for AmountSvc<T> { 5348 6264 type Response = super::AmountResponse; 5349 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6265 + type Future = BoxFuture< 6266 + tonic::Response<Self::Response>, 6267 + tonic::Status, 6268 + >; 5350 6269 fn call( 5351 6270 &mut self, 5352 6271 request: tonic::Request<super::AmountRequest>, ··· 5383 6302 "/rockbox.v1alpha1.PlaylistService/PlaylistResume" => { 5384 6303 #[allow(non_camel_case_types)] 5385 6304 struct PlaylistResumeSvc<T: PlaylistService>(pub Arc<T>); 5386 - impl<T: PlaylistService> 5387 - tonic::server::UnaryService<super::PlaylistResumeRequest> 5388 - for PlaylistResumeSvc<T> 5389 - { 6305 + impl< 6306 + T: PlaylistService, 6307 + > tonic::server::UnaryService<super::PlaylistResumeRequest> 6308 + for PlaylistResumeSvc<T> { 5390 6309 type Response = super::PlaylistResumeResponse; 5391 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6310 + type Future = BoxFuture< 6311 + tonic::Response<Self::Response>, 6312 + tonic::Status, 6313 + >; 5392 6314 fn call( 5393 6315 &mut self, 5394 6316 request: tonic::Request<super::PlaylistResumeRequest>, 5395 6317 ) -> Self::Future { 5396 6318 let inner = Arc::clone(&self.0); 5397 6319 let fut = async move { 5398 - <T as PlaylistService>::playlist_resume(&inner, request).await 6320 + <T as PlaylistService>::playlist_resume(&inner, request) 6321 + .await 5399 6322 }; 5400 6323 Box::pin(fut) 5401 6324 } ··· 5425 6348 "/rockbox.v1alpha1.PlaylistService/ResumeTrack" => { 5426 6349 #[allow(non_camel_case_types)] 5427 6350 struct ResumeTrackSvc<T: PlaylistService>(pub Arc<T>); 5428 - impl<T: PlaylistService> tonic::server::UnaryService<super::ResumeTrackRequest> 5429 - for ResumeTrackSvc<T> 5430 - { 6351 + impl< 6352 + T: PlaylistService, 6353 + > tonic::server::UnaryService<super::ResumeTrackRequest> 6354 + for ResumeTrackSvc<T> { 5431 6355 type Response = super::ResumeTrackResponse; 5432 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6356 + type Future = BoxFuture< 6357 + tonic::Response<Self::Response>, 6358 + tonic::Status, 6359 + >; 5433 6360 fn call( 5434 6361 &mut self, 5435 6362 request: tonic::Request<super::ResumeTrackRequest>, ··· 5466 6393 "/rockbox.v1alpha1.PlaylistService/SetModified" => { 5467 6394 #[allow(non_camel_case_types)] 5468 6395 struct SetModifiedSvc<T: PlaylistService>(pub Arc<T>); 5469 - impl<T: PlaylistService> tonic::server::UnaryService<super::SetModifiedRequest> 5470 - for SetModifiedSvc<T> 5471 - { 6396 + impl< 6397 + T: PlaylistService, 6398 + > tonic::server::UnaryService<super::SetModifiedRequest> 6399 + for SetModifiedSvc<T> { 5472 6400 type Response = super::SetModifiedResponse; 5473 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6401 + type Future = BoxFuture< 6402 + tonic::Response<Self::Response>, 6403 + tonic::Status, 6404 + >; 5474 6405 fn call( 5475 6406 &mut self, 5476 6407 request: tonic::Request<super::SetModifiedRequest>, ··· 5507 6438 "/rockbox.v1alpha1.PlaylistService/Start" => { 5508 6439 #[allow(non_camel_case_types)] 5509 6440 struct StartSvc<T: PlaylistService>(pub Arc<T>); 5510 - impl<T: PlaylistService> tonic::server::UnaryService<super::StartRequest> for StartSvc<T> { 6441 + impl< 6442 + T: PlaylistService, 6443 + > tonic::server::UnaryService<super::StartRequest> for StartSvc<T> { 5511 6444 type Response = super::StartResponse; 5512 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6445 + type Future = BoxFuture< 6446 + tonic::Response<Self::Response>, 6447 + tonic::Status, 6448 + >; 5513 6449 fn call( 5514 6450 &mut self, 5515 6451 request: tonic::Request<super::StartRequest>, 5516 6452 ) -> Self::Future { 5517 6453 let inner = Arc::clone(&self.0); 5518 - let fut = 5519 - async move { <T as PlaylistService>::start(&inner, request).await }; 6454 + let fut = async move { 6455 + <T as PlaylistService>::start(&inner, request).await 6456 + }; 5520 6457 Box::pin(fut) 5521 6458 } 5522 6459 } ··· 5545 6482 "/rockbox.v1alpha1.PlaylistService/Sync" => { 5546 6483 #[allow(non_camel_case_types)] 5547 6484 struct SyncSvc<T: PlaylistService>(pub Arc<T>); 5548 - impl<T: PlaylistService> tonic::server::UnaryService<super::SyncRequest> for SyncSvc<T> { 6485 + impl< 6486 + T: PlaylistService, 6487 + > tonic::server::UnaryService<super::SyncRequest> for SyncSvc<T> { 5549 6488 type Response = super::SyncResponse; 5550 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6489 + type Future = BoxFuture< 6490 + tonic::Response<Self::Response>, 6491 + tonic::Status, 6492 + >; 5551 6493 fn call( 5552 6494 &mut self, 5553 6495 request: tonic::Request<super::SyncRequest>, 5554 6496 ) -> Self::Future { 5555 6497 let inner = Arc::clone(&self.0); 5556 - let fut = 5557 - async move { <T as PlaylistService>::sync(&inner, request).await }; 6498 + let fut = async move { 6499 + <T as PlaylistService>::sync(&inner, request).await 6500 + }; 5558 6501 Box::pin(fut) 5559 6502 } 5560 6503 } ··· 5583 6526 "/rockbox.v1alpha1.PlaylistService/RemoveAllTracks" => { 5584 6527 #[allow(non_camel_case_types)] 5585 6528 struct RemoveAllTracksSvc<T: PlaylistService>(pub Arc<T>); 5586 - impl<T: PlaylistService> 5587 - tonic::server::UnaryService<super::RemoveAllTracksRequest> 5588 - for RemoveAllTracksSvc<T> 5589 - { 6529 + impl< 6530 + T: PlaylistService, 6531 + > tonic::server::UnaryService<super::RemoveAllTracksRequest> 6532 + for RemoveAllTracksSvc<T> { 5590 6533 type Response = super::RemoveAllTracksResponse; 5591 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6534 + type Future = BoxFuture< 6535 + tonic::Response<Self::Response>, 6536 + tonic::Status, 6537 + >; 5592 6538 fn call( 5593 6539 &mut self, 5594 6540 request: tonic::Request<super::RemoveAllTracksRequest>, 5595 6541 ) -> Self::Future { 5596 6542 let inner = Arc::clone(&self.0); 5597 6543 let fut = async move { 5598 - <T as PlaylistService>::remove_all_tracks(&inner, request).await 6544 + <T as PlaylistService>::remove_all_tracks(&inner, request) 6545 + .await 5599 6546 }; 5600 6547 Box::pin(fut) 5601 6548 } ··· 5625 6572 "/rockbox.v1alpha1.PlaylistService/RemoveTracks" => { 5626 6573 #[allow(non_camel_case_types)] 5627 6574 struct RemoveTracksSvc<T: PlaylistService>(pub Arc<T>); 5628 - impl<T: PlaylistService> tonic::server::UnaryService<super::RemoveTracksRequest> 5629 - for RemoveTracksSvc<T> 5630 - { 6575 + impl< 6576 + T: PlaylistService, 6577 + > tonic::server::UnaryService<super::RemoveTracksRequest> 6578 + for RemoveTracksSvc<T> { 5631 6579 type Response = super::RemoveTracksResponse; 5632 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6580 + type Future = BoxFuture< 6581 + tonic::Response<Self::Response>, 6582 + tonic::Status, 6583 + >; 5633 6584 fn call( 5634 6585 &mut self, 5635 6586 request: tonic::Request<super::RemoveTracksRequest>, ··· 5666 6617 "/rockbox.v1alpha1.PlaylistService/CreatePlaylist" => { 5667 6618 #[allow(non_camel_case_types)] 5668 6619 struct CreatePlaylistSvc<T: PlaylistService>(pub Arc<T>); 5669 - impl<T: PlaylistService> 5670 - tonic::server::UnaryService<super::CreatePlaylistRequest> 5671 - for CreatePlaylistSvc<T> 5672 - { 6620 + impl< 6621 + T: PlaylistService, 6622 + > tonic::server::UnaryService<super::CreatePlaylistRequest> 6623 + for CreatePlaylistSvc<T> { 5673 6624 type Response = super::CreatePlaylistResponse; 5674 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6625 + type Future = BoxFuture< 6626 + tonic::Response<Self::Response>, 6627 + tonic::Status, 6628 + >; 5675 6629 fn call( 5676 6630 &mut self, 5677 6631 request: tonic::Request<super::CreatePlaylistRequest>, 5678 6632 ) -> Self::Future { 5679 6633 let inner = Arc::clone(&self.0); 5680 6634 let fut = async move { 5681 - <T as PlaylistService>::create_playlist(&inner, request).await 6635 + <T as PlaylistService>::create_playlist(&inner, request) 6636 + .await 5682 6637 }; 5683 6638 Box::pin(fut) 5684 6639 } ··· 5708 6663 "/rockbox.v1alpha1.PlaylistService/InsertTracks" => { 5709 6664 #[allow(non_camel_case_types)] 5710 6665 struct InsertTracksSvc<T: PlaylistService>(pub Arc<T>); 5711 - impl<T: PlaylistService> tonic::server::UnaryService<super::InsertTracksRequest> 5712 - for InsertTracksSvc<T> 5713 - { 6666 + impl< 6667 + T: PlaylistService, 6668 + > tonic::server::UnaryService<super::InsertTracksRequest> 6669 + for InsertTracksSvc<T> { 5714 6670 type Response = super::InsertTracksResponse; 5715 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6671 + type Future = BoxFuture< 6672 + tonic::Response<Self::Response>, 6673 + tonic::Status, 6674 + >; 5716 6675 fn call( 5717 6676 &mut self, 5718 6677 request: tonic::Request<super::InsertTracksRequest>, ··· 5749 6708 "/rockbox.v1alpha1.PlaylistService/InsertDirectory" => { 5750 6709 #[allow(non_camel_case_types)] 5751 6710 struct InsertDirectorySvc<T: PlaylistService>(pub Arc<T>); 5752 - impl<T: PlaylistService> 5753 - tonic::server::UnaryService<super::InsertDirectoryRequest> 5754 - for InsertDirectorySvc<T> 5755 - { 6711 + impl< 6712 + T: PlaylistService, 6713 + > tonic::server::UnaryService<super::InsertDirectoryRequest> 6714 + for InsertDirectorySvc<T> { 5756 6715 type Response = super::InsertDirectoryResponse; 5757 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6716 + type Future = BoxFuture< 6717 + tonic::Response<Self::Response>, 6718 + tonic::Status, 6719 + >; 5758 6720 fn call( 5759 6721 &mut self, 5760 6722 request: tonic::Request<super::InsertDirectoryRequest>, 5761 6723 ) -> Self::Future { 5762 6724 let inner = Arc::clone(&self.0); 5763 6725 let fut = async move { 5764 - <T as PlaylistService>::insert_directory(&inner, request).await 6726 + <T as PlaylistService>::insert_directory(&inner, request) 6727 + .await 5765 6728 }; 5766 6729 Box::pin(fut) 5767 6730 } ··· 5791 6754 "/rockbox.v1alpha1.PlaylistService/InsertPlaylist" => { 5792 6755 #[allow(non_camel_case_types)] 5793 6756 struct InsertPlaylistSvc<T: PlaylistService>(pub Arc<T>); 5794 - impl<T: PlaylistService> 5795 - tonic::server::UnaryService<super::InsertPlaylistRequest> 5796 - for InsertPlaylistSvc<T> 5797 - { 6757 + impl< 6758 + T: PlaylistService, 6759 + > tonic::server::UnaryService<super::InsertPlaylistRequest> 6760 + for InsertPlaylistSvc<T> { 5798 6761 type Response = super::InsertPlaylistResponse; 5799 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6762 + type Future = BoxFuture< 6763 + tonic::Response<Self::Response>, 6764 + tonic::Status, 6765 + >; 5800 6766 fn call( 5801 6767 &mut self, 5802 6768 request: tonic::Request<super::InsertPlaylistRequest>, 5803 6769 ) -> Self::Future { 5804 6770 let inner = Arc::clone(&self.0); 5805 6771 let fut = async move { 5806 - <T as PlaylistService>::insert_playlist(&inner, request).await 6772 + <T as PlaylistService>::insert_playlist(&inner, request) 6773 + .await 5807 6774 }; 5808 6775 Box::pin(fut) 5809 6776 } ··· 5833 6800 "/rockbox.v1alpha1.PlaylistService/InsertAlbum" => { 5834 6801 #[allow(non_camel_case_types)] 5835 6802 struct InsertAlbumSvc<T: PlaylistService>(pub Arc<T>); 5836 - impl<T: PlaylistService> tonic::server::UnaryService<super::InsertAlbumRequest> 5837 - for InsertAlbumSvc<T> 5838 - { 6803 + impl< 6804 + T: PlaylistService, 6805 + > tonic::server::UnaryService<super::InsertAlbumRequest> 6806 + for InsertAlbumSvc<T> { 5839 6807 type Response = super::InsertAlbumResponse; 5840 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6808 + type Future = BoxFuture< 6809 + tonic::Response<Self::Response>, 6810 + tonic::Status, 6811 + >; 5841 6812 fn call( 5842 6813 &mut self, 5843 6814 request: tonic::Request<super::InsertAlbumRequest>, ··· 5874 6845 "/rockbox.v1alpha1.PlaylistService/InsertArtistTracks" => { 5875 6846 #[allow(non_camel_case_types)] 5876 6847 struct InsertArtistTracksSvc<T: PlaylistService>(pub Arc<T>); 5877 - impl<T: PlaylistService> 5878 - tonic::server::UnaryService<super::InsertArtistTracksRequest> 5879 - for InsertArtistTracksSvc<T> 5880 - { 6848 + impl< 6849 + T: PlaylistService, 6850 + > tonic::server::UnaryService<super::InsertArtistTracksRequest> 6851 + for InsertArtistTracksSvc<T> { 5881 6852 type Response = super::InsertArtistTracksResponse; 5882 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6853 + type Future = BoxFuture< 6854 + tonic::Response<Self::Response>, 6855 + tonic::Status, 6856 + >; 5883 6857 fn call( 5884 6858 &mut self, 5885 6859 request: tonic::Request<super::InsertArtistTracksRequest>, 5886 6860 ) -> Self::Future { 5887 6861 let inner = Arc::clone(&self.0); 5888 6862 let fut = async move { 5889 - <T as PlaylistService>::insert_artist_tracks(&inner, request).await 6863 + <T as PlaylistService>::insert_artist_tracks( 6864 + &inner, 6865 + request, 6866 + ) 6867 + .await 5890 6868 }; 5891 6869 Box::pin(fut) 5892 6870 } ··· 5916 6894 "/rockbox.v1alpha1.PlaylistService/ShufflePlaylist" => { 5917 6895 #[allow(non_camel_case_types)] 5918 6896 struct ShufflePlaylistSvc<T: PlaylistService>(pub Arc<T>); 5919 - impl<T: PlaylistService> 5920 - tonic::server::UnaryService<super::ShufflePlaylistRequest> 5921 - for ShufflePlaylistSvc<T> 5922 - { 6897 + impl< 6898 + T: PlaylistService, 6899 + > tonic::server::UnaryService<super::ShufflePlaylistRequest> 6900 + for ShufflePlaylistSvc<T> { 5923 6901 type Response = super::ShufflePlaylistResponse; 5924 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 6902 + type Future = BoxFuture< 6903 + tonic::Response<Self::Response>, 6904 + tonic::Status, 6905 + >; 5925 6906 fn call( 5926 6907 &mut self, 5927 6908 request: tonic::Request<super::ShufflePlaylistRequest>, 5928 6909 ) -> Self::Future { 5929 6910 let inner = Arc::clone(&self.0); 5930 6911 let fut = async move { 5931 - <T as PlaylistService>::shuffle_playlist(&inner, request).await 6912 + <T as PlaylistService>::shuffle_playlist(&inner, request) 6913 + .await 5932 6914 }; 5933 6915 Box::pin(fut) 5934 6916 } ··· 5955 6937 }; 5956 6938 Box::pin(fut) 5957 6939 } 5958 - _ => Box::pin(async move { 5959 - let mut response = http::Response::new(empty_body()); 5960 - let headers = response.headers_mut(); 5961 - headers.insert( 5962 - tonic::Status::GRPC_STATUS, 5963 - (tonic::Code::Unimplemented as i32).into(), 5964 - ); 5965 - headers.insert( 5966 - http::header::CONTENT_TYPE, 5967 - tonic::metadata::GRPC_CONTENT_TYPE, 5968 - ); 5969 - Ok(response) 5970 - }), 6940 + _ => { 6941 + Box::pin(async move { 6942 + let mut response = http::Response::new(empty_body()); 6943 + let headers = response.headers_mut(); 6944 + headers 6945 + .insert( 6946 + tonic::Status::GRPC_STATUS, 6947 + (tonic::Code::Unimplemented as i32).into(), 6948 + ); 6949 + headers 6950 + .insert( 6951 + http::header::CONTENT_TYPE, 6952 + tonic::metadata::GRPC_CONTENT_TYPE, 6953 + ); 6954 + Ok(response) 6955 + }) 6956 + } 5971 6957 } 5972 6958 } 5973 6959 } ··· 6477 7463 dead_code, 6478 7464 missing_docs, 6479 7465 clippy::wildcard_imports, 6480 - clippy::let_unit_value 7466 + clippy::let_unit_value, 6481 7467 )] 6482 - use tonic::codegen::http::Uri; 6483 7468 use tonic::codegen::*; 7469 + use tonic::codegen::http::Uri; 6484 7470 #[derive(Debug, Clone)] 6485 7471 pub struct SettingsServiceClient<T> { 6486 7472 inner: tonic::client::Grpc<T>, ··· 6524 7510 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody, 6525 7511 >, 6526 7512 >, 6527 - <T as tonic::codegen::Service<http::Request<tonic::body::BoxBody>>>::Error: 6528 - Into<StdError> + std::marker::Send + std::marker::Sync, 7513 + <T as tonic::codegen::Service< 7514 + http::Request<tonic::body::BoxBody>, 7515 + >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync, 6529 7516 { 6530 7517 SettingsServiceClient::new(InterceptedService::new(inner, interceptor)) 6531 7518 } ··· 6563 7550 pub async fn get_settings_list( 6564 7551 &mut self, 6565 7552 request: impl tonic::IntoRequest<super::GetSettingsListRequest>, 6566 - ) -> std::result::Result<tonic::Response<super::GetSettingsListResponse>, tonic::Status> 6567 - { 6568 - self.inner.ready().await.map_err(|e| { 6569 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6570 - })?; 7553 + ) -> std::result::Result< 7554 + tonic::Response<super::GetSettingsListResponse>, 7555 + tonic::Status, 7556 + > { 7557 + self.inner 7558 + .ready() 7559 + .await 7560 + .map_err(|e| { 7561 + tonic::Status::unknown( 7562 + format!("Service was not ready: {}", e.into()), 7563 + ) 7564 + })?; 6571 7565 let codec = tonic::codec::ProstCodec::default(); 6572 7566 let path = http::uri::PathAndQuery::from_static( 6573 7567 "/rockbox.v1alpha1.SettingsService/GetSettingsList", 6574 7568 ); 6575 7569 let mut req = request.into_request(); 6576 - req.extensions_mut().insert(GrpcMethod::new( 6577 - "rockbox.v1alpha1.SettingsService", 6578 - "GetSettingsList", 6579 - )); 7570 + req.extensions_mut() 7571 + .insert( 7572 + GrpcMethod::new( 7573 + "rockbox.v1alpha1.SettingsService", 7574 + "GetSettingsList", 7575 + ), 7576 + ); 6580 7577 self.inner.unary(req, path, codec).await 6581 7578 } 6582 7579 pub async fn get_global_settings( 6583 7580 &mut self, 6584 7581 request: impl tonic::IntoRequest<super::GetGlobalSettingsRequest>, 6585 - ) -> std::result::Result<tonic::Response<super::GetGlobalSettingsResponse>, tonic::Status> 6586 - { 6587 - self.inner.ready().await.map_err(|e| { 6588 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6589 - })?; 7582 + ) -> std::result::Result< 7583 + tonic::Response<super::GetGlobalSettingsResponse>, 7584 + tonic::Status, 7585 + > { 7586 + self.inner 7587 + .ready() 7588 + .await 7589 + .map_err(|e| { 7590 + tonic::Status::unknown( 7591 + format!("Service was not ready: {}", e.into()), 7592 + ) 7593 + })?; 6590 7594 let codec = tonic::codec::ProstCodec::default(); 6591 7595 let path = http::uri::PathAndQuery::from_static( 6592 7596 "/rockbox.v1alpha1.SettingsService/GetGlobalSettings", 6593 7597 ); 6594 7598 let mut req = request.into_request(); 6595 - req.extensions_mut().insert(GrpcMethod::new( 6596 - "rockbox.v1alpha1.SettingsService", 6597 - "GetGlobalSettings", 6598 - )); 7599 + req.extensions_mut() 7600 + .insert( 7601 + GrpcMethod::new( 7602 + "rockbox.v1alpha1.SettingsService", 7603 + "GetGlobalSettings", 7604 + ), 7605 + ); 6599 7606 self.inner.unary(req, path, codec).await 6600 7607 } 6601 7608 pub async fn save_settings( 6602 7609 &mut self, 6603 7610 request: impl tonic::IntoRequest<super::SaveSettingsRequest>, 6604 - ) -> std::result::Result<tonic::Response<super::SaveSettingsResponse>, tonic::Status> 6605 - { 6606 - self.inner.ready().await.map_err(|e| { 6607 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 6608 - })?; 7611 + ) -> std::result::Result< 7612 + tonic::Response<super::SaveSettingsResponse>, 7613 + tonic::Status, 7614 + > { 7615 + self.inner 7616 + .ready() 7617 + .await 7618 + .map_err(|e| { 7619 + tonic::Status::unknown( 7620 + format!("Service was not ready: {}", e.into()), 7621 + ) 7622 + })?; 6609 7623 let codec = tonic::codec::ProstCodec::default(); 6610 7624 let path = http::uri::PathAndQuery::from_static( 6611 7625 "/rockbox.v1alpha1.SettingsService/SaveSettings", 6612 7626 ); 6613 7627 let mut req = request.into_request(); 6614 - req.extensions_mut().insert(GrpcMethod::new( 6615 - "rockbox.v1alpha1.SettingsService", 6616 - "SaveSettings", 6617 - )); 7628 + req.extensions_mut() 7629 + .insert( 7630 + GrpcMethod::new("rockbox.v1alpha1.SettingsService", "SaveSettings"), 7631 + ); 6618 7632 self.inner.unary(req, path, codec).await 6619 7633 } 6620 7634 } ··· 6626 7640 dead_code, 6627 7641 missing_docs, 6628 7642 clippy::wildcard_imports, 6629 - clippy::let_unit_value 7643 + clippy::let_unit_value, 6630 7644 )] 6631 7645 use tonic::codegen::*; 6632 7646 /// Generated trait containing gRPC methods that should be implemented for use with SettingsServiceServer. ··· 6635 7649 async fn get_settings_list( 6636 7650 &self, 6637 7651 request: tonic::Request<super::GetSettingsListRequest>, 6638 - ) -> std::result::Result<tonic::Response<super::GetSettingsListResponse>, tonic::Status>; 7652 + ) -> std::result::Result< 7653 + tonic::Response<super::GetSettingsListResponse>, 7654 + tonic::Status, 7655 + >; 6639 7656 async fn get_global_settings( 6640 7657 &self, 6641 7658 request: tonic::Request<super::GetGlobalSettingsRequest>, 6642 - ) -> std::result::Result<tonic::Response<super::GetGlobalSettingsResponse>, tonic::Status>; 7659 + ) -> std::result::Result< 7660 + tonic::Response<super::GetGlobalSettingsResponse>, 7661 + tonic::Status, 7662 + >; 6643 7663 async fn save_settings( 6644 7664 &self, 6645 7665 request: tonic::Request<super::SaveSettingsRequest>, 6646 - ) -> std::result::Result<tonic::Response<super::SaveSettingsResponse>, tonic::Status>; 7666 + ) -> std::result::Result< 7667 + tonic::Response<super::SaveSettingsResponse>, 7668 + tonic::Status, 7669 + >; 6647 7670 } 6648 7671 #[derive(Debug)] 6649 7672 pub struct SettingsServiceServer<T> { ··· 6666 7689 max_encoding_message_size: None, 6667 7690 } 6668 7691 } 6669 - pub fn with_interceptor<F>(inner: T, interceptor: F) -> InterceptedService<Self, F> 7692 + pub fn with_interceptor<F>( 7693 + inner: T, 7694 + interceptor: F, 7695 + ) -> InterceptedService<Self, F> 6670 7696 where 6671 7697 F: tonic::service::Interceptor, 6672 7698 { ··· 6721 7747 "/rockbox.v1alpha1.SettingsService/GetSettingsList" => { 6722 7748 #[allow(non_camel_case_types)] 6723 7749 struct GetSettingsListSvc<T: SettingsService>(pub Arc<T>); 6724 - impl<T: SettingsService> 6725 - tonic::server::UnaryService<super::GetSettingsListRequest> 6726 - for GetSettingsListSvc<T> 6727 - { 7750 + impl< 7751 + T: SettingsService, 7752 + > tonic::server::UnaryService<super::GetSettingsListRequest> 7753 + for GetSettingsListSvc<T> { 6728 7754 type Response = super::GetSettingsListResponse; 6729 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 7755 + type Future = BoxFuture< 7756 + tonic::Response<Self::Response>, 7757 + tonic::Status, 7758 + >; 6730 7759 fn call( 6731 7760 &mut self, 6732 7761 request: tonic::Request<super::GetSettingsListRequest>, 6733 7762 ) -> Self::Future { 6734 7763 let inner = Arc::clone(&self.0); 6735 7764 let fut = async move { 6736 - <T as SettingsService>::get_settings_list(&inner, request).await 7765 + <T as SettingsService>::get_settings_list(&inner, request) 7766 + .await 6737 7767 }; 6738 7768 Box::pin(fut) 6739 7769 } ··· 6763 7793 "/rockbox.v1alpha1.SettingsService/GetGlobalSettings" => { 6764 7794 #[allow(non_camel_case_types)] 6765 7795 struct GetGlobalSettingsSvc<T: SettingsService>(pub Arc<T>); 6766 - impl<T: SettingsService> 6767 - tonic::server::UnaryService<super::GetGlobalSettingsRequest> 6768 - for GetGlobalSettingsSvc<T> 6769 - { 7796 + impl< 7797 + T: SettingsService, 7798 + > tonic::server::UnaryService<super::GetGlobalSettingsRequest> 7799 + for GetGlobalSettingsSvc<T> { 6770 7800 type Response = super::GetGlobalSettingsResponse; 6771 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 7801 + type Future = BoxFuture< 7802 + tonic::Response<Self::Response>, 7803 + tonic::Status, 7804 + >; 6772 7805 fn call( 6773 7806 &mut self, 6774 7807 request: tonic::Request<super::GetGlobalSettingsRequest>, 6775 7808 ) -> Self::Future { 6776 7809 let inner = Arc::clone(&self.0); 6777 7810 let fut = async move { 6778 - <T as SettingsService>::get_global_settings(&inner, request).await 7811 + <T as SettingsService>::get_global_settings(&inner, request) 7812 + .await 6779 7813 }; 6780 7814 Box::pin(fut) 6781 7815 } ··· 6805 7839 "/rockbox.v1alpha1.SettingsService/SaveSettings" => { 6806 7840 #[allow(non_camel_case_types)] 6807 7841 struct SaveSettingsSvc<T: SettingsService>(pub Arc<T>); 6808 - impl<T: SettingsService> tonic::server::UnaryService<super::SaveSettingsRequest> 6809 - for SaveSettingsSvc<T> 6810 - { 7842 + impl< 7843 + T: SettingsService, 7844 + > tonic::server::UnaryService<super::SaveSettingsRequest> 7845 + for SaveSettingsSvc<T> { 6811 7846 type Response = super::SaveSettingsResponse; 6812 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 7847 + type Future = BoxFuture< 7848 + tonic::Response<Self::Response>, 7849 + tonic::Status, 7850 + >; 6813 7851 fn call( 6814 7852 &mut self, 6815 7853 request: tonic::Request<super::SaveSettingsRequest>, ··· 6843 7881 }; 6844 7882 Box::pin(fut) 6845 7883 } 6846 - _ => Box::pin(async move { 6847 - let mut response = http::Response::new(empty_body()); 6848 - let headers = response.headers_mut(); 6849 - headers.insert( 6850 - tonic::Status::GRPC_STATUS, 6851 - (tonic::Code::Unimplemented as i32).into(), 6852 - ); 6853 - headers.insert( 6854 - http::header::CONTENT_TYPE, 6855 - tonic::metadata::GRPC_CONTENT_TYPE, 6856 - ); 6857 - Ok(response) 6858 - }), 7884 + _ => { 7885 + Box::pin(async move { 7886 + let mut response = http::Response::new(empty_body()); 7887 + let headers = response.headers_mut(); 7888 + headers 7889 + .insert( 7890 + tonic::Status::GRPC_STATUS, 7891 + (tonic::Code::Unimplemented as i32).into(), 7892 + ); 7893 + headers 7894 + .insert( 7895 + http::header::CONTENT_TYPE, 7896 + tonic::metadata::GRPC_CONTENT_TYPE, 7897 + ); 7898 + Ok(response) 7899 + }) 7900 + } 6859 7901 } 6860 7902 } 6861 7903 } ··· 7013 8055 dead_code, 7014 8056 missing_docs, 7015 8057 clippy::wildcard_imports, 7016 - clippy::let_unit_value 8058 + clippy::let_unit_value, 7017 8059 )] 7018 - use tonic::codegen::http::Uri; 7019 8060 use tonic::codegen::*; 8061 + use tonic::codegen::http::Uri; 7020 8062 #[derive(Debug, Clone)] 7021 8063 pub struct SoundServiceClient<T> { 7022 8064 inner: tonic::client::Grpc<T>, ··· 7060 8102 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody, 7061 8103 >, 7062 8104 >, 7063 - <T as tonic::codegen::Service<http::Request<tonic::body::BoxBody>>>::Error: 7064 - Into<StdError> + std::marker::Send + std::marker::Sync, 8105 + <T as tonic::codegen::Service< 8106 + http::Request<tonic::body::BoxBody>, 8107 + >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync, 7065 8108 { 7066 8109 SoundServiceClient::new(InterceptedService::new(inner, interceptor)) 7067 8110 } ··· 7099 8142 pub async fn adjust_volume( 7100 8143 &mut self, 7101 8144 request: impl tonic::IntoRequest<super::AdjustVolumeRequest>, 7102 - ) -> std::result::Result<tonic::Response<super::AdjustVolumeResponse>, tonic::Status> 7103 - { 7104 - self.inner.ready().await.map_err(|e| { 7105 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 7106 - })?; 8145 + ) -> std::result::Result< 8146 + tonic::Response<super::AdjustVolumeResponse>, 8147 + tonic::Status, 8148 + > { 8149 + self.inner 8150 + .ready() 8151 + .await 8152 + .map_err(|e| { 8153 + tonic::Status::unknown( 8154 + format!("Service was not ready: {}", e.into()), 8155 + ) 8156 + })?; 7107 8157 let codec = tonic::codec::ProstCodec::default(); 7108 - let path = 7109 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/AdjustVolume"); 8158 + let path = http::uri::PathAndQuery::from_static( 8159 + "/rockbox.v1alpha1.SoundService/AdjustVolume", 8160 + ); 7110 8161 let mut req = request.into_request(); 7111 - req.extensions_mut().insert(GrpcMethod::new( 7112 - "rockbox.v1alpha1.SoundService", 7113 - "AdjustVolume", 7114 - )); 8162 + req.extensions_mut() 8163 + .insert( 8164 + GrpcMethod::new("rockbox.v1alpha1.SoundService", "AdjustVolume"), 8165 + ); 7115 8166 self.inner.unary(req, path, codec).await 7116 8167 } 7117 8168 pub async fn sound_set( 7118 8169 &mut self, 7119 8170 request: impl tonic::IntoRequest<super::SoundSetRequest>, 7120 - ) -> std::result::Result<tonic::Response<super::SoundSetResponse>, tonic::Status> { 7121 - self.inner.ready().await.map_err(|e| { 7122 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 7123 - })?; 8171 + ) -> std::result::Result< 8172 + tonic::Response<super::SoundSetResponse>, 8173 + tonic::Status, 8174 + > { 8175 + self.inner 8176 + .ready() 8177 + .await 8178 + .map_err(|e| { 8179 + tonic::Status::unknown( 8180 + format!("Service was not ready: {}", e.into()), 8181 + ) 8182 + })?; 7124 8183 let codec = tonic::codec::ProstCodec::default(); 7125 - let path = 7126 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/SoundSet"); 8184 + let path = http::uri::PathAndQuery::from_static( 8185 + "/rockbox.v1alpha1.SoundService/SoundSet", 8186 + ); 7127 8187 let mut req = request.into_request(); 7128 8188 req.extensions_mut() 7129 8189 .insert(GrpcMethod::new("rockbox.v1alpha1.SoundService", "SoundSet")); ··· 7132 8192 pub async fn sound_current( 7133 8193 &mut self, 7134 8194 request: impl tonic::IntoRequest<super::SoundCurrentRequest>, 7135 - ) -> std::result::Result<tonic::Response<super::SoundCurrentResponse>, tonic::Status> 7136 - { 7137 - self.inner.ready().await.map_err(|e| { 7138 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 7139 - })?; 8195 + ) -> std::result::Result< 8196 + tonic::Response<super::SoundCurrentResponse>, 8197 + tonic::Status, 8198 + > { 8199 + self.inner 8200 + .ready() 8201 + .await 8202 + .map_err(|e| { 8203 + tonic::Status::unknown( 8204 + format!("Service was not ready: {}", e.into()), 8205 + ) 8206 + })?; 7140 8207 let codec = tonic::codec::ProstCodec::default(); 7141 - let path = 7142 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/SoundCurrent"); 8208 + let path = http::uri::PathAndQuery::from_static( 8209 + "/rockbox.v1alpha1.SoundService/SoundCurrent", 8210 + ); 7143 8211 let mut req = request.into_request(); 7144 - req.extensions_mut().insert(GrpcMethod::new( 7145 - "rockbox.v1alpha1.SoundService", 7146 - "SoundCurrent", 7147 - )); 8212 + req.extensions_mut() 8213 + .insert( 8214 + GrpcMethod::new("rockbox.v1alpha1.SoundService", "SoundCurrent"), 8215 + ); 7148 8216 self.inner.unary(req, path, codec).await 7149 8217 } 7150 8218 pub async fn sound_default( 7151 8219 &mut self, 7152 8220 request: impl tonic::IntoRequest<super::SoundDefaultRequest>, 7153 - ) -> std::result::Result<tonic::Response<super::SoundDefaultResponse>, tonic::Status> 7154 - { 7155 - self.inner.ready().await.map_err(|e| { 7156 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 7157 - })?; 8221 + ) -> std::result::Result< 8222 + tonic::Response<super::SoundDefaultResponse>, 8223 + tonic::Status, 8224 + > { 8225 + self.inner 8226 + .ready() 8227 + .await 8228 + .map_err(|e| { 8229 + tonic::Status::unknown( 8230 + format!("Service was not ready: {}", e.into()), 8231 + ) 8232 + })?; 7158 8233 let codec = tonic::codec::ProstCodec::default(); 7159 - let path = 7160 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/SoundDefault"); 8234 + let path = http::uri::PathAndQuery::from_static( 8235 + "/rockbox.v1alpha1.SoundService/SoundDefault", 8236 + ); 7161 8237 let mut req = request.into_request(); 7162 - req.extensions_mut().insert(GrpcMethod::new( 7163 - "rockbox.v1alpha1.SoundService", 7164 - "SoundDefault", 7165 - )); 8238 + req.extensions_mut() 8239 + .insert( 8240 + GrpcMethod::new("rockbox.v1alpha1.SoundService", "SoundDefault"), 8241 + ); 7166 8242 self.inner.unary(req, path, codec).await 7167 8243 } 7168 8244 pub async fn sound_min( 7169 8245 &mut self, 7170 8246 request: impl tonic::IntoRequest<super::SoundMinRequest>, 7171 - ) -> std::result::Result<tonic::Response<super::SoundMinResponse>, tonic::Status> { 7172 - self.inner.ready().await.map_err(|e| { 7173 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 7174 - })?; 8247 + ) -> std::result::Result< 8248 + tonic::Response<super::SoundMinResponse>, 8249 + tonic::Status, 8250 + > { 8251 + self.inner 8252 + .ready() 8253 + .await 8254 + .map_err(|e| { 8255 + tonic::Status::unknown( 8256 + format!("Service was not ready: {}", e.into()), 8257 + ) 8258 + })?; 7175 8259 let codec = tonic::codec::ProstCodec::default(); 7176 - let path = 7177 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/SoundMin"); 8260 + let path = http::uri::PathAndQuery::from_static( 8261 + "/rockbox.v1alpha1.SoundService/SoundMin", 8262 + ); 7178 8263 let mut req = request.into_request(); 7179 8264 req.extensions_mut() 7180 8265 .insert(GrpcMethod::new("rockbox.v1alpha1.SoundService", "SoundMin")); ··· 7183 8268 pub async fn sound_max( 7184 8269 &mut self, 7185 8270 request: impl tonic::IntoRequest<super::SoundMaxRequest>, 7186 - ) -> std::result::Result<tonic::Response<super::SoundMaxResponse>, tonic::Status> { 7187 - self.inner.ready().await.map_err(|e| { 7188 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 7189 - })?; 8271 + ) -> std::result::Result< 8272 + tonic::Response<super::SoundMaxResponse>, 8273 + tonic::Status, 8274 + > { 8275 + self.inner 8276 + .ready() 8277 + .await 8278 + .map_err(|e| { 8279 + tonic::Status::unknown( 8280 + format!("Service was not ready: {}", e.into()), 8281 + ) 8282 + })?; 7190 8283 let codec = tonic::codec::ProstCodec::default(); 7191 - let path = 7192 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/SoundMax"); 8284 + let path = http::uri::PathAndQuery::from_static( 8285 + "/rockbox.v1alpha1.SoundService/SoundMax", 8286 + ); 7193 8287 let mut req = request.into_request(); 7194 8288 req.extensions_mut() 7195 8289 .insert(GrpcMethod::new("rockbox.v1alpha1.SoundService", "SoundMax")); ··· 7198 8292 pub async fn sound_unit( 7199 8293 &mut self, 7200 8294 request: impl tonic::IntoRequest<super::SoundUnitRequest>, 7201 - ) -> std::result::Result<tonic::Response<super::SoundUnitResponse>, tonic::Status> { 7202 - self.inner.ready().await.map_err(|e| { 7203 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 7204 - })?; 8295 + ) -> std::result::Result< 8296 + tonic::Response<super::SoundUnitResponse>, 8297 + tonic::Status, 8298 + > { 8299 + self.inner 8300 + .ready() 8301 + .await 8302 + .map_err(|e| { 8303 + tonic::Status::unknown( 8304 + format!("Service was not ready: {}", e.into()), 8305 + ) 8306 + })?; 7205 8307 let codec = tonic::codec::ProstCodec::default(); 7206 - let path = 7207 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/SoundUnit"); 8308 + let path = http::uri::PathAndQuery::from_static( 8309 + "/rockbox.v1alpha1.SoundService/SoundUnit", 8310 + ); 7208 8311 let mut req = request.into_request(); 7209 - req.extensions_mut().insert(GrpcMethod::new( 7210 - "rockbox.v1alpha1.SoundService", 7211 - "SoundUnit", 7212 - )); 8312 + req.extensions_mut() 8313 + .insert(GrpcMethod::new("rockbox.v1alpha1.SoundService", "SoundUnit")); 7213 8314 self.inner.unary(req, path, codec).await 7214 8315 } 7215 8316 pub async fn sound_val2_phys( 7216 8317 &mut self, 7217 8318 request: impl tonic::IntoRequest<super::SoundVal2PhysRequest>, 7218 - ) -> std::result::Result<tonic::Response<super::SoundVal2PhysResponse>, tonic::Status> 7219 - { 7220 - self.inner.ready().await.map_err(|e| { 7221 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 7222 - })?; 8319 + ) -> std::result::Result< 8320 + tonic::Response<super::SoundVal2PhysResponse>, 8321 + tonic::Status, 8322 + > { 8323 + self.inner 8324 + .ready() 8325 + .await 8326 + .map_err(|e| { 8327 + tonic::Status::unknown( 8328 + format!("Service was not ready: {}", e.into()), 8329 + ) 8330 + })?; 7223 8331 let codec = tonic::codec::ProstCodec::default(); 7224 8332 let path = http::uri::PathAndQuery::from_static( 7225 8333 "/rockbox.v1alpha1.SoundService/SoundVal2Phys", 7226 8334 ); 7227 8335 let mut req = request.into_request(); 7228 - req.extensions_mut().insert(GrpcMethod::new( 7229 - "rockbox.v1alpha1.SoundService", 7230 - "SoundVal2Phys", 7231 - )); 8336 + req.extensions_mut() 8337 + .insert( 8338 + GrpcMethod::new("rockbox.v1alpha1.SoundService", "SoundVal2Phys"), 8339 + ); 7232 8340 self.inner.unary(req, path, codec).await 7233 8341 } 7234 8342 pub async fn get_pitch( 7235 8343 &mut self, 7236 8344 request: impl tonic::IntoRequest<super::GetPitchRequest>, 7237 - ) -> std::result::Result<tonic::Response<super::GetPitchResponse>, tonic::Status> { 7238 - self.inner.ready().await.map_err(|e| { 7239 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 7240 - })?; 8345 + ) -> std::result::Result< 8346 + tonic::Response<super::GetPitchResponse>, 8347 + tonic::Status, 8348 + > { 8349 + self.inner 8350 + .ready() 8351 + .await 8352 + .map_err(|e| { 8353 + tonic::Status::unknown( 8354 + format!("Service was not ready: {}", e.into()), 8355 + ) 8356 + })?; 7241 8357 let codec = tonic::codec::ProstCodec::default(); 7242 - let path = 7243 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/GetPitch"); 8358 + let path = http::uri::PathAndQuery::from_static( 8359 + "/rockbox.v1alpha1.SoundService/GetPitch", 8360 + ); 7244 8361 let mut req = request.into_request(); 7245 8362 req.extensions_mut() 7246 8363 .insert(GrpcMethod::new("rockbox.v1alpha1.SoundService", "GetPitch")); ··· 7249 8366 pub async fn set_pitch( 7250 8367 &mut self, 7251 8368 request: impl tonic::IntoRequest<super::SetPitchRequest>, 7252 - ) -> std::result::Result<tonic::Response<super::SetPitchResponse>, tonic::Status> { 7253 - self.inner.ready().await.map_err(|e| { 7254 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 7255 - })?; 8369 + ) -> std::result::Result< 8370 + tonic::Response<super::SetPitchResponse>, 8371 + tonic::Status, 8372 + > { 8373 + self.inner 8374 + .ready() 8375 + .await 8376 + .map_err(|e| { 8377 + tonic::Status::unknown( 8378 + format!("Service was not ready: {}", e.into()), 8379 + ) 8380 + })?; 7256 8381 let codec = tonic::codec::ProstCodec::default(); 7257 - let path = 7258 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/SetPitch"); 8382 + let path = http::uri::PathAndQuery::from_static( 8383 + "/rockbox.v1alpha1.SoundService/SetPitch", 8384 + ); 7259 8385 let mut req = request.into_request(); 7260 8386 req.extensions_mut() 7261 8387 .insert(GrpcMethod::new("rockbox.v1alpha1.SoundService", "SetPitch")); ··· 7264 8390 pub async fn beep_play( 7265 8391 &mut self, 7266 8392 request: impl tonic::IntoRequest<super::BeepPlayRequest>, 7267 - ) -> std::result::Result<tonic::Response<super::BeepPlayResponse>, tonic::Status> { 7268 - self.inner.ready().await.map_err(|e| { 7269 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 7270 - })?; 8393 + ) -> std::result::Result< 8394 + tonic::Response<super::BeepPlayResponse>, 8395 + tonic::Status, 8396 + > { 8397 + self.inner 8398 + .ready() 8399 + .await 8400 + .map_err(|e| { 8401 + tonic::Status::unknown( 8402 + format!("Service was not ready: {}", e.into()), 8403 + ) 8404 + })?; 7271 8405 let codec = tonic::codec::ProstCodec::default(); 7272 - let path = 7273 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/BeepPlay"); 8406 + let path = http::uri::PathAndQuery::from_static( 8407 + "/rockbox.v1alpha1.SoundService/BeepPlay", 8408 + ); 7274 8409 let mut req = request.into_request(); 7275 8410 req.extensions_mut() 7276 8411 .insert(GrpcMethod::new("rockbox.v1alpha1.SoundService", "BeepPlay")); ··· 7279 8414 pub async fn pcmbuf_fade( 7280 8415 &mut self, 7281 8416 request: impl tonic::IntoRequest<super::PcmbufFadeRequest>, 7282 - ) -> std::result::Result<tonic::Response<super::PcmbufFadeResponse>, tonic::Status> 7283 - { 7284 - self.inner.ready().await.map_err(|e| { 7285 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 7286 - })?; 8417 + ) -> std::result::Result< 8418 + tonic::Response<super::PcmbufFadeResponse>, 8419 + tonic::Status, 8420 + > { 8421 + self.inner 8422 + .ready() 8423 + .await 8424 + .map_err(|e| { 8425 + tonic::Status::unknown( 8426 + format!("Service was not ready: {}", e.into()), 8427 + ) 8428 + })?; 7287 8429 let codec = tonic::codec::ProstCodec::default(); 7288 - let path = 7289 - http::uri::PathAndQuery::from_static("/rockbox.v1alpha1.SoundService/PcmbufFade"); 8430 + let path = http::uri::PathAndQuery::from_static( 8431 + "/rockbox.v1alpha1.SoundService/PcmbufFade", 8432 + ); 7290 8433 let mut req = request.into_request(); 7291 - req.extensions_mut().insert(GrpcMethod::new( 7292 - "rockbox.v1alpha1.SoundService", 7293 - "PcmbufFade", 7294 - )); 8434 + req.extensions_mut() 8435 + .insert(GrpcMethod::new("rockbox.v1alpha1.SoundService", "PcmbufFade")); 7295 8436 self.inner.unary(req, path, codec).await 7296 8437 } 7297 8438 pub async fn pcmbuf_set_low_latency( 7298 8439 &mut self, 7299 8440 request: impl tonic::IntoRequest<super::PcmbufSetLowLatencyRequest>, 7300 - ) -> std::result::Result<tonic::Response<super::PcmbufSetLowLatencyResponse>, tonic::Status> 7301 - { 7302 - self.inner.ready().await.map_err(|e| { 7303 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 7304 - })?; 8441 + ) -> std::result::Result< 8442 + tonic::Response<super::PcmbufSetLowLatencyResponse>, 8443 + tonic::Status, 8444 + > { 8445 + self.inner 8446 + .ready() 8447 + .await 8448 + .map_err(|e| { 8449 + tonic::Status::unknown( 8450 + format!("Service was not ready: {}", e.into()), 8451 + ) 8452 + })?; 7305 8453 let codec = tonic::codec::ProstCodec::default(); 7306 8454 let path = http::uri::PathAndQuery::from_static( 7307 8455 "/rockbox.v1alpha1.SoundService/PcmbufSetLowLatency", 7308 8456 ); 7309 8457 let mut req = request.into_request(); 7310 - req.extensions_mut().insert(GrpcMethod::new( 7311 - "rockbox.v1alpha1.SoundService", 7312 - "PcmbufSetLowLatency", 7313 - )); 8458 + req.extensions_mut() 8459 + .insert( 8460 + GrpcMethod::new( 8461 + "rockbox.v1alpha1.SoundService", 8462 + "PcmbufSetLowLatency", 8463 + ), 8464 + ); 7314 8465 self.inner.unary(req, path, codec).await 7315 8466 } 7316 8467 pub async fn system_sound_play( 7317 8468 &mut self, 7318 8469 request: impl tonic::IntoRequest<super::SystemSoundPlayRequest>, 7319 - ) -> std::result::Result<tonic::Response<super::SystemSoundPlayResponse>, tonic::Status> 7320 - { 7321 - self.inner.ready().await.map_err(|e| { 7322 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 7323 - })?; 8470 + ) -> std::result::Result< 8471 + tonic::Response<super::SystemSoundPlayResponse>, 8472 + tonic::Status, 8473 + > { 8474 + self.inner 8475 + .ready() 8476 + .await 8477 + .map_err(|e| { 8478 + tonic::Status::unknown( 8479 + format!("Service was not ready: {}", e.into()), 8480 + ) 8481 + })?; 7324 8482 let codec = tonic::codec::ProstCodec::default(); 7325 8483 let path = http::uri::PathAndQuery::from_static( 7326 8484 "/rockbox.v1alpha1.SoundService/SystemSoundPlay", 7327 8485 ); 7328 8486 let mut req = request.into_request(); 7329 - req.extensions_mut().insert(GrpcMethod::new( 7330 - "rockbox.v1alpha1.SoundService", 7331 - "SystemSoundPlay", 7332 - )); 8487 + req.extensions_mut() 8488 + .insert( 8489 + GrpcMethod::new("rockbox.v1alpha1.SoundService", "SystemSoundPlay"), 8490 + ); 7333 8491 self.inner.unary(req, path, codec).await 7334 8492 } 7335 8493 pub async fn keyclick_click( 7336 8494 &mut self, 7337 8495 request: impl tonic::IntoRequest<super::KeyclickClickRequest>, 7338 - ) -> std::result::Result<tonic::Response<super::KeyclickClickResponse>, tonic::Status> 7339 - { 7340 - self.inner.ready().await.map_err(|e| { 7341 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 7342 - })?; 8496 + ) -> std::result::Result< 8497 + tonic::Response<super::KeyclickClickResponse>, 8498 + tonic::Status, 8499 + > { 8500 + self.inner 8501 + .ready() 8502 + .await 8503 + .map_err(|e| { 8504 + tonic::Status::unknown( 8505 + format!("Service was not ready: {}", e.into()), 8506 + ) 8507 + })?; 7343 8508 let codec = tonic::codec::ProstCodec::default(); 7344 8509 let path = http::uri::PathAndQuery::from_static( 7345 8510 "/rockbox.v1alpha1.SoundService/KeyclickClick", 7346 8511 ); 7347 8512 let mut req = request.into_request(); 7348 - req.extensions_mut().insert(GrpcMethod::new( 7349 - "rockbox.v1alpha1.SoundService", 7350 - "KeyclickClick", 7351 - )); 8513 + req.extensions_mut() 8514 + .insert( 8515 + GrpcMethod::new("rockbox.v1alpha1.SoundService", "KeyclickClick"), 8516 + ); 7352 8517 self.inner.unary(req, path, codec).await 7353 8518 } 7354 8519 } ··· 7360 8525 dead_code, 7361 8526 missing_docs, 7362 8527 clippy::wildcard_imports, 7363 - clippy::let_unit_value 8528 + clippy::let_unit_value, 7364 8529 )] 7365 8530 use tonic::codegen::*; 7366 8531 /// Generated trait containing gRPC methods that should be implemented for use with SoundServiceServer. ··· 7369 8534 async fn adjust_volume( 7370 8535 &self, 7371 8536 request: tonic::Request<super::AdjustVolumeRequest>, 7372 - ) -> std::result::Result<tonic::Response<super::AdjustVolumeResponse>, tonic::Status>; 8537 + ) -> std::result::Result< 8538 + tonic::Response<super::AdjustVolumeResponse>, 8539 + tonic::Status, 8540 + >; 7373 8541 async fn sound_set( 7374 8542 &self, 7375 8543 request: tonic::Request<super::SoundSetRequest>, 7376 - ) -> std::result::Result<tonic::Response<super::SoundSetResponse>, tonic::Status>; 8544 + ) -> std::result::Result< 8545 + tonic::Response<super::SoundSetResponse>, 8546 + tonic::Status, 8547 + >; 7377 8548 async fn sound_current( 7378 8549 &self, 7379 8550 request: tonic::Request<super::SoundCurrentRequest>, 7380 - ) -> std::result::Result<tonic::Response<super::SoundCurrentResponse>, tonic::Status>; 8551 + ) -> std::result::Result< 8552 + tonic::Response<super::SoundCurrentResponse>, 8553 + tonic::Status, 8554 + >; 7381 8555 async fn sound_default( 7382 8556 &self, 7383 8557 request: tonic::Request<super::SoundDefaultRequest>, 7384 - ) -> std::result::Result<tonic::Response<super::SoundDefaultResponse>, tonic::Status>; 8558 + ) -> std::result::Result< 8559 + tonic::Response<super::SoundDefaultResponse>, 8560 + tonic::Status, 8561 + >; 7385 8562 async fn sound_min( 7386 8563 &self, 7387 8564 request: tonic::Request<super::SoundMinRequest>, 7388 - ) -> std::result::Result<tonic::Response<super::SoundMinResponse>, tonic::Status>; 8565 + ) -> std::result::Result< 8566 + tonic::Response<super::SoundMinResponse>, 8567 + tonic::Status, 8568 + >; 7389 8569 async fn sound_max( 7390 8570 &self, 7391 8571 request: tonic::Request<super::SoundMaxRequest>, 7392 - ) -> std::result::Result<tonic::Response<super::SoundMaxResponse>, tonic::Status>; 8572 + ) -> std::result::Result< 8573 + tonic::Response<super::SoundMaxResponse>, 8574 + tonic::Status, 8575 + >; 7393 8576 async fn sound_unit( 7394 8577 &self, 7395 8578 request: tonic::Request<super::SoundUnitRequest>, 7396 - ) -> std::result::Result<tonic::Response<super::SoundUnitResponse>, tonic::Status>; 8579 + ) -> std::result::Result< 8580 + tonic::Response<super::SoundUnitResponse>, 8581 + tonic::Status, 8582 + >; 7397 8583 async fn sound_val2_phys( 7398 8584 &self, 7399 8585 request: tonic::Request<super::SoundVal2PhysRequest>, 7400 - ) -> std::result::Result<tonic::Response<super::SoundVal2PhysResponse>, tonic::Status>; 8586 + ) -> std::result::Result< 8587 + tonic::Response<super::SoundVal2PhysResponse>, 8588 + tonic::Status, 8589 + >; 7401 8590 async fn get_pitch( 7402 8591 &self, 7403 8592 request: tonic::Request<super::GetPitchRequest>, 7404 - ) -> std::result::Result<tonic::Response<super::GetPitchResponse>, tonic::Status>; 8593 + ) -> std::result::Result< 8594 + tonic::Response<super::GetPitchResponse>, 8595 + tonic::Status, 8596 + >; 7405 8597 async fn set_pitch( 7406 8598 &self, 7407 8599 request: tonic::Request<super::SetPitchRequest>, 7408 - ) -> std::result::Result<tonic::Response<super::SetPitchResponse>, tonic::Status>; 8600 + ) -> std::result::Result< 8601 + tonic::Response<super::SetPitchResponse>, 8602 + tonic::Status, 8603 + >; 7409 8604 async fn beep_play( 7410 8605 &self, 7411 8606 request: tonic::Request<super::BeepPlayRequest>, 7412 - ) -> std::result::Result<tonic::Response<super::BeepPlayResponse>, tonic::Status>; 8607 + ) -> std::result::Result< 8608 + tonic::Response<super::BeepPlayResponse>, 8609 + tonic::Status, 8610 + >; 7413 8611 async fn pcmbuf_fade( 7414 8612 &self, 7415 8613 request: tonic::Request<super::PcmbufFadeRequest>, 7416 - ) -> std::result::Result<tonic::Response<super::PcmbufFadeResponse>, tonic::Status>; 8614 + ) -> std::result::Result< 8615 + tonic::Response<super::PcmbufFadeResponse>, 8616 + tonic::Status, 8617 + >; 7417 8618 async fn pcmbuf_set_low_latency( 7418 8619 &self, 7419 8620 request: tonic::Request<super::PcmbufSetLowLatencyRequest>, 7420 - ) -> std::result::Result<tonic::Response<super::PcmbufSetLowLatencyResponse>, tonic::Status>; 8621 + ) -> std::result::Result< 8622 + tonic::Response<super::PcmbufSetLowLatencyResponse>, 8623 + tonic::Status, 8624 + >; 7421 8625 async fn system_sound_play( 7422 8626 &self, 7423 8627 request: tonic::Request<super::SystemSoundPlayRequest>, 7424 - ) -> std::result::Result<tonic::Response<super::SystemSoundPlayResponse>, tonic::Status>; 8628 + ) -> std::result::Result< 8629 + tonic::Response<super::SystemSoundPlayResponse>, 8630 + tonic::Status, 8631 + >; 7425 8632 async fn keyclick_click( 7426 8633 &self, 7427 8634 request: tonic::Request<super::KeyclickClickRequest>, 7428 - ) -> std::result::Result<tonic::Response<super::KeyclickClickResponse>, tonic::Status>; 8635 + ) -> std::result::Result< 8636 + tonic::Response<super::KeyclickClickResponse>, 8637 + tonic::Status, 8638 + >; 7429 8639 } 7430 8640 #[derive(Debug)] 7431 8641 pub struct SoundServiceServer<T> { ··· 7448 8658 max_encoding_message_size: None, 7449 8659 } 7450 8660 } 7451 - pub fn with_interceptor<F>(inner: T, interceptor: F) -> InterceptedService<Self, F> 8661 + pub fn with_interceptor<F>( 8662 + inner: T, 8663 + interceptor: F, 8664 + ) -> InterceptedService<Self, F> 7452 8665 where 7453 8666 F: tonic::service::Interceptor, 7454 8667 { ··· 7503 8716 "/rockbox.v1alpha1.SoundService/AdjustVolume" => { 7504 8717 #[allow(non_camel_case_types)] 7505 8718 struct AdjustVolumeSvc<T: SoundService>(pub Arc<T>); 7506 - impl<T: SoundService> tonic::server::UnaryService<super::AdjustVolumeRequest> 7507 - for AdjustVolumeSvc<T> 7508 - { 8719 + impl< 8720 + T: SoundService, 8721 + > tonic::server::UnaryService<super::AdjustVolumeRequest> 8722 + for AdjustVolumeSvc<T> { 7509 8723 type Response = super::AdjustVolumeResponse; 7510 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8724 + type Future = BoxFuture< 8725 + tonic::Response<Self::Response>, 8726 + tonic::Status, 8727 + >; 7511 8728 fn call( 7512 8729 &mut self, 7513 8730 request: tonic::Request<super::AdjustVolumeRequest>, ··· 7544 8761 "/rockbox.v1alpha1.SoundService/SoundSet" => { 7545 8762 #[allow(non_camel_case_types)] 7546 8763 struct SoundSetSvc<T: SoundService>(pub Arc<T>); 7547 - impl<T: SoundService> tonic::server::UnaryService<super::SoundSetRequest> for SoundSetSvc<T> { 8764 + impl< 8765 + T: SoundService, 8766 + > tonic::server::UnaryService<super::SoundSetRequest> 8767 + for SoundSetSvc<T> { 7548 8768 type Response = super::SoundSetResponse; 7549 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8769 + type Future = BoxFuture< 8770 + tonic::Response<Self::Response>, 8771 + tonic::Status, 8772 + >; 7550 8773 fn call( 7551 8774 &mut self, 7552 8775 request: tonic::Request<super::SoundSetRequest>, ··· 7583 8806 "/rockbox.v1alpha1.SoundService/SoundCurrent" => { 7584 8807 #[allow(non_camel_case_types)] 7585 8808 struct SoundCurrentSvc<T: SoundService>(pub Arc<T>); 7586 - impl<T: SoundService> tonic::server::UnaryService<super::SoundCurrentRequest> 7587 - for SoundCurrentSvc<T> 7588 - { 8809 + impl< 8810 + T: SoundService, 8811 + > tonic::server::UnaryService<super::SoundCurrentRequest> 8812 + for SoundCurrentSvc<T> { 7589 8813 type Response = super::SoundCurrentResponse; 7590 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8814 + type Future = BoxFuture< 8815 + tonic::Response<Self::Response>, 8816 + tonic::Status, 8817 + >; 7591 8818 fn call( 7592 8819 &mut self, 7593 8820 request: tonic::Request<super::SoundCurrentRequest>, ··· 7624 8851 "/rockbox.v1alpha1.SoundService/SoundDefault" => { 7625 8852 #[allow(non_camel_case_types)] 7626 8853 struct SoundDefaultSvc<T: SoundService>(pub Arc<T>); 7627 - impl<T: SoundService> tonic::server::UnaryService<super::SoundDefaultRequest> 7628 - for SoundDefaultSvc<T> 7629 - { 8854 + impl< 8855 + T: SoundService, 8856 + > tonic::server::UnaryService<super::SoundDefaultRequest> 8857 + for SoundDefaultSvc<T> { 7630 8858 type Response = super::SoundDefaultResponse; 7631 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8859 + type Future = BoxFuture< 8860 + tonic::Response<Self::Response>, 8861 + tonic::Status, 8862 + >; 7632 8863 fn call( 7633 8864 &mut self, 7634 8865 request: tonic::Request<super::SoundDefaultRequest>, ··· 7665 8896 "/rockbox.v1alpha1.SoundService/SoundMin" => { 7666 8897 #[allow(non_camel_case_types)] 7667 8898 struct SoundMinSvc<T: SoundService>(pub Arc<T>); 7668 - impl<T: SoundService> tonic::server::UnaryService<super::SoundMinRequest> for SoundMinSvc<T> { 8899 + impl< 8900 + T: SoundService, 8901 + > tonic::server::UnaryService<super::SoundMinRequest> 8902 + for SoundMinSvc<T> { 7669 8903 type Response = super::SoundMinResponse; 7670 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8904 + type Future = BoxFuture< 8905 + tonic::Response<Self::Response>, 8906 + tonic::Status, 8907 + >; 7671 8908 fn call( 7672 8909 &mut self, 7673 8910 request: tonic::Request<super::SoundMinRequest>, ··· 7704 8941 "/rockbox.v1alpha1.SoundService/SoundMax" => { 7705 8942 #[allow(non_camel_case_types)] 7706 8943 struct SoundMaxSvc<T: SoundService>(pub Arc<T>); 7707 - impl<T: SoundService> tonic::server::UnaryService<super::SoundMaxRequest> for SoundMaxSvc<T> { 8944 + impl< 8945 + T: SoundService, 8946 + > tonic::server::UnaryService<super::SoundMaxRequest> 8947 + for SoundMaxSvc<T> { 7708 8948 type Response = super::SoundMaxResponse; 7709 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8949 + type Future = BoxFuture< 8950 + tonic::Response<Self::Response>, 8951 + tonic::Status, 8952 + >; 7710 8953 fn call( 7711 8954 &mut self, 7712 8955 request: tonic::Request<super::SoundMaxRequest>, ··· 7743 8986 "/rockbox.v1alpha1.SoundService/SoundUnit" => { 7744 8987 #[allow(non_camel_case_types)] 7745 8988 struct SoundUnitSvc<T: SoundService>(pub Arc<T>); 7746 - impl<T: SoundService> tonic::server::UnaryService<super::SoundUnitRequest> for SoundUnitSvc<T> { 8989 + impl< 8990 + T: SoundService, 8991 + > tonic::server::UnaryService<super::SoundUnitRequest> 8992 + for SoundUnitSvc<T> { 7747 8993 type Response = super::SoundUnitResponse; 7748 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 8994 + type Future = BoxFuture< 8995 + tonic::Response<Self::Response>, 8996 + tonic::Status, 8997 + >; 7749 8998 fn call( 7750 8999 &mut self, 7751 9000 request: tonic::Request<super::SoundUnitRequest>, ··· 7782 9031 "/rockbox.v1alpha1.SoundService/SoundVal2Phys" => { 7783 9032 #[allow(non_camel_case_types)] 7784 9033 struct SoundVal2PhysSvc<T: SoundService>(pub Arc<T>); 7785 - impl<T: SoundService> tonic::server::UnaryService<super::SoundVal2PhysRequest> 7786 - for SoundVal2PhysSvc<T> 7787 - { 9034 + impl< 9035 + T: SoundService, 9036 + > tonic::server::UnaryService<super::SoundVal2PhysRequest> 9037 + for SoundVal2PhysSvc<T> { 7788 9038 type Response = super::SoundVal2PhysResponse; 7789 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 9039 + type Future = BoxFuture< 9040 + tonic::Response<Self::Response>, 9041 + tonic::Status, 9042 + >; 7790 9043 fn call( 7791 9044 &mut self, 7792 9045 request: tonic::Request<super::SoundVal2PhysRequest>, ··· 7823 9076 "/rockbox.v1alpha1.SoundService/GetPitch" => { 7824 9077 #[allow(non_camel_case_types)] 7825 9078 struct GetPitchSvc<T: SoundService>(pub Arc<T>); 7826 - impl<T: SoundService> tonic::server::UnaryService<super::GetPitchRequest> for GetPitchSvc<T> { 9079 + impl< 9080 + T: SoundService, 9081 + > tonic::server::UnaryService<super::GetPitchRequest> 9082 + for GetPitchSvc<T> { 7827 9083 type Response = super::GetPitchResponse; 7828 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 9084 + type Future = BoxFuture< 9085 + tonic::Response<Self::Response>, 9086 + tonic::Status, 9087 + >; 7829 9088 fn call( 7830 9089 &mut self, 7831 9090 request: tonic::Request<super::GetPitchRequest>, ··· 7862 9121 "/rockbox.v1alpha1.SoundService/SetPitch" => { 7863 9122 #[allow(non_camel_case_types)] 7864 9123 struct SetPitchSvc<T: SoundService>(pub Arc<T>); 7865 - impl<T: SoundService> tonic::server::UnaryService<super::SetPitchRequest> for SetPitchSvc<T> { 9124 + impl< 9125 + T: SoundService, 9126 + > tonic::server::UnaryService<super::SetPitchRequest> 9127 + for SetPitchSvc<T> { 7866 9128 type Response = super::SetPitchResponse; 7867 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 9129 + type Future = BoxFuture< 9130 + tonic::Response<Self::Response>, 9131 + tonic::Status, 9132 + >; 7868 9133 fn call( 7869 9134 &mut self, 7870 9135 request: tonic::Request<super::SetPitchRequest>, ··· 7901 9166 "/rockbox.v1alpha1.SoundService/BeepPlay" => { 7902 9167 #[allow(non_camel_case_types)] 7903 9168 struct BeepPlaySvc<T: SoundService>(pub Arc<T>); 7904 - impl<T: SoundService> tonic::server::UnaryService<super::BeepPlayRequest> for BeepPlaySvc<T> { 9169 + impl< 9170 + T: SoundService, 9171 + > tonic::server::UnaryService<super::BeepPlayRequest> 9172 + for BeepPlaySvc<T> { 7905 9173 type Response = super::BeepPlayResponse; 7906 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 9174 + type Future = BoxFuture< 9175 + tonic::Response<Self::Response>, 9176 + tonic::Status, 9177 + >; 7907 9178 fn call( 7908 9179 &mut self, 7909 9180 request: tonic::Request<super::BeepPlayRequest>, ··· 7940 9211 "/rockbox.v1alpha1.SoundService/PcmbufFade" => { 7941 9212 #[allow(non_camel_case_types)] 7942 9213 struct PcmbufFadeSvc<T: SoundService>(pub Arc<T>); 7943 - impl<T: SoundService> tonic::server::UnaryService<super::PcmbufFadeRequest> for PcmbufFadeSvc<T> { 9214 + impl< 9215 + T: SoundService, 9216 + > tonic::server::UnaryService<super::PcmbufFadeRequest> 9217 + for PcmbufFadeSvc<T> { 7944 9218 type Response = super::PcmbufFadeResponse; 7945 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 9219 + type Future = BoxFuture< 9220 + tonic::Response<Self::Response>, 9221 + tonic::Status, 9222 + >; 7946 9223 fn call( 7947 9224 &mut self, 7948 9225 request: tonic::Request<super::PcmbufFadeRequest>, ··· 7979 9256 "/rockbox.v1alpha1.SoundService/PcmbufSetLowLatency" => { 7980 9257 #[allow(non_camel_case_types)] 7981 9258 struct PcmbufSetLowLatencySvc<T: SoundService>(pub Arc<T>); 7982 - impl<T: SoundService> 7983 - tonic::server::UnaryService<super::PcmbufSetLowLatencyRequest> 7984 - for PcmbufSetLowLatencySvc<T> 7985 - { 9259 + impl< 9260 + T: SoundService, 9261 + > tonic::server::UnaryService<super::PcmbufSetLowLatencyRequest> 9262 + for PcmbufSetLowLatencySvc<T> { 7986 9263 type Response = super::PcmbufSetLowLatencyResponse; 7987 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 9264 + type Future = BoxFuture< 9265 + tonic::Response<Self::Response>, 9266 + tonic::Status, 9267 + >; 7988 9268 fn call( 7989 9269 &mut self, 7990 9270 request: tonic::Request<super::PcmbufSetLowLatencyRequest>, 7991 9271 ) -> Self::Future { 7992 9272 let inner = Arc::clone(&self.0); 7993 9273 let fut = async move { 7994 - <T as SoundService>::pcmbuf_set_low_latency(&inner, request).await 9274 + <T as SoundService>::pcmbuf_set_low_latency(&inner, request) 9275 + .await 7995 9276 }; 7996 9277 Box::pin(fut) 7997 9278 } ··· 8021 9302 "/rockbox.v1alpha1.SoundService/SystemSoundPlay" => { 8022 9303 #[allow(non_camel_case_types)] 8023 9304 struct SystemSoundPlaySvc<T: SoundService>(pub Arc<T>); 8024 - impl<T: SoundService> tonic::server::UnaryService<super::SystemSoundPlayRequest> 8025 - for SystemSoundPlaySvc<T> 8026 - { 9305 + impl< 9306 + T: SoundService, 9307 + > tonic::server::UnaryService<super::SystemSoundPlayRequest> 9308 + for SystemSoundPlaySvc<T> { 8027 9309 type Response = super::SystemSoundPlayResponse; 8028 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 9310 + type Future = BoxFuture< 9311 + tonic::Response<Self::Response>, 9312 + tonic::Status, 9313 + >; 8029 9314 fn call( 8030 9315 &mut self, 8031 9316 request: tonic::Request<super::SystemSoundPlayRequest>, 8032 9317 ) -> Self::Future { 8033 9318 let inner = Arc::clone(&self.0); 8034 9319 let fut = async move { 8035 - <T as SoundService>::system_sound_play(&inner, request).await 9320 + <T as SoundService>::system_sound_play(&inner, request) 9321 + .await 8036 9322 }; 8037 9323 Box::pin(fut) 8038 9324 } ··· 8062 9348 "/rockbox.v1alpha1.SoundService/KeyclickClick" => { 8063 9349 #[allow(non_camel_case_types)] 8064 9350 struct KeyclickClickSvc<T: SoundService>(pub Arc<T>); 8065 - impl<T: SoundService> tonic::server::UnaryService<super::KeyclickClickRequest> 8066 - for KeyclickClickSvc<T> 8067 - { 9351 + impl< 9352 + T: SoundService, 9353 + > tonic::server::UnaryService<super::KeyclickClickRequest> 9354 + for KeyclickClickSvc<T> { 8068 9355 type Response = super::KeyclickClickResponse; 8069 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 9356 + type Future = BoxFuture< 9357 + tonic::Response<Self::Response>, 9358 + tonic::Status, 9359 + >; 8070 9360 fn call( 8071 9361 &mut self, 8072 9362 request: tonic::Request<super::KeyclickClickRequest>, ··· 8100 9390 }; 8101 9391 Box::pin(fut) 8102 9392 } 8103 - _ => Box::pin(async move { 8104 - let mut response = http::Response::new(empty_body()); 8105 - let headers = response.headers_mut(); 8106 - headers.insert( 8107 - tonic::Status::GRPC_STATUS, 8108 - (tonic::Code::Unimplemented as i32).into(), 8109 - ); 8110 - headers.insert( 8111 - http::header::CONTENT_TYPE, 8112 - tonic::metadata::GRPC_CONTENT_TYPE, 8113 - ); 8114 - Ok(response) 8115 - }), 9393 + _ => { 9394 + Box::pin(async move { 9395 + let mut response = http::Response::new(empty_body()); 9396 + let headers = response.headers_mut(); 9397 + headers 9398 + .insert( 9399 + tonic::Status::GRPC_STATUS, 9400 + (tonic::Code::Unimplemented as i32).into(), 9401 + ); 9402 + headers 9403 + .insert( 9404 + http::header::CONTENT_TYPE, 9405 + tonic::metadata::GRPC_CONTENT_TYPE, 9406 + ); 9407 + Ok(response) 9408 + }) 9409 + } 8116 9410 } 8117 9411 } 8118 9412 } ··· 8173 9467 dead_code, 8174 9468 missing_docs, 8175 9469 clippy::wildcard_imports, 8176 - clippy::let_unit_value 9470 + clippy::let_unit_value, 8177 9471 )] 9472 + use tonic::codegen::*; 8178 9473 use tonic::codegen::http::Uri; 8179 - use tonic::codegen::*; 8180 9474 #[derive(Debug, Clone)] 8181 9475 pub struct SystemServiceClient<T> { 8182 9476 inner: tonic::client::Grpc<T>, ··· 8220 9514 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody, 8221 9515 >, 8222 9516 >, 8223 - <T as tonic::codegen::Service<http::Request<tonic::body::BoxBody>>>::Error: 8224 - Into<StdError> + std::marker::Send + std::marker::Sync, 9517 + <T as tonic::codegen::Service< 9518 + http::Request<tonic::body::BoxBody>, 9519 + >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync, 8225 9520 { 8226 9521 SystemServiceClient::new(InterceptedService::new(inner, interceptor)) 8227 9522 } ··· 8259 9554 pub async fn get_rockbox_version( 8260 9555 &mut self, 8261 9556 request: impl tonic::IntoRequest<super::GetRockboxVersionRequest>, 8262 - ) -> std::result::Result<tonic::Response<super::GetRockboxVersionResponse>, tonic::Status> 8263 - { 8264 - self.inner.ready().await.map_err(|e| { 8265 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 8266 - })?; 9557 + ) -> std::result::Result< 9558 + tonic::Response<super::GetRockboxVersionResponse>, 9559 + tonic::Status, 9560 + > { 9561 + self.inner 9562 + .ready() 9563 + .await 9564 + .map_err(|e| { 9565 + tonic::Status::unknown( 9566 + format!("Service was not ready: {}", e.into()), 9567 + ) 9568 + })?; 8267 9569 let codec = tonic::codec::ProstCodec::default(); 8268 9570 let path = http::uri::PathAndQuery::from_static( 8269 9571 "/rockbox.v1alpha1.SystemService/GetRockboxVersion", 8270 9572 ); 8271 9573 let mut req = request.into_request(); 8272 - req.extensions_mut().insert(GrpcMethod::new( 8273 - "rockbox.v1alpha1.SystemService", 8274 - "GetRockboxVersion", 8275 - )); 9574 + req.extensions_mut() 9575 + .insert( 9576 + GrpcMethod::new( 9577 + "rockbox.v1alpha1.SystemService", 9578 + "GetRockboxVersion", 9579 + ), 9580 + ); 8276 9581 self.inner.unary(req, path, codec).await 8277 9582 } 8278 9583 pub async fn get_global_status( 8279 9584 &mut self, 8280 9585 request: impl tonic::IntoRequest<super::GetGlobalStatusRequest>, 8281 - ) -> std::result::Result<tonic::Response<super::GetGlobalStatusResponse>, tonic::Status> 8282 - { 8283 - self.inner.ready().await.map_err(|e| { 8284 - tonic::Status::unknown(format!("Service was not ready: {}", e.into())) 8285 - })?; 9586 + ) -> std::result::Result< 9587 + tonic::Response<super::GetGlobalStatusResponse>, 9588 + tonic::Status, 9589 + > { 9590 + self.inner 9591 + .ready() 9592 + .await 9593 + .map_err(|e| { 9594 + tonic::Status::unknown( 9595 + format!("Service was not ready: {}", e.into()), 9596 + ) 9597 + })?; 8286 9598 let codec = tonic::codec::ProstCodec::default(); 8287 9599 let path = http::uri::PathAndQuery::from_static( 8288 9600 "/rockbox.v1alpha1.SystemService/GetGlobalStatus", 8289 9601 ); 8290 9602 let mut req = request.into_request(); 8291 - req.extensions_mut().insert(GrpcMethod::new( 8292 - "rockbox.v1alpha1.SystemService", 8293 - "GetGlobalStatus", 8294 - )); 9603 + req.extensions_mut() 9604 + .insert( 9605 + GrpcMethod::new("rockbox.v1alpha1.SystemService", "GetGlobalStatus"), 9606 + ); 8295 9607 self.inner.unary(req, path, codec).await 8296 9608 } 8297 9609 } ··· 8303 9615 dead_code, 8304 9616 missing_docs, 8305 9617 clippy::wildcard_imports, 8306 - clippy::let_unit_value 9618 + clippy::let_unit_value, 8307 9619 )] 8308 9620 use tonic::codegen::*; 8309 9621 /// Generated trait containing gRPC methods that should be implemented for use with SystemServiceServer. ··· 8312 9624 async fn get_rockbox_version( 8313 9625 &self, 8314 9626 request: tonic::Request<super::GetRockboxVersionRequest>, 8315 - ) -> std::result::Result<tonic::Response<super::GetRockboxVersionResponse>, tonic::Status>; 9627 + ) -> std::result::Result< 9628 + tonic::Response<super::GetRockboxVersionResponse>, 9629 + tonic::Status, 9630 + >; 8316 9631 async fn get_global_status( 8317 9632 &self, 8318 9633 request: tonic::Request<super::GetGlobalStatusRequest>, 8319 - ) -> std::result::Result<tonic::Response<super::GetGlobalStatusResponse>, tonic::Status>; 9634 + ) -> std::result::Result< 9635 + tonic::Response<super::GetGlobalStatusResponse>, 9636 + tonic::Status, 9637 + >; 8320 9638 } 8321 9639 #[derive(Debug)] 8322 9640 pub struct SystemServiceServer<T> { ··· 8339 9657 max_encoding_message_size: None, 8340 9658 } 8341 9659 } 8342 - pub fn with_interceptor<F>(inner: T, interceptor: F) -> InterceptedService<Self, F> 9660 + pub fn with_interceptor<F>( 9661 + inner: T, 9662 + interceptor: F, 9663 + ) -> InterceptedService<Self, F> 8343 9664 where 8344 9665 F: tonic::service::Interceptor, 8345 9666 { ··· 8394 9715 "/rockbox.v1alpha1.SystemService/GetRockboxVersion" => { 8395 9716 #[allow(non_camel_case_types)] 8396 9717 struct GetRockboxVersionSvc<T: SystemService>(pub Arc<T>); 8397 - impl<T: SystemService> 8398 - tonic::server::UnaryService<super::GetRockboxVersionRequest> 8399 - for GetRockboxVersionSvc<T> 8400 - { 9718 + impl< 9719 + T: SystemService, 9720 + > tonic::server::UnaryService<super::GetRockboxVersionRequest> 9721 + for GetRockboxVersionSvc<T> { 8401 9722 type Response = super::GetRockboxVersionResponse; 8402 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 9723 + type Future = BoxFuture< 9724 + tonic::Response<Self::Response>, 9725 + tonic::Status, 9726 + >; 8403 9727 fn call( 8404 9728 &mut self, 8405 9729 request: tonic::Request<super::GetRockboxVersionRequest>, 8406 9730 ) -> Self::Future { 8407 9731 let inner = Arc::clone(&self.0); 8408 9732 let fut = async move { 8409 - <T as SystemService>::get_rockbox_version(&inner, request).await 9733 + <T as SystemService>::get_rockbox_version(&inner, request) 9734 + .await 8410 9735 }; 8411 9736 Box::pin(fut) 8412 9737 } ··· 8436 9761 "/rockbox.v1alpha1.SystemService/GetGlobalStatus" => { 8437 9762 #[allow(non_camel_case_types)] 8438 9763 struct GetGlobalStatusSvc<T: SystemService>(pub Arc<T>); 8439 - impl<T: SystemService> 8440 - tonic::server::UnaryService<super::GetGlobalStatusRequest> 8441 - for GetGlobalStatusSvc<T> 8442 - { 9764 + impl< 9765 + T: SystemService, 9766 + > tonic::server::UnaryService<super::GetGlobalStatusRequest> 9767 + for GetGlobalStatusSvc<T> { 8443 9768 type Response = super::GetGlobalStatusResponse; 8444 - type Future = BoxFuture<tonic::Response<Self::Response>, tonic::Status>; 9769 + type Future = BoxFuture< 9770 + tonic::Response<Self::Response>, 9771 + tonic::Status, 9772 + >; 8445 9773 fn call( 8446 9774 &mut self, 8447 9775 request: tonic::Request<super::GetGlobalStatusRequest>, 8448 9776 ) -> Self::Future { 8449 9777 let inner = Arc::clone(&self.0); 8450 9778 let fut = async move { 8451 - <T as SystemService>::get_global_status(&inner, request).await 9779 + <T as SystemService>::get_global_status(&inner, request) 9780 + .await 8452 9781 }; 8453 9782 Box::pin(fut) 8454 9783 } ··· 8475 9804 }; 8476 9805 Box::pin(fut) 8477 9806 } 8478 - _ => Box::pin(async move { 8479 - let mut response = http::Response::new(empty_body()); 8480 - let headers = response.headers_mut(); 8481 - headers.insert( 8482 - tonic::Status::GRPC_STATUS, 8483 - (tonic::Code::Unimplemented as i32).into(), 8484 - ); 8485 - headers.insert( 8486 - http::header::CONTENT_TYPE, 8487 - tonic::metadata::GRPC_CONTENT_TYPE, 8488 - ); 8489 - Ok(response) 8490 - }), 9807 + _ => { 9808 + Box::pin(async move { 9809 + let mut response = http::Response::new(empty_body()); 9810 + let headers = response.headers_mut(); 9811 + headers 9812 + .insert( 9813 + tonic::Status::GRPC_STATUS, 9814 + (tonic::Code::Unimplemented as i32).into(), 9815 + ); 9816 + headers 9817 + .insert( 9818 + http::header::CONTENT_TYPE, 9819 + tonic::metadata::GRPC_CONTENT_TYPE, 9820 + ); 9821 + Ok(response) 9822 + }) 9823 + } 8491 9824 } 8492 9825 } 8493 9826 }
+1
crates/server/Cargo.toml
··· 40 40 tokio = {version = "1.36.0", features = ["full"]} 41 41 url = "2.3.1" 42 42 urlencoding = "2.1.3" 43 + tracing = { workspace = true }
+3 -2
crates/server/src/http.rs
··· 1 1 use anyhow::Error; 2 2 use owo_colors::OwoColorize; 3 3 use rockbox_library::entity::track::Track; 4 + use tracing::{debug, error}; 4 5 use rockbox_sys::{ 5 6 self as rb, 6 7 types::{mp3_entry::Mp3Entry, tree::Entry}, ··· 357 358 rb::system::sleep(rb::HZ); 358 359 } 359 360 Err(e) => { 360 - eprintln!("Error accepting connection: {}", e); 361 + error!("Error accepting connection: {}", e); 361 362 break; 362 363 } 363 364 } ··· 391 392 player: Arc<Mutex<Option<Box<dyn Player + Send>>>>, 392 393 kv: Arc<Mutex<KV<Track>>>, 393 394 ) { 394 - println!("{} {}", method.bright_cyan(), path); 395 + debug!("{} {}", method, path); 395 396 match self.router.route(method, path) { 396 397 Some((handler, params)) => { 397 398 let mut response = Response::new();
+10 -9
crates/server/src/lib.rs
··· 1 1 use anyhow::Error; 2 2 use handlers::*; 3 + use tracing::{error, warn}; 3 4 4 5 use http::RockboxHttpServer; 5 6 use lazy_static::lazy_static; ··· 59 60 pub extern "C" fn debugfn(args: *const c_char, value: c_int) { 60 61 let c_str = unsafe { std::ffi::CStr::from_ptr(args) }; 61 62 let str_slice = c_str.to_str().unwrap(); 62 - println!("{} {}", str_slice, value); 63 + tracing::debug!("{} {}", str_slice, value); 63 64 } 64 65 65 66 #[no_mangle] ··· 67 68 match rockbox_settings::load_settings(None) { 68 69 Ok(_) => {} 69 70 Err(e) => { 70 - println!("Warning loading settings: {}", e); 71 + warn!("Warning loading settings: {}", e); 71 72 } 72 73 } 73 74 ··· 134 135 match app.listen() { 135 136 Ok(_) => {} 136 137 Err(e) => { 137 - eprintln!("Error starting server: {}", e); 138 + error!("Error starting server: {}", e); 138 139 } 139 140 } 140 141 } ··· 219 220 match runtime.block_on(rockbox_rpc::server::start(cmd_tx.clone())) { 220 221 Ok(_) => {} 221 222 Err(e) => { 222 - eprintln!("Error starting server: {}", e); 223 + error!("Error starting server: {}", e); 223 224 } 224 225 } 225 226 }); ··· 232 233 match runtime.block_on(rockbox_graphql::server::start(cloned_cmd_tx.clone())) { 233 234 Ok(_) => {} 234 235 Err(e) => { 235 - eprintln!("Error starting server: {}", e); 236 + error!("Error starting server: {}", e); 236 237 } 237 238 } 238 239 }); ··· 247 248 move || match async_std::task::block_on(MprisServer::start()) { 248 249 Ok(_) => {} 249 250 Err(e) => { 250 - eprintln!("Error starting mpris server: {}", e); 251 + error!("Error starting mpris server: {}", e); 251 252 } 252 253 }, 253 254 ); ··· 261 262 match runtime.block_on(MpdServer::start()) { 262 263 Ok(_) => {} 263 264 Err(e) => { 264 - eprintln!("Error starting mpd server: {}", e); 265 + error!("Error starting mpd server: {}", e); 265 266 } 266 267 } 267 268 }); ··· 398 399 .block_on(scrobble(cloned_track, cloned_pool.clone())) 399 400 { 400 401 Ok(_) => {} 401 - Err(e) => eprintln!("{}", e), 402 + Err(e) => error!("{}", e), 402 403 } 403 404 }); 404 405 scrobbled_tracks.insert(metadata.id.clone()); ··· 536 537 if let Some(album) = album { 537 538 match rockbox_rocksky::scrobble(track, album).await { 538 539 Ok(_) => {} 539 - Err(e) => eprintln!("Failed to scrobble {}", e), 540 + Err(e) => error!("Failed to scrobble {}", e), 540 541 }; 541 542 } 542 543 }
+12 -1
crates/settings/src/lib.rs
··· 1 1 use anyhow::Error; 2 - use rockbox_sys::{self as rb, types::user_settings::NewGlobalSettings}; 2 + use rockbox_sys::{self as rb, sound::pcm, types::user_settings::NewGlobalSettings}; 3 3 4 4 pub fn load_settings(new_settings: Option<NewGlobalSettings>) -> Result<(), Error> { 5 5 let settings: NewGlobalSettings = match new_settings.clone() { ··· 27 27 } 28 28 29 29 rb::settings::save_settings(settings.clone(), new_settings.is_none()); 30 + 31 + if let Some(ref output) = settings.audio_output { 32 + if output == "fifo" { 33 + let path = settings 34 + .fifo_path 35 + .as_deref() 36 + .unwrap_or("/tmp/rockbox.fifo"); 37 + pcm::fifo_set_path(path); 38 + pcm::switch_sink(pcm::PCM_SINK_FIFO); 39 + } 40 + } 30 41 31 42 rb::settings::apply_audio_settings(); 32 43
+2
crates/sys/src/lib.rs
··· 1146 1146 fn pcm_is_playing() -> c_uchar; 1147 1147 fn pcm_play_lock(); 1148 1148 fn pcm_play_unlock(); 1149 + fn pcm_switch_sink(sink: c_int) -> c_uchar; 1150 + fn pcm_fifo_set_path(path: *const c_char); 1149 1151 fn beep_play(frequency: c_uint, duration: c_uint, amplitude: c_uint); 1150 1152 fn dsp_set_crossfeed_type(r#type: c_int); 1151 1153 fn dsp_eq_enable(enable: c_uchar);
+16 -1
crates/sys/src/sound/pcm.rs
··· 1 - use std::ffi::c_void; 1 + use std::ffi::{c_void, CString}; 2 2 3 3 use crate::{PcmPlayCallbackType, PcmStatusCallbackType}; 4 + 5 + pub const PCM_SINK_BUILTIN: i32 = 0; 6 + pub const PCM_SINK_FIFO: i32 = 1; 4 7 5 8 pub fn apply_settings() { 6 9 unsafe { ··· 43 46 crate::pcm_play_unlock(); 44 47 } 45 48 } 49 + 50 + pub fn switch_sink(sink: i32) -> bool { 51 + unsafe { crate::pcm_switch_sink(sink) != 0 } 52 + } 53 + 54 + pub fn fifo_set_path(path: &str) { 55 + let cpath = CString::new(path).expect("path must not contain null bytes"); 56 + unsafe { crate::pcm_fifo_set_path(cpath.as_ptr()) } 57 + // Keep alive until C code finishes using it — it's only read during init, 58 + // so leaking is acceptable here for a startup-time config call. 59 + std::mem::forget(cpath); 60 + }
+6
crates/sys/src/types/user_settings.rs
··· 677 677 pub eq_band_settings: Option<Vec<EqBandSetting>>, 678 678 pub replaygain_settings: Option<ReplaygainSettings>, 679 679 pub compressor_settings: Option<CompressorSettings>, 680 + /// Audio output sink: "builtin" (default) or "fifo" 681 + pub audio_output: Option<String>, 682 + /// Path for the FIFO sink, e.g. "/tmp/rockbox.fifo" or "-" for stdout 683 + pub fifo_path: Option<String>, 680 684 } 681 685 682 686 impl From<UserSettings> for NewGlobalSettings { ··· 710 714 eq_band_settings: Some(settings.eq_band_settings), 711 715 replaygain_settings: Some(settings.replaygain_settings), 712 716 compressor_settings: Some(settings.compressor_settings), 717 + audio_output: None, 718 + fifo_path: None, 713 719 } 714 720 } 715 721 }
+1
crates/typesense/Cargo.toml
··· 17 17 serde.workspace = true 18 18 serde_json.workspace = true 19 19 uuid.workspace = true 20 + tracing = { workspace = true }
+18 -17
crates/typesense/src/client.rs
··· 1 1 use crate::types::*; 2 2 use anyhow::Error; 3 3 use reqwest::Client; 4 + use tracing::{debug, info, warn}; 4 5 5 6 pub async fn create_tracks_collection() -> Result<(), Error> { 6 7 let client = Client::new(); ··· 38 39 39 40 let api_key = std::env::var("RB_TYPESENSE_API_KEY"); 40 41 if api_key.is_err() { 41 - println!("Warning: RB_TYPESENSE_API_KEY is not set."); 42 + warn!("RB_TYPESENSE_API_KEY is not set."); 42 43 return Ok(()); 43 44 } 44 45 let api_key = api_key.unwrap(); ··· 49 50 .send() 50 51 .await?; 51 52 52 - println!("Create tracks collection response: {}", res.status()); 53 + debug!("Create tracks collection response: {}", res.status()); 53 54 54 55 Ok(()) 55 56 } ··· 78 79 79 80 let api_key = std::env::var("RB_TYPESENSE_API_KEY"); 80 81 if api_key.is_err() { 81 - println!("Warning: RB_TYPESENSE_API_KEY is not set."); 82 + warn!("RB_TYPESENSE_API_KEY is not set."); 82 83 return Ok(()); 83 84 } 84 85 let api_key = api_key.unwrap(); ··· 89 90 .send() 90 91 .await?; 91 92 92 - println!("Create albums collection response: {}", res.status()); 93 + debug!("Create albums collection response: {}", res.status()); 93 94 94 95 Ok(()) 95 96 } ··· 113 114 114 115 let api_key = std::env::var("RB_TYPESENSE_API_KEY"); 115 116 if api_key.is_err() { 116 - println!("Warning: RB_TYPESENSE_API_KEY is not set."); 117 + warn!("RB_TYPESENSE_API_KEY is not set."); 117 118 return Ok(()); 118 119 } 119 120 let api_key = api_key.unwrap(); ··· 124 125 .send() 125 126 .await?; 126 127 127 - println!("Create artists collection response: {}", res.status()); 128 + debug!("Create artists collection response: {}", res.status()); 128 129 129 130 Ok(()) 130 131 } ··· 145 146 146 147 let api_key = std::env::var("RB_TYPESENSE_API_KEY"); 147 148 if api_key.is_err() { 148 - println!("Warning: RB_TYPESENSE_API_KEY is not set."); 149 + warn!("RB_TYPESENSE_API_KEY is not set."); 149 150 return Ok(()); 150 151 } 151 152 let api_key = api_key.unwrap(); ··· 160 161 .send() 161 162 .await?; 162 163 163 - println!("Insert tracks response: {}", res.status()); 164 + info!("Insert tracks response: {}", res.status()); 164 165 165 166 Ok(()) 166 167 } ··· 181 182 182 183 let api_key = std::env::var("RB_TYPESENSE_API_KEY"); 183 184 if api_key.is_err() { 184 - println!("Warning: RB_TYPESENSE_API_KEY is not set."); 185 + warn!("RB_TYPESENSE_API_KEY is not set."); 185 186 return Ok(()); 186 187 } 187 188 let api_key = api_key.unwrap(); ··· 196 197 .send() 197 198 .await?; 198 199 199 - println!("Insert albums response: {}", res.status()); 200 + info!("Insert albums response: {}", res.status()); 200 201 201 202 Ok(()) 202 203 } ··· 217 218 218 219 let api_key = std::env::var("RB_TYPESENSE_API_KEY"); 219 220 if api_key.is_err() { 220 - println!("Warning: RB_TYPESENSE_API_KEY is not set."); 221 + warn!("RB_TYPESENSE_API_KEY is not set."); 221 222 return Ok(()); 222 223 } 223 224 let api_key = api_key.unwrap(); ··· 232 233 .send() 233 234 .await?; 234 235 235 - println!("Insert artists response: {}", res.status()); 236 + info!("Insert artists response: {}", res.status()); 236 237 237 238 Ok(()) 238 239 } ··· 247 248 248 249 let api_key = std::env::var("RB_TYPESENSE_API_KEY"); 249 250 if api_key.is_err() { 250 - println!("Warning: RB_TYPESENSE_API_KEY is not set."); 251 + warn!("RB_TYPESENSE_API_KEY is not set."); 251 252 return Ok(None); 252 253 } 253 254 let api_key = api_key.unwrap(); ··· 272 273 match serde_json::from_str::<TrackResult>(&text) { 273 274 Ok(result) => Ok(Some(result)), 274 275 Err(e) => { 275 - eprintln!("Failed to parse Typesense response: {}", e); 276 - eprintln!("Response body: {}", text); 276 + warn!("Failed to parse Typesense response: {}", e); 277 + warn!("Response body: {}", text); 277 278 Err(e.into()) 278 279 } 279 280 } ··· 289 290 290 291 let api_key = std::env::var("RB_TYPESENSE_API_KEY"); 291 292 if api_key.is_err() { 292 - println!("Warning: RB_TYPESENSE_API_KEY is not set."); 293 + warn!("RB_TYPESENSE_API_KEY is not set."); 293 294 return Ok(None); 294 295 } 295 296 let api_key = api_key.unwrap(); ··· 323 324 324 325 let api_key = std::env::var("RB_TYPESENSE_API_KEY"); 325 326 if api_key.is_err() { 326 - println!("Warning: RB_TYPESENSE_API_KEY is not set."); 327 + warn!("RB_TYPESENSE_API_KEY is not set."); 327 328 return Ok(None); 328 329 } 329 330 let api_key = api_key.unwrap();
+4 -3
crates/typesense/src/lib.rs
··· 2 2 fs, 3 3 process::{Command, Stdio}, 4 4 }; 5 + use tracing::info; 5 6 6 7 pub mod client; 7 8 pub mod types; ··· 30 31 if !data_dir.join("api-key").exists() { 31 32 let api_key = uuid::Uuid::new_v4().to_string(); 32 33 fs::write(data_dir.join("api-key"), &api_key)?; 33 - println!("Generated new Typesense API key: {}", api_key); 34 + info!("Generated new Typesense API key: {}", api_key); 34 35 if std::env::var("RB_TYPESENSE_API_KEY").is_err() { 35 36 std::env::set_var("RB_TYPESENSE_API_KEY", &api_key); 36 37 } 37 38 } else { 38 39 let api_key = fs::read_to_string(data_dir.join("api-key"))?; 39 - println!("Using existing Typesense API key: {}", api_key); 40 + info!("Using existing Typesense API key: {}", api_key); 40 41 if std::env::var("RB_TYPESENSE_API_KEY").is_err() { 41 42 std::env::set_var("RB_TYPESENSE_API_KEY", &api_key); 42 43 } 43 44 } 44 45 45 46 if cmd.wait()?.success() { 46 - println!("Typesense server is already installed and available in PATH."); 47 + info!("Typesense server is already installed and available in PATH."); 47 48 return Ok(()); 48 49 } 49 50
+3
firmware/SOURCES
··· 535 535 pcm_sampr.c 536 536 pcm.c 537 537 pcm_mixer.c 538 + #if (CONFIG_PLATFORM & PLATFORM_HOSTED) 539 + target/hosted/pcm-fifo.c 540 + #endif 538 541 #ifdef HAVE_SW_VOLUME_CONTROL 539 542 pcm_sw_volume.c 540 543 #endif /* HAVE_SW_VOLUME_CONTROL */
+9
firmware/export/pcm_sink.h
··· 52 52 53 53 enum pcm_sink_ids { 54 54 PCM_SINK_BUILTIN = 0, 55 + #if (CONFIG_PLATFORM & PLATFORM_HOSTED) 56 + PCM_SINK_FIFO, 57 + #endif 55 58 PCM_SINK_NUM 56 59 }; 57 60 58 61 /* defined in each platform pcm source */ 59 62 extern struct pcm_sink builtin_pcm_sink; 63 + 64 + #if (CONFIG_PLATFORM & PLATFORM_HOSTED) 65 + /* FIFO/pipe sink — writes raw S16LE stereo PCM to a named FIFO or stdout */ 66 + extern struct pcm_sink fifo_pcm_sink; 67 + void pcm_fifo_set_path(const char *path); 68 + #endif
+4
firmware/pcm.c
··· 31 31 #include "general.h" 32 32 #include "pcm-internal.h" 33 33 #include "pcm_mixer.h" 34 + #include "pcm_sink.h" 34 35 35 36 /** 36 37 * Aspects implemented in the target-specific portion: ··· 79 80 80 81 static struct pcm_sink* sinks[PCM_SINK_NUM] = { 81 82 [PCM_SINK_BUILTIN] = &builtin_pcm_sink, 83 + #if (CONFIG_PLATFORM & PLATFORM_HOSTED) 84 + [PCM_SINK_FIFO] = &fifo_pcm_sink, 85 + #endif 82 86 }; 83 87 static enum pcm_sink_ids cur_sink = PCM_SINK_BUILTIN; 84 88