1 // Copyright 2018 The Go Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style
3 // license that can be found in the LICENSE file.
16 func (a *A) AMethod(y int) *Server {
20 // FooServer is a server that provides Foo services
23 func (f *FooServer) WriteEvents(ctx context.Context, x int) error {
24 return errors.New("hey!")
33 func New(sctx context.Context, u string) (*Server, error) {
34 s := &Server{user: u, ctx: sctx}
35 s.FooServer = (*FooServer)(s)