Class: Arxiv::Downloader::Archive

Inherits:
Object
  • Object
show all
Defined in:
lib/arxiv/downloader/archive.rb

Instance Method Summary collapse

Constructor Details

#initialize(identifier, root:, client: Client.new) ⇒ Archive

Returns a new instance of Archive.



6
7
8
9
10
# File 'lib/arxiv/downloader/archive.rb', line 6

def initialize identifier, root:, client: Client.new
  @identifier = identifier
  @root       = root
  @client     = client
end

Instance Method Details

#runObject



12
13
14
15
16
17
18
19
20
21
22
# File 'lib/arxiv/downloader/archive.rb', line 12

def run
  FileUtils.mkdir_p paper_dir

  download_pdf
  download_abstract
  download_html_archive
  download_source_archive
  write_sidecars

  paper_dir
end