Files
gotsrpc/tests/nested-generics/server/handler.go
Kevin Franklin Kim 07f2bc6541 test: add shared vo's
2026-03-19 22:15:44 +01:00

28 lines
538 B
Go

package server
import (
"context"
"github.com/foomo/gotsrpc/v2/tests/common"
)
type Handler struct{}
func (h *Handler) GetValue(_ context.Context) common.Item {
return common.Item{ID: "1", Name: "test"}
}
func (h *Handler) GetWrapped(_ context.Context) common.Response[common.Item] {
return common.Response[common.Item]{
Data: common.Item{ID: "1", Name: "test"},
}
}
func (h *Handler) GetByKey(_ context.Context, key string) int {
return len(key)
}
func (h *Handler) GetName(_ context.Context) string {
return "service"
}