Documentation
¶
Overview ¶
This file may have been modified by Bytedance Ltd. and/or its affiliates (“Bytedance's Modifications”). All Bytedance's Modifications are Copyright (2022) Bytedance Ltd. and/or its affiliates.
Index ¶
- type Expression
- type Field
- type Function
- func (f *Function) AnonFuncsCount() int
- func (f *Function) FullName() string
- func (f *Function) IsNaked() bool
- func (f *Function) OnlyReturnsError() bool
- func (f *Function) OnlyReturnsOneValue() bool
- func (f *Function) ReceiverName() string
- func (f *Function) ReturnsMultiple() bool
- func (f *Function) TestName() string
- func (f *Function) TestParameters() []*Field
- func (f *Function) TestResults() []*Field
- type Header
- type Import
- type Path
- type Receiver
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Expression ¶
type Expression struct {
Value string
IsStar bool
IsVariadic bool
IsInterface bool
IsWriter bool
Underlying string
PkgPath string // 如果map结构,那么PkgPath表示的是key的包路径
PkgName string
}
func (*Expression) String ¶
func (e *Expression) String() string
type Field ¶
type Field struct {
Name string
Type *Expression
Index int
}
func (*Field) FieldMaxIndex ¶
func (*Field) IsBasicType ¶
func (*Field) ToStringForStruct ¶
type Function ¶
type Function struct {
Name string
IsExported bool
Receiver *Receiver
Parameters []*Field
Results []*Field
RowData string
ReturnsError bool
ContainAnonFuncs int
}
func (*Function) AnonFuncsCount ¶
func (*Function) OnlyReturnsError ¶
func (*Function) OnlyReturnsOneValue ¶
func (*Function) ReceiverName ¶
func (*Function) ReturnsMultiple ¶
func (*Function) TestParameters ¶
func (*Function) TestResults ¶
type Receiver ¶
func (*Receiver) InitiateReceiver ¶
func (*Receiver) InitiateReceiverForMock ¶
func (*Receiver) InitiateStruct ¶
func (*Receiver) InitiateVariable ¶
InitiateVariable used for gotype dynamic transformation
Click to show internal directories.
Click to hide internal directories.