private static string GetUrl(string type, string id, string quality, string format) { IMusic music; switch (type) { case "wy": music = new WyMusic(); break; case "xm": music = new XmMusic(); break; case "tt": music = new TtMusic(); break; case "qq": music = new TxMusic(); break; case "bd": music = new BdMusic(); break; default: return(null); } return(music.GetSongUrl(id, quality, format)); }
private static ArtistResult SearchArtist(string type, string id, string page, string size) { IMusic music; switch (type) { case "wy": music = new WyMusic(); break; case "xm": music = new XmMusic(); break; case "tt": music = new TtMusic(); break; case "qq": music = new TxMusic(); break; case "bd": music = new BdMusic(); break; default: return(null); } return(music.ArtistSearch(id, Convert.ToInt32(page), Convert.ToInt32(size))); }
private static SongResult SearchSong(string type, string id) { IMusic music; switch (type) { case "wy": music = new WyMusic(); break; case "xm": music = new XmMusic(); break; case "tt": music = new TtMusic(); break; case "qq": music = new TxMusic(); break; case "bd": music = new BdMusic(); break; default: return(null); } return(music.GetSingleSong(id)); }
private static AlbumResult AlbumSearch(string type, string id) { IMusic music; switch (type) { case "wy": music = new WyMusic(); break; case "xm": music = new XmMusic(); break; case "tt": music = new TtMusic(); break; case "qq": music = new TxMusic(); break; case "bd": music = new BdMusic(); break; default: return(null); } return(music.AlbumSearch(id)); }
private static SearchResult Search(string type, string key, string page, string size) { IMusic music; switch (type) { case "wy": music = new WyMusic(); break; case "xm": music = new XmMusic(); break; case "tt": music = new TtMusic(); break; case "qq": music = new TxMusic(); break; case "bd": music = new BdMusic(); break; default: music = new AnyMusic(); break; } return(music.SongSearch(key, Convert.ToInt32(page), Convert.ToInt32(size))); }