Пример #1
0
 public override void Initialize(ContentTypeWriterManager manager)
 {
     _manager  = manager;
     keyWriter = manager.GetTypeWriter(typeof(TKey));
     // if TValue is an object (a non generic dictionary) then we want to look up each objects writer at runtime.
     valueWriter = typeof(TValue) == typeof(object) ? null : manager.GetTypeWriter(typeof(TValue));
 }
Пример #2
0
 public override void Initialize(ContentTypeWriterManager manager)
 {
     elementWriter = manager.GetTypeWriter(typeof(T));
 }