Deezer SDK IOS

um6iljoc  于 11个月前  发布在  iOS
关注(0)|答案(1)|浏览(85)

我正在使用Deezer SDK for ios,我不会向Radio Deezer提出请求,所以这就是我所做的

- (void)requestRadioForListening:(NSString*)radioId {
    NSString* servicePath = [NSString stringWithFormat:@"%@/%@/%@", @"radio", radioId, @"tracks"];
    NSDictionary* params = [NSDictionary dictionaryWithObject:@"true" forKey:@"next"];
    DeezerRequest* request = [_deezerConnect createRequestWithServicePath:servicePath
                                                                   params:params
                                                                 delegate:self];
    [_deezerConnect launchAsyncRequest:request];
}

字符串
现在我想播放前一首曲目。我怎么做?要添加什么参数才能获得前一首曲目?

mtb9vblg

mtb9vblg1#

不幸的是,通过Deezer API请求电台的前一个音轨是不可能的。(有道理,你能倒回你的调频收音机吗?)。不过,您可以稍微作弊一下,看看收音机的音轨端点的结果,查找当前音轨,数组中的前一音轨就是您要搜索的音轨。当然,另一个解决方案是自己在应用程序中记住上一首曲目。

相关问题