- Sort Score
- Result 10 results
- Languages All
Results 1 - 3 of 3 for UnmarshalerAttr (0.12 sec)
-
src/encoding/xml/read.go
// so it's likely to be incorrect, but we do what we're told. return val.Interface().(UnmarshalerAttr).UnmarshalXMLAttr(attr) } if val.CanAddr() { pv := val.Addr() if pv.CanInterface() && pv.Type().Implements(unmarshalerAttrType) { return pv.Interface().(UnmarshalerAttr).UnmarshalXMLAttr(attr) } } // Not an UnmarshalerAttr; try encoding.TextUnmarshaler.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Sep 08 19:04:28 UTC 2023 - 22.4K bytes - Viewed (0) -
src/encoding/xml/read_test.go
panic("must not call") } type MyAttr struct { attr string } func (m *MyAttr) UnmarshalXMLAttr(attr Attr) error { m.attr = attr.Value return nil } var _ UnmarshalerAttr = (*MyAttr)(nil) type MyStruct struct { Data *MyCharData Attr *MyAttr `xml:",attr"` Data2 MyCharData Attr2 MyAttr `xml:",attr"` } func TestUnmarshaler(t *testing.T) {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Mar 26 19:58:28 UTC 2024 - 29.1K bytes - Viewed (0) -
src/cmd/vendor/golang.org/x/tools/internal/stdlib/manifest.go
{"TagPathError.Tag2", Field, 0}, {"Token", Type, 0}, {"TokenReader", Type, 10}, {"Unmarshal", Func, 0}, {"UnmarshalError", Type, 0}, {"Unmarshaler", Type, 2}, {"UnmarshalerAttr", Type, 2}, {"UnsupportedTypeError", Type, 0}, {"UnsupportedTypeError.Type", Field, 0}, }, "errors": { {"As", Func, 13}, {"ErrUnsupported", Var, 21}, {"Is", Func, 13},
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Apr 02 02:20:05 UTC 2024 - 534.2K bytes - Viewed (0)