Feeds.h 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. #ifndef NULLSOFT_FEEDSH
  2. #define NULLSOFT_FEEDSH
  3. #include "ifc_podcast.h"
  4. #include "Item.h"
  5. #include <vector>
  6. class Channel : public ifc_podcast
  7. {
  8. public:
  9. typedef std::vector<RSS::Item> ItemList;
  10. Channel();
  11. Channel(const Channel &copy);
  12. const Channel &operator =(const Channel &copy);
  13. ~Channel();
  14. void SortByTitle(), SortByMedia(), SortByMediaTime(), SortByDate(), SortByMediaSize();
  15. bool operator == (const Channel &compare);
  16. //void operator = (const Channel &copy);
  17. void UpdateFrom(const Channel &copy);
  18. unsigned int ttl;
  19. __time64_t updateTime, lastUpdate;
  20. int autoDownloadEpisodes;
  21. bool autoUpdate;
  22. bool useDefaultUpdate;
  23. bool autoDownload;
  24. bool needsRefresh;
  25. // TODO: std::wstring downloadLocation;
  26. ItemList items;
  27. void SetURL(const wchar_t *val);
  28. void SetTitle(const wchar_t *val);
  29. void SetLink(const wchar_t *val);
  30. void SetDescription(const wchar_t *val);
  31. wchar_t *url, *title, *link, *description;
  32. public: // ifc_podcast interface
  33. int GetTitle(wchar_t *str, size_t len);
  34. private:
  35. void Init();
  36. void Reset();
  37. protected:
  38. RECVS_DISPATCH;
  39. };
  40. #endif