1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use url::Url;

use crate::{SongId, QQMusicApi};

pub trait QueryLyric {
    fn query_lyric(&self, song: &str) -> Url;
}

impl QueryLyric for QQMusicApi {
    fn query_lyric(&self,  mid: &str) -> Url {
        let mut url = self.base_url.clone();
        url.set_path("/lyric");
        url.set_query(Some(&SongId::Songmid(mid).to_string()));
        url
    }
}

pub use crate::types::lyric::QueryLyricResp;