for python : protoc -l =$SRC_DIR -- python_out = $DST_DIR $SRC_DIR/example.proto
protoc-gen-as3
window下使用actionscript的protoc-gen-as3步骤
1)下载protoc-gen-as3-1.0.0-rc6-bin.tar.gz 并解压到d:\google\as_plugin目录
2)下载protoc-2.4.1-win32.zip 并解压到d:\google\
3)创建d:\google\as_out\目录
4)创建d:\google\message.proto
message Person {
required string name = 1;
required int32 id = 2;
}
5)开打cmd运行命令
protoc.exe --plugin=protoc-gen-as3="protoc-gen-as3.bat" --as3_out=d:\google\as_out message.proto |
目录d:\google\as_out\下自动生成initializer.as.inc,Person.as文件
6)打开flash builder创建应用,引入d:\google\as_plugin\protobuf.swc文件