Documentation
¶
Overview ¶
Package scan defines scanning responsibilities for struct/DQL inputs.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Field ¶
type Field struct {
Path string
Name string
Index []int
Type reflect.Type
Tag reflect.StructTag
Anonymous bool
HasViewTag bool
HasStateTag bool
ViewTag *tags.Tag
StateTag *tags.Tag
}
Field describes one scanned struct field.
type Result ¶
type Result struct {
RootType reflect.Type
EmbedFS *embed.FS
Fields []*Field
ByPath map[string]*Field
ViewFields []*Field
StateFields []*Field
}
Result holds scan output produced from a struct source.
type StructScanner ¶
type StructScanner struct{}
StructScanner scans arbitrary struct types and extracts Datly-relevant tags.
func (*StructScanner) Scan ¶
func (s *StructScanner) Scan(_ context.Context, source *shape.Source, _ ...shape.ScanOption) (*shape.ScanResult, error)
Scan implements shape.Scanner.
Click to show internal directories.
Click to hide internal directories.