package model
import "github.com/golang/mock/mockgen/model"
Package model contains the data model necessary for generating mock implementations.
Index ¶
- type ArrayType
- type ChanDir
- type ChanType
- type FuncType
- type Interface
- func InterfaceFromInterfaceType(it reflect.Type) (*Interface, error)
- func (intf *Interface) Print(w io.Writer)
- type MapType
- type Method
- type NamedType
- type Package
- type Parameter
- type PointerType
- type PredeclaredType
- type Type
Types ¶
type ArrayType ¶
ArrayType is an array or slice type.
func (*ArrayType) String ¶
type ChanDir ¶
type ChanDir int
ChanDir is a channel direction.
type ChanType ¶
ChanType is a channel type.
func (*ChanType) String ¶
type FuncType ¶
FuncType is a function type.
func (*FuncType) String ¶
type Interface ¶
Interface is a Go interface.
func InterfaceFromInterfaceType ¶
func (*Interface) Print ¶
type MapType ¶
type MapType struct { Key, Value Type }
MapType is a map type.
func (*MapType) String ¶
type Method ¶
Method is a single method of an interface.
func (*Method) Print ¶
type NamedType ¶
type NamedType struct { Package string // may be empty Type string // TODO: should this be typed Type? }
NamedType is an exported type in a package.
func (*NamedType) String ¶
type Package ¶
Package is a Go package. It may be a subset.
func (*Package) Imports ¶
Imports returns the imports needed by the Package as a set of import paths.
func (*Package) Print ¶
type Parameter ¶
Parameter is an argument or return parameter of a method.
func (*Parameter) Print ¶
type PointerType ¶
type PointerType struct { Type Type }
PointerType is a pointer to another type.
func (*PointerType) String ¶
func (pt *PointerType) String(pm map[string]string, pkgOverride string) string
type PredeclaredType ¶
type PredeclaredType string
PredeclaredType is a predeclared type such as "int".
func (PredeclaredType) String ¶
func (pt PredeclaredType) String(pm map[string]string, pkgOverride string) string
type Type ¶
type Type interface { String(pm map[string]string, pkgOverride string) string // contains filtered or unexported methods }
Type is a Go type.
Source Files ¶
- Version
- v1.0.1
- Published
- Apr 3, 2018
- Platform
- linux/amd64
- Imports
- 5 packages
- Last checked
- 1 minute ago –
Tools for package owners.