simple

package
v0.0.0 Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2019 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddAndDoubleWithMiddlewareRequest

func AddAndDoubleWithMiddlewareRequest(client yarf.Client, i, j int) (*yarf.Msg, error)

AddAndDoubleWithMiddlewareRequest adds two numbers and doubling result by using middleware

func AddFloat32Request

func AddFloat32Request(client yarf.Client, i, j float32) (*yarf.Msg, error)

AddFloat32Request adds two float numbers

func AddFloatRequest

func AddFloatRequest(client yarf.Client, i, j float64) (*yarf.Msg, error)

AddFloatRequest adds two float numbers

func AddObserversRequest

func AddObserversRequest(client yarf.Client, i, j, observers int) int

AddObserversRequest preforms a request that multiple observes

func AddRequest

func AddRequest(client yarf.Client, i, j int) (*yarf.Msg, error)

AddRequest adds two numbers

func CatCallbackRequest

func CatCallbackRequest(client yarf.Client, arr ...string) (*yarf.Msg, error)

CatCallbackRequest concatenates an array of strings in a string by using callbacks

func CatChannelRequest

func CatChannelRequest(client yarf.Client, arr ...string) (*yarf.Msg, error)

CatChannelRequest concatenates an array of strings in a string by using channels

func CatLateCallbackRequest

func CatLateCallbackRequest(client yarf.Client, arr ...string) (*yarf.Msg, error)

CatLateCallbackRequest concatenates an array of strings in a string by using callbacks after request is resolved

func CatLateChannelRequest

func CatLateChannelRequest(client yarf.Client, arr ...string) (*yarf.Msg, error)

CatLateChannelRequest concatenates an array of strings in a string by using channels after the request has been resolved

func CatRequest

func CatRequest(client yarf.Client, arr ...string) (*yarf.Msg, error)

CatRequest concatenates an array of strings in a string

func ConcRequest

func ConcRequest(client yarf.Client, sleep int) error

GenRequest generates an empty array of len

func CopyRequest

func CopyRequest(client yarf.Client, len int) (*yarf.Msg, error)

CopyRequest makes a copy of an array of len

func Error2CallbackRequest

func Error2CallbackRequest(client yarf.Client) (err error)

Error2CallbackRequest shall return a simple error by using callbacks

func Error2ChannelRequest

func Error2ChannelRequest(client yarf.Client) (err error)

Error2ChannelRequest shall return a simple error by using channels

func ErrorRequest

func ErrorRequest(client yarf.Client) (err error)

ErrorRequest shall return a simple error

func ErrorRequest2

func ErrorRequest2(client yarf.Client) (err error)

ErrorRequest2 shall return a simple error

func GenRequest

func GenRequest(client yarf.Client, len int) (*yarf.Msg, error)

GenRequest generates an empty array of len

func LenRequest

func LenRequest(client yarf.Client, len int) (*yarf.Msg, error)

LenRequest returns the length of an array

func PanicRequest

func PanicRequest(client yarf.Client) (err error)

PanicRequest shall panic at the server side

func RunClient

func RunClient(clientTransport yarf.Transporter)

RunClient uses provided transport interface to run some tests

func SHA256Request

func SHA256Request(client yarf.Client, data []byte) (string, error)

SHA256Request sha256 data...

func StartServer

func StartServer(serverTransport yarf.Transporter, verbose bool)

StartServer starts a integration server using provided yarf transport

func StartServerWithSerializer

func StartServerWithSerializer(serverTransport yarf.Transporter, verbose bool, serializer yarf.Serializer, midware ...yarf.Middleware)

StartServerWithSerializer starts a integration server using provided yarf transport and a specific Serializer

func SubRequest

func SubRequest(client yarf.Client, i, j int) (*yarf.Msg, error)

SubRequest subtracts j from i

func SumFloat32Request

func SumFloat32Request(client yarf.Client, arr []float32) (*yarf.Msg, error)

SumFloat32Request sums an float array

func SumFloatRequest

func SumFloatRequest(client yarf.Client, arr []float64) (*yarf.Msg, error)

SumFloatRequest sums an float array

func SumRequest

func SumRequest(client yarf.Client, arr []int) (*yarf.Msg, error)

SumRequest sums an integer array

func TimeoutRequest

func TimeoutRequest(ctx context.Context, client yarf.Client, sleepMS int) (err error)

TimeoutRequest preforms a request to server to sleep, with context

func XORRequest

func XORRequest(client yarf.Client, arr0 []bool, arr1 []bool) (*yarf.Msg, error)

XORRequest xors 2 arrays

Types

type Tuple

type Tuple struct {
	Val1 int
	Val2 int
}

Tuple is a simple struct for a tuple

func SwapAndMultiplyRequest

func SwapAndMultiplyRequest(client yarf.Client, tuple Tuple, multiplier int) (res Tuple, err error)

SwapAndMultiplyRequest swap places on values in tuple

func SwapWithSerializer

func SwapWithSerializer(client yarf.Client, tuple Tuple) (res Tuple, err error)

SwapWithSerializer swap places on values in tuple

Jump to

Keyboard shortcuts

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