Commit 968b2fdd authored by Paul Warren's avatar Paul Warren
Browse files

Add UnmarshalXMLAttr

parent 731e1651
......@@ -75,6 +75,15 @@ func UnmarshallQNameAttr(d *xml.Decoder, s xml.StartElement, a QName) (QName, er
return q, nil
}
func (qname *QName) UnmarshalXMLAttr(d *xml.Decoder, attr xml.Attr) error {
q, err := NewFromString(d.NamespaceBindings(), attr.Value)
if err != nil {
return err
}
*qname = q
return nil
}
func (qname QName) String() string {
return "{" + qname.Namespace + "}" + qname.Localname
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment