mirror of
https://github.com/arkadiyt/protodump.git
synced 2026-10-24 11:09:38 +02:00
Use fully qualified names for inputs
This commit is contained in:
1 parent
446d6a6c52
commit
63401cf45c
2 files changed
+6
-4
No files matched your search
@@ -5,8 +5,8 @@ package hello.world;
|
|||||||
option go_package = "./;helloworld";
|
option go_package = "./;helloworld";
|
||||||
|
|
||||||
service Greeter {
|
service Greeter {
|
||||||
rpc SayHello (HelloRequest) returns (HelloReply) {}
|
rpc SayHello (.hello.world.HelloRequest) returns (.hello.world.HelloReply) {}
|
||||||
rpc StreamMethodServer (StreamRequest) returns (stream StreamReply) {}
|
rpc StreamMethodServer (.hello.world.StreamRequest) returns (stream .hello.world.StreamReply) {}
|
||||||
}
|
}
|
||||||
|
|
||||||
message Reserved {
|
message Reserved {
|
||||||
|
|||||||
@@ -55,12 +55,14 @@ func (pd *ProtoDefinition) writeMethod(method protoreflect.MethodDescriptor) {
|
|||||||
if method.IsStreamingClient() {
|
if method.IsStreamingClient() {
|
||||||
pd.write("stream ")
|
pd.write("stream ")
|
||||||
}
|
}
|
||||||
pd.write(string(method.Input().Name()))
|
pd.write(".")
|
||||||
|
pd.write(string(method.Input().FullName()))
|
||||||
pd.write(") returns (")
|
pd.write(") returns (")
|
||||||
if method.IsStreamingServer() {
|
if method.IsStreamingServer() {
|
||||||
pd.write("stream ")
|
pd.write("stream ")
|
||||||
}
|
}
|
||||||
pd.write(string(method.Output().Name()))
|
pd.write(".")
|
||||||
|
pd.write(string(method.Output().FullName()))
|
||||||
pd.write(") {}\n")
|
pd.write(") {}\n")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user