Esempio n. 1
0
 public JsonBuilder(MapperContainer mappers, TypeContainer types, ConfigContainer config,
                    ConcurrentDictionary <Type, Action <object, StringBuilder> > serializerMapper, DictReflector dictReflector)
 {
     serializers        = serializerMapper;
     this.mappers       = mappers;
     this.types         = types;
     this.config        = config;
     this.dictReflector = dictReflector;
 }
Esempio n. 2
0
 public MapEngine(TypeContainer types, MapperContainer mappers, ConfigContainer configuration,
                  CollectionBuilder colBuilder, ConcurrentDictionary <Type, Func <Type, JValue, object> > deserializers, EnumCache enumCache, DictReflector dictReflector)
 {
     this.types         = types;
     this.mappers       = mappers;
     this.configuration = configuration;
     this.colBuilder    = colBuilder;
     this.deserializers = deserializers;
     this.dictReflector = dictReflector;
     this.enumCache     = enumCache;
 }
Esempio n. 3
0
        public MapContext()
        {
            Mappers            = new MapperContainer();
            Configuration      = new ConfigContainer();
            Types              = new TypeContainer();
            CollBuilder        = new CollectionBuilder();
            SerializerMapper   = new ConcurrentDictionary <Type, Action <object, StringBuilder> >();
            DeserializerMapper = new ConcurrentDictionary <Type, Func <Type, JValue, object> >();
            DictReflector      = new DictReflector();
            var enumCache = new EnumCache();

            MapEngine = new MapEngine(Types, Mappers, Configuration, CollBuilder, DeserializerMapper, enumCache, DictReflector);
        }