Class: NetworkProfile::NetworkProfileWithoutExtraction

Inherits:
DefaultProfile
  • Object
show all
Defined in:
lib/network_profile/extractors/network_profile_without_extraction.rb

Instance Method Summary collapse

Methods inherited from DefaultProfile

all_types, auto_extractor_link_types, #extra_data, #image, #initialize, parse, #text

Constructor Details

This class inherits a constructor from NetworkProfile::DefaultProfile

Instance Method Details

#dataObject



14
15
16
17
18
19
20
21
22
23
# File 'lib/network_profile/extractors/network_profile_without_extraction.rb', line 14

def data
  {
    title: title,
    text: "",
    image: nil,
    type: self.class.name.underscore.split('/').last,
    link: @link,
    site_icon: self.class.mdi_icon,
  }
end

#profile_descriptionObject



6
7
8
# File 'lib/network_profile/extractors/network_profile_without_extraction.rb', line 6

def profile_description
  "Profil: "
end

#titleObject



10
11
12
# File 'lib/network_profile/extractors/network_profile_without_extraction.rb', line 10

def title
  "#{profile_description} #{@link.split('/').last}"
end