Exemplo n.º 1
0
 static JsonMapper()
 {
     JsonMapper.max_nesting_depth      = 100;
     JsonMapper.array_metadata         = new Dictionary <Type, ArrayMetadata>();
     JsonMapper.conv_ops               = new Dictionary <Type, IDictionary <Type, MethodInfo> >();
     JsonMapper.object_metadata        = new Dictionary <Type, ObjectMetadata>();
     JsonMapper.type_properties        = new Dictionary <Type, IList <PropertyMetadata> >();
     JsonMapper.static_writer          = new JsonWriter();
     JsonMapper.datetime_format        = DateTimeFormatInfo.InvariantInfo;
     JsonMapper.base_exporters_table   = new Dictionary <Type, ExporterFunc>();
     JsonMapper.custom_exporters_table = new Dictionary <Type, ExporterFunc>();
     JsonMapper.base_importers_table   = new Dictionary <Type, IDictionary <Type, ImporterFunc> >();
     JsonMapper.custom_importers_table = new Dictionary <Type, IDictionary <Type, ImporterFunc> >();
     JsonMapper.RegisterBaseExporters();
     JsonMapper.RegisterBaseImporters();
 }
Exemplo n.º 2
0
 static JsonMapper()
 {
     JsonMapper.array_metadata_lock    = new object();
     JsonMapper.conv_ops_lock          = new object();
     JsonMapper.object_metadata_lock   = new object();
     JsonMapper.type_properties_lock   = new object();
     JsonMapper.static_writer_lock     = new object();
     JsonMapper.max_nesting_depth      = 100;
     JsonMapper.array_metadata         = new Hashtable();
     JsonMapper.conv_ops               = new Hashtable();
     JsonMapper.object_metadata        = new Hashtable();
     JsonMapper.type_properties        = new Hashtable();
     JsonMapper.static_writer          = new JsonWriter();
     JsonMapper.datetime_format        = DateTimeFormatInfo.InvariantInfo;
     JsonMapper.base_exporters_table   = new Hashtable();
     JsonMapper.custom_exporters_table = new Hashtable();
     JsonMapper.base_importers_table   = new Hashtable();
     JsonMapper.custom_importers_table = new Hashtable();
     JsonMapper.RegisterBaseExporters();
     JsonMapper.RegisterBaseImporters();
 }
Exemplo n.º 3
0
 static JsonMapper()
 {
     JsonMapper.RegisterBaseExporters();
     JsonMapper.RegisterBaseImporters();
 }