v0.7.15
podcast_search
팟캐스트 검색 및 팟캐스트 RSS 피드 파싱을 위한 라이브러리입니다. iTunes 및 PodcastIndex 디렉터리를 지원하며, 챕터 및 전사본과 같은 최신 기능도 지원합니다.
36좋아요 1.4천30일 다운로드160Pub 점수
AndroidiOSmacOSWindowsLinux
팟캐스트용 iTunes 검색 API에 대한 프로그래밍 방식의 액세스를 제공하는 간단한 라이브러리입니다.
아래는 영문 원문 스냅샷입니다. 최신 내용은 GitHub에서 확인하세요.
A library for searching for podcasts, parsing podcast RSS feeds and obtaining episodes details. Supports searching via iTunes and PodcastIndex.
Search for podcasts with 'widgets' in the title and find the top podcasts. Both examples limit to 10 results and are set for the United Kingdom:
import 'package:podcast_search/podcast_search.dart';
// ignore_for_file: avoid_print
void main() async {
var search = Search();
/// Search for podcasts with 'widgets' in the title.
var results =
await search.search('widgets', country: Country.unitedKingdom, limit: 10);
/// List the name of each podcast found.
for (var result in results.items) {
print('Found podcast: ${result.trackName}');
}
/// Parse the first podcast.
final feed = results.items[0].feedUrl;
/// It is possible to get back a podcast with a missing feed URL, so check that.
if (feed != null) {
var podcast = await Feed.loadFeed(url: feed);
/// Display episode titles.
for (var episode in podcast.episodes) {
print('Episode title: ${episode.title}');
}
}
/// Find the top 10 podcasts in the UK.
var charts = await search.charts(limit: 10, country: Country.unitedKingdom);
/// List the name of each podcast found.
for (var result in charts.items) {
print('Episode title: ${result.trackName}');
}
}