Class: EmailData::Source::FileSystem

Inherits:
Object
  • Object
show all
Defined in:
lib/email_data/source/file_system.rb

Class Method Summary collapse

Class Method Details

.country_tldsObject



14
15
16
# File 'lib/email_data/source/file_system.rb', line 14

def self.country_tlds
  @country_tlds ||= load_file("country_tlds.txt")
end

.disposable_domainsObject



22
23
24
# File 'lib/email_data/source/file_system.rb', line 22

def self.disposable_domains
  @disposable_domains ||= load_file("disposable_domains.txt")
end

.disposable_domains_with_mxObject



26
27
28
29
# File 'lib/email_data/source/file_system.rb', line 26

def self.disposable_domains_with_mx
  @disposable_domains_with_mx ||=
    load_file("disposable_domains_with_mx.txt")
end

.disposable_domains_without_mxObject



31
32
33
34
# File 'lib/email_data/source/file_system.rb', line 31

def self.disposable_domains_without_mx
  @disposable_domains_without_mx ||=
    load_file("disposable_domains_without_mx.txt")
end

.disposable_emailsObject



18
19
20
# File 'lib/email_data/source/file_system.rb', line 18

def self.disposable_emails
  @disposable_emails ||= load_file("disposable_emails.txt")
end

.dnsblsObject



48
49
50
# File 'lib/email_data/source/file_system.rb', line 48

def self.dnsbls
  @dnsbls ||= load_file("dnsbls.txt")
end

.free_email_domainsObject



36
37
38
# File 'lib/email_data/source/file_system.rb', line 36

def self.free_email_domains
  @free_email_domains ||= load_file("free_email_domains.txt")
end

.load_file(filename) ⇒ Object



52
53
54
55
56
57
58
59
60
# File 'lib/email_data/source/file_system.rb', line 52

def self.load_file(filename)
  EmailData
    .data_dir
    .join(filename)
    .read
    .lines
    .map(&:chomp)
    .reject(&:empty?)
end

.private_relaysObject



44
45
46
# File 'lib/email_data/source/file_system.rb', line 44

def self.private_relays
  @private_relays ||= load_file("private_relays.txt")
end

.rolesObject



40
41
42
# File 'lib/email_data/source/file_system.rb', line 40

def self.roles
  @roles ||= load_file("roles.txt")
end

.sldsObject



10
11
12
# File 'lib/email_data/source/file_system.rb', line 10

def self.slds
  @slds ||= load_file("slds.txt")
end

.tldsObject



6
7
8
# File 'lib/email_data/source/file_system.rb', line 6

def self.tlds
  @tlds ||= load_file("tlds.txt")
end