Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on Apr 24th, 2012  |  syntax: None  |  size: 0.41 KB  |  hits: 8  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. Is it possible to merge RuntimeTypeModel's in protobuf-net
  2. public class CustomerBuffer : Buffer<Customer>
  3. {
  4.     public CustomerBuffer()
  5.     {
  6.         Add("ID");
  7.         Add("SyncID");
  8.         Add("AccountNumber");
  9.         Add("Reference");
  10.         Add("Contact");
  11.         Add("Address");
  12.         Add("CreditInformation");
  13.     }
  14. }
  15.        
  16. foreach(MetaType MT in model.GetTypes())
  17. {
  18.     InternalModel.Add(MT.Type, false);
  19. }