5 #ifndef PACKAGER_MEDIA_FORMATS_MP2T_ES_PARSER_H_
6 #define PACKAGER_MEDIA_FORMATS_MP2T_ES_PARSER_H_
23 typedef std::function<void(std::shared_ptr<StreamInfo>)> NewStreamInfoCB;
24 typedef std::function<void(std::shared_ptr<MediaSample>)> EmitSampleCB;
25 typedef std::function<void(std::shared_ptr<TextSample>)> EmitTextSampleCB;
27 EsParser(uint32_t pid) : pid_(pid) {}
32 virtual bool Parse(
const uint8_t* buf,
38 virtual bool Flush() = 0;
41 virtual void Reset() = 0;
43 uint32_t pid() {
return pid_; }
All the methods that are virtual are virtual for mocking.