MCPcopy
hub / github.com/filebrowser/filebrowser / UnmarshalText

Method UnmarshalText

http/preview_enum.go:65–73  ·  view source on GitHub ↗

UnmarshalText implements the text unmarshaller method

(text []byte)

Source from the content-addressed store, hash-verified

63
64// UnmarshalText implements the text unmarshaller method
65func (x *PreviewSize) UnmarshalText(text []byte) error {
66 name := string(text)
67 tmp, err := ParsePreviewSize(name)
68 if err != nil {
69 return err
70 }
71 *x = tmp
72 return nil
73}
74
75// Scan implements the Scanner interface.
76func (x *PreviewSize) Scan(value interface{}) error {

Callers

nothing calls this directly

Calls 1

ParsePreviewSizeFunction · 0.85

Tested by

no test coverage detected