Class: KodiDedup::Config

Inherits:
Object
  • Object
show all
Defined in:
lib/kodi_dedup/config.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(options) ⇒ Config

Returns a new instance of Config.



5
6
7
8
9
10
11
12
13
# File 'lib/kodi_dedup/config.rb', line 5

def initialize(options)
  @perform = options['perform']
  if options['replace']
    @replace = options['replace'].keys.first
    @with    = options['replace'].values.first
  end
  @url     = options['url']
  @mediainfo = options[:mediainfo] || KodiDedup::Mediainfo
end

Instance Attribute Details

#mediainfoObject (readonly)

Returns the value of attribute mediainfo.



3
4
5
# File 'lib/kodi_dedup/config.rb', line 3

def mediainfo
  @mediainfo
end

#performObject (readonly)

Returns the value of attribute perform.



3
4
5
# File 'lib/kodi_dedup/config.rb', line 3

def perform
  @perform
end

#replaceObject (readonly)

Returns the value of attribute replace.



3
4
5
# File 'lib/kodi_dedup/config.rb', line 3

def replace
  @replace
end

#urlObject (readonly)

Returns the value of attribute url.



3
4
5
# File 'lib/kodi_dedup/config.rb', line 3

def url
  @url
end

#withObject (readonly)

Returns the value of attribute with.



3
4
5
# File 'lib/kodi_dedup/config.rb', line 3

def with
  @with
end