iTunesSwiftiTunes API 的 Swift 实现
iTunesSwift 是 Swift 实现的 iTunes API。
搜索:
import ITunesSwift // Search All ITunesSwift.findAll().by("search keyword").request { (result , error) in println(result) } // Search albums (Specifiable all media and entity. Media.Music, Entity.MusicArtist, Entity.Software etc...) ITunesSwift.find(Entity.Album).by("search keyword").request { (result , error) in println(result) } // With Attributes ITunesSwift.find(Entity.Album).by(Attribute.ArtistTerm, term: "artist name").request() { (result , error) in println(result) } // With limit ITunesSwift.find(Entity.Album).by("search keyword").limit(10).request { (result , error) in println(result) }
评论