From 64bc10f6aaeea4ed79a42ec3a6c2686138f9ae81 Mon Sep 17 00:00:00 2001 From: Serene-Arc Date: Thu, 11 Feb 2021 16:31:38 +1000 Subject: [PATCH] Add ARCHITECTURE file --- ARCHITECTURE.md | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 ARCHITECTURE.md diff --git a/ARCHITECTURE.md b/ARCHITECTURE.md new file mode 100644 index 0000000..8f1bb5e --- /dev/null +++ b/ARCHITECTURE.md @@ -0,0 +1,22 @@ +# Architecture + + 1. Arguments are passed to an instance of RedditDownloader + 2. Internal objects are created + + - Formatter created + - Filter created + - Configuration loaded + - Reddit instance created + + 3. Reddit lists scraped + +To actually download, the following happens: + + 1. RedditDownloader uses DownloadFactory to find the right module for a submission + 2. Downloader instance created + 3. Downloader returns a list of Resource objects (lists may have one objects) + 4. RedditDownloader checks if it already exists + 5. RedditDownloader checks against the DownloadFilter created earlier + 6. RedditDownloader creates a formatted file path base on the Resource with FileNameFormatter + 7. Resource content is written to disk + \ No newline at end of file