sorter

package
Version: v0.0.0-...-a7167af Latest Latest
Warning

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

Go to latest
Published: Nov 25, 2020 License: MIT, MIT Imports: 0 Imported by: 8

README

sorter

go get -u myitcv.io/sorter

You probably want to look at the README.md for sortGen

Documentation

Index

Constants

View Source
const (
	// OrderedName is the name of the named type above, exposed here so that
	// generators can safely refer to it without it breaking
	OrderedName = "Ordered"

	// PkgName is the package to which this definition belongs, again exposed
	// here for the benefit of generators
	PkgName = "myitcv.io/sorter"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Ordered

type Ordered bool

Ordered is a named type used to help identify order functions. See sortGen for more details

type Wrapper

type Wrapper struct {
	LenFunc  func() int
	LessFunc func(i, j int) bool
	SwapFunc func(i, j int)
}

Wrapper is a light wrapper to faciliate calls to sort.Sort

func (*Wrapper) Len

func (w *Wrapper) Len() int

func (*Wrapper) Less

func (w *Wrapper) Less(i, j int) bool

func (*Wrapper) Swap

func (w *Wrapper) Swap(i, j int)

Source Files

Directories

Path Synopsis
cmd

Jump to

Keyboard shortcuts

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