split generator into libraries

this is in preparation for splitting the discovery logic from protobuf
logic in the emitter, which will allow tighter optimizations for each
wire format
separate discovery parser from protobuf parser
Emitter becomes Emitter/EmitterContext; emitter, template_loader are separate libs
reduce boilerplate in emitter by making global values fields on EmitterContext
Merge pull request #241 from yjbanov/marshaller-opt

Organize generator code into libraries to support experimentation with custom marshallers
Fix a discovery generation bug where fields that are types with illegal class names cause broken generated code
Merge branch 'master' of https://github.com/google/streamy-dart into illegal-names
Merge branch 'illegal-names' of https://github.com/dgresham/streamy-dart into illegal-names