@@ -68,14 +68,17 @@ var WebRPCServices = map[string][]string{
68
68
{{ if $opts.types -}}
69
69
type {{$service.Name}} interface {
70
70
{{- range $_, $method := $service.Methods}}
71
+ {{- $deprecated := index $method.Annotations "deprecated" -}}
71
72
{{- if gt (len $method.Comments) 0 -}}
72
73
{{- range $_, $comment := $method.Comments }}
73
74
// {{ replaceAll $comment "\"" "'" }}
74
75
{{- end }}
76
+ {{- if $deprecated }}
77
+ //
78
+ {{- end }}
75
79
{{- end }}
76
- {{- $deprecated := index $method.Annotations "deprecated" -}}
77
80
{{- if $deprecated }}
78
- // Deprecated:
81
+ // Deprecated: {{ $deprecated.Value }}
79
82
{{- end }}
80
83
{{ if eq $method.StreamOutput true -}}
81
84
{{$method.Name}}(ctx context.Context{{range $_, $input := $method.Inputs}}, {{$input.Name}} {{template "field" dict "Name" $input.Name "Type" $input.Type "TypeMap" $typeMap "TypePrefix" $typePrefix "Optional" $input.Optional "TypeMeta" $input.Meta}}{{end}}, stream {{$method.Name}}StreamWriter) error
@@ -174,14 +177,17 @@ func (w *streamWriter) write(respPayload interface{}) error {
174
177
{{ range $_, $service := $services -}}
175
178
type {{$service.Name}}Client interface {
176
179
{{- range $_, $method := $service.Methods}}
180
+ {{- $deprecated := index $method.Annotations "deprecated" -}}
177
181
{{- if gt (len $method.Comments) 0 }}
178
182
{{- range $_, $comment := $method.Comments }}
179
183
// {{ replaceAll $comment "\"" "'" }}
180
184
{{- end }}
185
+ {{- if $deprecated }}
186
+ //
187
+ {{- end }}
181
188
{{- end }}
182
- {{- $deprecated := index $method.Annotations "deprecated" -}}
183
189
{{- if $deprecated }}
184
- // Deprecated:
190
+ // Deprecated: {{ $deprecated.Value }}
185
191
{{- end }}
186
192
{{ if eq $method.StreamOutput true -}}
187
193
{{$method.Name}}(ctx context.Context{{range $_, $input := $method.Inputs}}, {{$input.Name}} {{template "field" dict "Name" $input.Name "Type" $input.Type "TypeMap" $typeMap "TypePrefix" $typePrefix "Optional" $input.Optional "TypeMeta" $input.Meta}}{{end}}) ({{$method.Name}}StreamReader, error)
0 commit comments