Skip to content

Instantly share code, notes, and snippets.

View AHartTN's full-sized avatar

Anthony Hart AHartTN

  • AH Operations
  • Hermitage, TN
View GitHub Profile
@AHartTN
AHartTN / gist:969404
Created May 12, 2011 20:46
My Dynamic JSON object converter
sealed class DynamicJsonConverter : JavaScriptConverter
{
public override object Deserialize(IDictionary<string, object> dictionary, Type type, JavaScriptSerializer serializer)
{
if (dictionary == null)
throw new ArgumentNullException("dictionary");
return type == typeof(object) ? new DynamicJsonObject(dictionary) : null;
}
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Dynamic;
using System.IO;
using System.Linq;
using System.Net;
using System.Text;
using System.Web.Script.Serialization;