MythTV master
mythinteractivebuffer.h
Go to the documentation of this file.
1#ifndef ICRINGBUFFER_H
2#define ICRINGBUFFER_H
3
4// MythTV
6
7class NetStream;
8
10{
11 public:
12 explicit MythInteractiveBuffer(const QString &Url, MythMediaBuffer *Parent = nullptr);
13 ~MythInteractiveBuffer() override;
14
15 bool IsOpen (void) const override;
16 long long GetReadPosition (void) const override;
17 bool OpenFile (const QString &Url, std::chrono::milliseconds Retry = kDefaultOpenTimeout) override;
18 bool IsStreamed (void) override { return false; }
19 bool IsSeekingAllowed (void) override { return true; }
20 bool IsBookmarkAllowed (void) override { return false; }
21
23
24 protected:
25 int SafeRead (void *Buffer, uint Size) override;
26 long long GetRealFileSizeInternal(void) const override;
27 long long SeekInternal (long long Position, int Whence) override;
28
29 private:
30 NetStream *m_stream { nullptr };
32};
33#endif
MythMediaBuffer * TakeBuffer(void)
long long SeekInternal(long long Position, int Whence) override
bool OpenFile(const QString &Url, std::chrono::milliseconds Retry=kDefaultOpenTimeout) override
Opens a BBC NetStream for reading.
int SafeRead(void *Buffer, uint Size) override
bool IsBookmarkAllowed(void) override
MythMediaBuffer * m_parent
bool IsStreamed(void) override
bool IsSeekingAllowed(void) override
bool IsOpen(void) const override
long long GetReadPosition(void) const override
long long GetRealFileSizeInternal(void) const override
friend class MythInteractiveBuffer
static constexpr std::chrono::milliseconds kDefaultOpenTimeout
Stream content from a URI.
Definition: netstream.h:32
unsigned int uint
Definition: freesurround.h:24