7 #ifndef PACKAGER_MEDIA_FORMATS_WEBVTT_WEBVTT_TEXT_HANDLER_H_ 8 #define PACKAGER_MEDIA_FORMATS_WEBVTT_WEBVTT_TEXT_HANDLER_H_ 14 #include "packager/media/base/media_handler.h" 15 #include "packager/media/base/muxer_options.h" 16 #include "packager/media/event/muxer_listener.h" 33 virtual Status OnStreamEnd() = 0;
37 void WriteCue(
const std::string&
id,
40 const std::string& settings,
41 const std::string& payload);
44 Status WriteSegmentToFile(
const std::string& filename);
50 Status InitializeInternal()
override;
51 Status Process(std::unique_ptr<StreamData> stream_data)
override;
52 Status OnFlushRequest(
size_t input_stream_index)
override;
63 std::unique_ptr<MuxerListener> muxer_listener);
69 Status OnStreamEnd()
override;
73 void GoToNextSegment(uint64_t start_time_ms);
76 std::unique_ptr<MuxerListener> muxer_listener_;
79 uint64_t total_duration_ms_ = 0;
80 uint32_t segment_index_ = 0;
86 #endif // PACKAGER_MEDIA_FORMATS_WEBVTT_WEBVTT_TEXT_HANDLER_H_
All the methods that are virtual are virtual for mocking.