wavelength 1.0.0
Loading...
Searching...
No Matches
filelisttask.h
Go to the documentation of this file.
1#pragma once
2
3#include <list>
4
5#include <librtmedius.h>
6
7#include "netflow/nettask.h"
8#include "os/string.h"
9
18class FileListTask : public NetTask {
19public:
26 ~FileListTask() override = default;
27
36 FileListTask(String *pPrefix, std::list<String> *pFiles) : mPrefix(pPrefix), mFiles(pFiles) {
37 }
38
52 static void
53 OnResponse(int nConnection, int nType, int nSize, const rtMediusFileResponse *pResponse);
54
55#ifdef VIDEO_STANDARD_PAL
56#endif
57
58protected:
65 void OnStart() override;
66
67#ifdef VIDEO_STANDARD_PAL
73 void OnPoll() override;
74
75private:
84 void RequestPage();
85#endif
86
88 std::list<String> *mFiles;
89 int mPage;
92};
int mReceived
Definition filelisttask.h:90
int mPage
Definition filelisttask.h:89
void OnStart() override
Clear the names and send the request.
FileListTask(String *pPrefix, std::list< String > *pFiles)
Construct a step.
Definition filelisttask.h:36
String * mPrefix
Definition filelisttask.h:87
~FileListTask() override=default
Destroy the object.
std::list< String > * mFiles
Definition filelisttask.h:88
int mPageDone
Definition filelisttask.h:91
static void OnResponse(int nConnection, int nType, int nSize, const rtMediusFileResponse *pResponse)
Add a file whose name begins with the prefix, and finish the step the response is tagged with after t...
NetTask()
Construct a task outside any NetMultiTask.
Definition nettask.h:24
Growable text buffer that is also a PrnStream.
Definition string.h:19
virtual void OnPoll()
Advance the work, and set mState to kStateDone when it finishes.
Definition task.h:105