18 lines
384 B
Go
18 lines
384 B
Go
package main
|
|
|
|
import (
|
|
context "context"
|
|
)
|
|
|
|
var buildinglist = &KeyList{}
|
|
|
|
// UnimplementedBuildingServer can be embedded to have forward compatible implementations.
|
|
type buildingserver struct {
|
|
}
|
|
|
|
func (bs *buildingserver) Name(ctx context.Context, req *Request) (*Reply, error) {
|
|
reply := &Reply{}
|
|
reply.Message = string(GetRandomKey(buildinglist).([]byte))
|
|
return reply, nil
|
|
}
|