diff --git a/types/scte224v20180501/adi30/adi30.go b/types/scte224v20180501/adi30/adi30.go index 68e2f20..be362b1 100644 --- a/types/scte224v20180501/adi30/adi30.go +++ b/types/scte224v20180501/adi30/adi30.go @@ -22,10 +22,37 @@ type ADI30 struct { Xsi string `xml:"http://www.w3.org/2001/XMLSchema-instance xsi,attr" json:"-"` //Xmlns string `xml:"xmlns,attr" json:"-"` */ + ContentNamespace ContentXSIPrefix `xml:"explicitContentNamespace,attr"` + TitleNamespace TitleXSIPrefix `xml:"explicitTitleNamespace,attr"` Asset []*Asset `xml:"Asset,omitempty" json:"asset,omitempty"` //Metadata *Metadata `xml:"Metadata"` } + +type TitleXSIPrefix struct{} + +func (t TitleXSIPrefix) MarshalXMLAttr(name xml.Name) (xml.Attr, error) { + return xml.Attr{ + Name: xml.Name{ + Space: "", + Local: "xmlns:title", + }, + Value: "http://www.scte.org/schemas/236/2017/title", + }, nil +} + +type ContentXSIPrefix struct {} + +func (c ContentXSIPrefix) MarshalXMLAttr(name xml.Name) (xml.Attr, error) { + return xml.Attr{ + Name: xml.Name{ + Space: "", + Local: "xmlns:content", + }, + Value: "http://www.scte.org/schemas/236/2017/content", + }, nil +} + // Metadata elements are containers for a single AMS element and // zero or more App_Data elements. type Metadata struct { diff --git a/types/scte224v20180501/roundtrip_test.go b/types/scte224v20180501/roundtrip_test.go index c9d1cf8..25870ee 100644 --- a/types/scte224v20180501/roundtrip_test.go +++ b/types/scte224v20180501/roundtrip_test.go @@ -180,7 +180,7 @@ const expectedInlinedADIMetadata = ` ow7qaht5qULfWFcl5sbvzJXOVJEHsP6a - + HBO eng