<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>gfx</author_name>
  <author_url>https://blog.hatena.ne.jp/gfx/</author_url>
  <blog_title>Islands in the byte stream</blog_title>
  <blog_url>https://gfx.hatenablog.com/</blog_url>
  <categories>
  </categories>
  <description>google/gson GsonでList&lt;T&gt;をデシリアライズするのがけっこう面倒くさくて、以下のようにしなければいけません*1。 Type collectionType = new TypeToken&lt;Collection&lt;Integer&gt;&gt;(){}.getType(); List&lt;Integer&gt; ints2 = gson.fromJson(json, collectionType); ところが、 List&lt;T&gt; を意味する Type 型を Class&lt;List&lt;T&gt;&gt; と Class&lt;T&gt; から作ることができればハックが不要になるはず！とおもって探したところ、かなりマジカルな方法ながら…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fgfx.hatenablog.com%2Fentry%2F2015%2F08%2F28%2F132304&quot; title=&quot;Gson.fromJson()でList&amp;lt;T&amp;gt;を返すユーティリティをどうやって定義するか - Islands in the byte stream&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>2015-08-28 13:23:04</published>
  <title>Gson.fromJson()でList&lt;T&gt;を返すユーティリティをどうやって定義するか</title>
  <type>rich</type>
  <url>https://gfx.hatenablog.com/entry/2015/08/28/132304</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
