parser

package
v0.0.0-...-403b093 Latest Latest
Warning

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

Go to latest
Published: Jun 12, 2018 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Register

func Register(service Service, front bool)

func Registerf

func Registerf(match MatchFunc, parse ParseFunc, front bool)

Types

type MatchFunc

type MatchFunc func(path string) (ok bool)

type ParseFunc

type ParseFunc func(path string) (pkg, ver string, err error)

type Service

type Service interface {
	Match(path string) (ok bool)
	Parse(path string) (pkg, ver string, err error)
}

func Make

func Make(match MatchFunc, parse ParseFunc) Service

func Select

func Select(path string) (service Service, ok bool)

Jump to

Keyboard shortcuts

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