Silverlight 2.0にはLinq to JSONとかいうのが入るらしい
"Beta2 now includes LINQ to JSON support that enables you to easily query, filter, and map JSON results to .NET objects within a Silverlight application. This makes it easy to call and work with existing AJAX end-points and services published on the web."とか書いてある。
というわけで夜中についカッとなってやった。今は反省している。
コンパイル出来るというだけで1行もテストしていないww たぶんXLinqと同じで、同じオブジェクトが1つのJSON objectやJSON arrayに追加されたら、引数インスタンス自身ではなくそのcloneが追加されるとか、そういうことが起こるんだろうなあ。
しかしJsonTypeにもJsonPrimitiveにもJSONのnullに対応するものが無い。これはきっと変更されるだろうなあと思う。てことは多分今日書いたコードは多かれ少なかれ無駄になるな。