class Suspect::Setup::Creator
Attributes
collector_id_generator[R]
file_helper[R]
structure[R]
Public Class Methods
new(structure, collector_id_generator, file_helper)
click to toggle source
# File lib/suspect/setup/creator.rb, line 4 def initialize(structure, collector_id_generator, file_helper) @structure = structure @collector_id_generator = collector_id_generator @file_helper = file_helper end
Public Instance Methods
build()
click to toggle source
# File lib/suspect/setup/creator.rb, line 10 def build create_storage_dir create_collector_id_file end
Private Instance Methods
create_collector_id_file()
click to toggle source
# File lib/suspect/setup/creator.rb, line 19 def create_collector_id_file file_helper.write structure.collector_id_path, collector_id_generator.next end
create_storage_dir()
click to toggle source
# File lib/suspect/setup/creator.rb, line 24 def create_storage_dir file_helper.mkdir structure.storage_path end