Class: UncleKryon::AumData
- Defined in:
- lib/unclekryon/data/aum_data.rb
Instance Attribute Summary collapse
-
#filename ⇒ Object
Returns the value of attribute filename.
-
#filesize ⇒ Object
Returns the value of attribute filesize.
-
#languages ⇒ Object
Returns the value of attribute languages.
-
#mirrors ⇒ Object
Returns the value of attribute mirrors.
-
#subtitle ⇒ Object
Returns the value of attribute subtitle.
-
#timespan ⇒ Object
Returns the value of attribute timespan.
-
#title ⇒ Object
Returns the value of attribute title.
-
#url ⇒ Object
Returns the value of attribute url.
Attributes inherited from BaseData
Instance Method Summary collapse
-
#==(other) ⇒ Object
Excludes @updated_on.
-
#initialize ⇒ AumData
constructor
A new instance of AumData.
- #to_s ⇒ Object
Methods inherited from BaseData
#initialize_copy, #max_updated_on, max_updated_on, #max_updated_on_s, max_updated_on_s, #update
Constructor Details
#initialize ⇒ AumData
Returns a new instance of AumData.
26 27 28 29 30 31 32 33 34 35 36 37 38 |
# File 'lib/unclekryon/data/aum_data.rb', line 26 def initialize super() @title = '' @subtitle = '' @languages = [] @timespan = '' @filesize = '' @filename = '' @url = '' @mirrors = {} end |
Instance Attribute Details
#filename ⇒ Object
Returns the value of attribute filename.
21 22 23 |
# File 'lib/unclekryon/data/aum_data.rb', line 21 def filename @filename end |
#filesize ⇒ Object
Returns the value of attribute filesize.
20 21 22 |
# File 'lib/unclekryon/data/aum_data.rb', line 20 def filesize @filesize end |
#languages ⇒ Object
Returns the value of attribute languages.
18 19 20 |
# File 'lib/unclekryon/data/aum_data.rb', line 18 def languages @languages end |
#mirrors ⇒ Object
Returns the value of attribute mirrors.
24 25 26 |
# File 'lib/unclekryon/data/aum_data.rb', line 24 def mirrors @mirrors end |
#subtitle ⇒ Object
Returns the value of attribute subtitle.
17 18 19 |
# File 'lib/unclekryon/data/aum_data.rb', line 17 def subtitle @subtitle end |
#timespan ⇒ Object
Returns the value of attribute timespan.
19 20 21 |
# File 'lib/unclekryon/data/aum_data.rb', line 19 def timespan @timespan end |
#title ⇒ Object
Returns the value of attribute title.
16 17 18 |
# File 'lib/unclekryon/data/aum_data.rb', line 16 def title @title end |
#url ⇒ Object
Returns the value of attribute url.
23 24 25 |
# File 'lib/unclekryon/data/aum_data.rb', line 23 def url @url end |
Instance Method Details
#==(other) ⇒ Object
Excludes @updated_on
41 42 43 44 45 46 47 48 49 50 |
# File 'lib/unclekryon/data/aum_data.rb', line 41 def ==(other) return @title == other.title && @subtitle == other.subtitle && @languages == other.languages && @timespan == other.timespan && @filesize == other.filesize && @filename == other.filename && @url == other.url && @mirrors == other.mirrors end |
#to_s ⇒ Object
52 53 54 55 56 57 58 59 60 61 |
# File 'lib/unclekryon/data/aum_data.rb', line 52 def to_s s = '' s << ('%-40s' % [@title]) s << (' | %30s' % [@subtitle]) s << (' | %10s' % [@languages.join(';')]) s << (' | %10s' % [@timespan]) s << (' | %10s' % [@filesize]) s << (' | %30s' % [@filename]) return s end |