Generalizations to support protobuf and czmq++.