functional

package
v1.4.9 Latest Latest
Warning

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

Go to latest
Published: Jul 23, 2017 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Compose

func Compose(arg0 string, fcs ...func(string) (string, error)) func() (string, error)

Compose multiple (string) -> (string, error) functions.

func Curry

func Curry(arg string, f func(string) (string, error)) func() (string, error)

Curry a single-arg string -> (string, error) function. The returned value is effectively a function with no arguments.

func FirstWithoutError

func FirstWithoutError(fcs ...func() (string, error)) (string, error)

FirstWithoutError tries the passed functions in order and returns the first value obtained without error. If all functions have an error, FirstWithoutError returns itself an encompassing error.

Types

This section is empty.

Jump to

Keyboard shortcuts

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