-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
XML parser #4180
XML parser #4180
Conversation
…ree and manage node as arrays
…ssue with ES6 syntax
…nodes as array process) on-the-fly
…at can contain a number value (such as "id" attribute)
…h.js into feature/xml-parser
import ObjectIron from './objectiron'; | ||
import X2JS from '../../../externals/xml2json'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove xml2json from externals
folder
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
const acc = new DescriptorType(); | ||
return acc.init(audioChanCfg); | ||
}); | ||
} | ||
|
||
function getAudioChannelConfigurationForRepresentation(representation) { | ||
if (!representation || !representation.hasOwnProperty(DashConstants.AUDIOCHANNELCONFIGURATION_ASARRAY) || !representation[DashConstants.AUDIOCHANNELCONFIGURATION_ASARRAY].length) return []; | ||
return representation[DashConstants.AUDIOCHANNELCONFIGURATION_ASARRAY].map( audioChanCfg => { | ||
if (!representation || !representation.hasOwnProperty(DashConstants.AUDIO_CHANNEL_CONFIGURATION) || !representation[DashConstants.AUDIO_CHANNEL_CONFIGURATION].length) return []; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Function is defined two times, probably a merge mistake
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes indeed, a merge mistake
constructor() { | ||
super( | ||
(attr, nodeName) => { | ||
const stringAttrsInElements = { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this per default always converted to string which is why we dont need this matcher anymore?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
exactly
|
Fixed, InbandEventStream was not in the list of nodes being represented as an array |
This XML parser does not handle escape sequences correctly. As a result, urls containing the |
Continuation of #3412
The goal of this PR is to provide a new XML parser in order to speed up parsing time.
Parsing time may be criticial for long contents with SegmentTimelines.
What has been achieved in this PR:
Here are some numbers for the XML parsing processing time (in ms) for a 240mn content having one AdaptationSet with a SegmentTimeline without repeat pattern: