title: How to create a dynamic message with Protocol Buffers?
body: <p>Say we want to create our message not using any preexisting .proto files and compiled out from them cpp/cxx/h files. We want to use protobuf strictly as a library. For example we got (in some only known to us format) message description: a message called <code>MyMessage</code> has to have <code>MyIntFiels</code> and optional <code>MyStringFiels</code>. How to create such message? for example fill it with simple data save to <code>.bin</code> and read from that binary its contents back?</p>
  
  <p>I looked all over <a href="https://developers.google.com/protocol-buffers/docs/reference/cpp/google.protobuf.dynamic_message" rel="nofollow">dynamic_message.h help description</a> and DescriptorPool and so on but do not see how to add/remove fields to the message as well as no way to add described on fly message to DescriptorPool.</p>
  
  <p>Can any one please explain?</p>