thrifttestserver

package
v1.29.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 21, 2018 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(impl Interface, opts ...thrift.RegisterOption) []transport.Procedure

New prepares an implementation of the ThriftTest service for registration.

handler := ThriftTestHandler{}
dispatcher.Register(thrifttestserver.New(handler))

Types

type Interface

type Interface interface {
	TestBinary(
		ctx context.Context,
		Thing []byte,
	) ([]byte, error)

	TestByte(
		ctx context.Context,
		Thing *int8,
	) (int8, error)

	TestDouble(
		ctx context.Context,
		Thing *float64,
	) (float64, error)

	TestEnum(
		ctx context.Context,
		Thing *gauntlet.Numberz,
	) (gauntlet.Numberz, error)

	TestException(
		ctx context.Context,
		Arg *string,
	) error

	TestI32(
		ctx context.Context,
		Thing *int32,
	) (int32, error)

	TestI64(
		ctx context.Context,
		Thing *int64,
	) (int64, error)

	TestInsanity(
		ctx context.Context,
		Argument *gauntlet.Insanity,
	) (map[gauntlet.UserId]map[gauntlet.Numberz]*gauntlet.Insanity, error)

	TestList(
		ctx context.Context,
		Thing []int32,
	) ([]int32, error)

	TestMap(
		ctx context.Context,
		Thing map[int32]int32,
	) (map[int32]int32, error)

	TestMapMap(
		ctx context.Context,
		Hello *int32,
	) (map[int32]map[int32]int32, error)

	TestMulti(
		ctx context.Context,
		Arg0 *int8,
		Arg1 *int32,
		Arg2 *int64,
		Arg3 map[int16]string,
		Arg4 *gauntlet.Numberz,
		Arg5 *gauntlet.UserId,
	) (*gauntlet.Xtruct, error)

	TestMultiException(
		ctx context.Context,
		Arg0 *string,
		Arg1 *string,
	) (*gauntlet.Xtruct, error)

	TestNest(
		ctx context.Context,
		Thing *gauntlet.Xtruct2,
	) (*gauntlet.Xtruct2, error)

	TestOneway(
		ctx context.Context,
		SecondsToSleep *int32,
	) error

	TestSet(
		ctx context.Context,
		Thing map[int32]struct{},
	) (map[int32]struct{}, error)

	TestString(
		ctx context.Context,
		Thing *string,
	) (string, error)

	TestStringMap(
		ctx context.Context,
		Thing map[string]string,
	) (map[string]string, error)

	TestStruct(
		ctx context.Context,
		Thing *gauntlet.Xtruct,
	) (*gauntlet.Xtruct, error)

	TestTypedef(
		ctx context.Context,
		Thing *gauntlet.UserId,
	) (gauntlet.UserId, error)

	TestVoid(
		ctx context.Context,
	) error
}

Interface is the server-side interface for the ThriftTest service.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL