<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>sos_jp</author_name>
  <author_url>https://blog.hatena.ne.jp/sos_jp/</author_url>
  <blog_title>sos の 作業メモ</blog_title>
  <blog_url>https://sos.hatenablog.jp/</blog_url>
  <categories>
    <anon>iOS</anon>
  </categories>
  <description>protocolの@optionalなメソッドが実装されているかどうかを調べる方法。 プログラミングガイドで目にして、なるほど、こうやって古いバージョンでも動くようにつくるのかと関心していたのですが、いざとなると全く思い出せなかったのでメモ。 NSObject の respondsToSelector: を使う if([obj respondsToSelector:@selector(hogehoge)]){ [obj hogehoge]; } みたいな感じ。</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fsos.hatenablog.jp%2Fentry%2F2013%2F02%2F13%2F150631&quot; title=&quot;selectorが実装されているかどうかを調べる - sos の 作業メモ&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2013-02-13 15:06:31</published>
  <title>selectorが実装されているかどうかを調べる</title>
  <type>rich</type>
  <url>https://sos.hatenablog.jp/entry/2013/02/13/150631</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
