mirror of
https://github.com/foomo/gotsrpc.git
synced 2025-10-16 12:35:35 +00:00
23 lines
347 B
Go
23 lines
347 B
Go
package demo
|
|
|
|
type Err struct {
|
|
Message string `json:"message"`
|
|
}
|
|
|
|
type ScalarInPlace string
|
|
|
|
type Demo struct {
|
|
Bla bool
|
|
}
|
|
|
|
func (d *Demo) Hello(name string) (string, *Err) {
|
|
if name == "Peter" {
|
|
return "", &Err{"fuck you Peter I do not like you"}
|
|
}
|
|
return "Hello from the server: " + name, nil
|
|
}
|
|
|
|
func (d *Demo) nothingInNothinOut() {
|
|
|
|
}
|