UnmarshalText implements the text unmarshaller method
(text []byte)
| 63 | |
| 64 | // UnmarshalText implements the text unmarshaller method |
| 65 | func (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. |
| 76 | func (x *PreviewSize) Scan(value interface{}) error { |
nothing calls this directly
no test coverage detected