<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
		xmlns:xhtml="http://www.w3.org/1999/xhtml"
>

<channel>
	<title>tech-memo &#187; itunes</title>
	<atom:link href="http://tech.hapicky.com/archives/tag/itunes/feed" rel="self" type="application/rss+xml" />
	<link>http://tech.hapicky.com</link>
	<description>ソフトウェアエンジニアリングに関するメモ書き</description>
	<lastBuildDate>Tue, 02 Feb 2010 05:42:30 +0000</lastBuildDate>
	<language>ja</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.4</generator>
<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://tech.hapicky.com/archives/tag/itunes/feed" />
		<item>
		<title>rubyでiTunesStore検索</title>
		<link>http://tech.hapicky.com/archives/6</link>
		<comments>http://tech.hapicky.com/archives/6#comments</comments>
		<pubDate>Fri, 04 Jan 2008 16:23:54 +0000</pubDate>
		<dc:creator>hapicky</dc:creator>
				<category><![CDATA[未分類]]></category>
		<category><![CDATA[itunes]]></category>
		<category><![CDATA[ruby]]></category>

		<guid isPermaLink="false">/tech-memo/?p=6</guid>
		<description><![CDATA[iTunesStoreを検索するrubyスクリプトを作ってみました。 itunesstore.zip 使い方は、 上記zipを展開し、lib/itunes_store.rbをロードパスに置いてください。 jsonライブラリに依存しているので、gemでインストールするなどしてください。 以下のように記述することで、検索結果をHashの配列で取得できます。 require 'itunes_store' itunes = ItunesStore::Search.new results = itunes.search('beatles', :media =&#62; ItunesStore::Media::MUSIC, :entity =&#62; 'album') お気づきの点などあればご指摘お願いします。]]></description>
			<content:encoded><![CDATA[<p>iTunesStoreを検索するrubyスクリプトを作ってみました。<br />
<a href="http://macmini.local/tech-memo/wp-content/uploads/2008/01/itunesstore.zip" title="itunesstore.zip">itunesstore.zip</a><br />
使い方は、
<ul>
<li>上記zipを展開し、lib/itunes_store.rbをロードパスに置いてください。</li>
<li><a href="http://json.rubyforge.org/">jsonライブラリ</a>に依存しているので、gemでインストールするなどしてください。</li>
<li>以下のように記述することで、検索結果をHashの配列で取得できます。
<pre>require 'itunes_store'
itunes = ItunesStore::Search.new
results = itunes.search('beatles', :media =&gt; ItunesStore::Media::MUSIC,
			:entity =&gt; 'album')</pre>
</li>
</ul>
<p>お気づきの点などあればご指摘お願いします。</p>
]]></content:encoded>
			<wfw:commentRss>http://tech.hapicky.com/archives/6/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://tech.hapicky.com/archives/6" />
	</item>
		<item>
		<title>iTunes StoreをJavascriptで検索する。</title>
		<link>http://tech.hapicky.com/archives/3</link>
		<comments>http://tech.hapicky.com/archives/3#comments</comments>
		<pubDate>Fri, 04 Jan 2008 04:01:26 +0000</pubDate>
		<dc:creator>hapicky</dc:creator>
				<category><![CDATA[未分類]]></category>
		<category><![CDATA[itunes]]></category>
		<category><![CDATA[javascript]]></category>

		<guid isPermaLink="false">/tech-memo/?p=3</guid>
		<description><![CDATA[iTunesStoreをjavascriptで検索し、JSON形式で結果を出力するサンプルを作ってみました。これはアフィリエイターなどのパートナー用に提供されているiTunesリンクメーカーというツールを参考にしたものです。 function searchItunes(keyword) { var lang = 9; var country = 'JP'; var media = 'music'; var entity = 'album'; var limit = 20; var term = encodeURI(keyword); var output = 'json'; var url = 'http://phobos.apple.com/WebObjects/MZSearch.woa/wa/itmsSearch'; var params = 'lang=' + lang + '&#38;country=' + country + '&#38;media=' + media + '&#38;entity=' + entity + [...]]]></description>
			<content:encoded><![CDATA[<p>iTunesStoreをjavascriptで検索し、JSON形式で結果を出力するサンプルを作ってみました。これはアフィリエイターなどのパートナー用に提供されている<a href="http://phobos.apple.com/WebObjects/MZSearch.woa/wa/itmsSearch?lang=9&amp;country=JP">iTunesリンクメーカー</a>というツールを参考にしたものです。</p>
<pre class="brush:js">
function searchItunes(keyword) {
	var lang = 9;
	var country = 'JP';
	var media = 'music';
	var entity = 'album';
	var limit = 20;
	var term = encodeURI(keyword);
	var output = 'json';
	var url = 'http://phobos.apple.com/WebObjects/MZSearch.woa/wa/itmsSearch';
	var params = 'lang=' + lang + '&amp;country=' + country + '&amp;media=' +
		media + '&amp;entity=' + entity + '&amp;limit=' + limit + '&amp;term=' +
		term +'&amp;output=' + output;
	window.open(url + '?' + params, "_blank");
}
</pre>
<p>Perlには<a href="http://search.cpan.org/~tsibley/Net-iTMS/">Net-iTMS</a>というライブラリがあるようですが、Ruby版も作ってみようかな。</p>
]]></content:encoded>
			<wfw:commentRss>http://tech.hapicky.com/archives/3/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://tech.hapicky.com/archives/3" />
	</item>
	</channel>
</rss>

