Class: GalleryGenerator::MutableViewableGallery
- Inherits:
-
Object
- Object
- GalleryGenerator::MutableViewableGallery
- Defined in:
- lib/m1key_gallery_generator/viewable_gallery.rb
Instance Attribute Summary collapse
-
#blurb ⇒ Object
Returns the value of attribute blurb.
-
#description ⇒ Object
Returns the value of attribute description.
-
#map_title ⇒ Object
Returns the value of attribute map_title.
-
#map_url ⇒ Object
Returns the value of attribute map_url.
-
#photos ⇒ Object
Returns the value of attribute photos.
-
#slug ⇒ Object
Returns the value of attribute slug.
-
#small_print ⇒ Object
Returns the value of attribute small_print.
-
#sources ⇒ Object
Returns the value of attribute sources.
-
#title ⇒ Object
Returns the value of attribute title.
-
#upload_date ⇒ Object
Returns the value of attribute upload_date.
-
#year ⇒ Object
Returns the value of attribute year.
Instance Method Summary collapse
-
#initialize(viewable_gallery) ⇒ MutableViewableGallery
constructor
A new instance of MutableViewableGallery.
- #to_mutable_viewable_photos(viewable_photos) ⇒ Object
Constructor Details
#initialize(viewable_gallery) ⇒ MutableViewableGallery
Returns a new instance of MutableViewableGallery.
46 47 48 49 50 51 52 53 54 55 56 57 58 |
# File 'lib/m1key_gallery_generator/viewable_gallery.rb', line 46 def initialize(viewable_gallery) @title = viewable_gallery.title @description = viewable_gallery.description @slug = viewable_gallery.slug @sources = viewable_gallery.sources @upload_date = viewable_gallery.upload_date @map_url = viewable_gallery.map_url @map_title = viewable_gallery.map_title @year = viewable_gallery.year @photos = to_mutable_viewable_photos(viewable_gallery.photos) @small_print = viewable_gallery.small_print @blurb = viewable_gallery.blurb end |
Instance Attribute Details
#blurb ⇒ Object
Returns the value of attribute blurb.
45 46 47 |
# File 'lib/m1key_gallery_generator/viewable_gallery.rb', line 45 def blurb @blurb end |
#description ⇒ Object
Returns the value of attribute description.
45 46 47 |
# File 'lib/m1key_gallery_generator/viewable_gallery.rb', line 45 def description @description end |
#map_title ⇒ Object
Returns the value of attribute map_title.
45 46 47 |
# File 'lib/m1key_gallery_generator/viewable_gallery.rb', line 45 def map_title @map_title end |
#map_url ⇒ Object
Returns the value of attribute map_url.
45 46 47 |
# File 'lib/m1key_gallery_generator/viewable_gallery.rb', line 45 def map_url @map_url end |
#photos ⇒ Object
Returns the value of attribute photos.
45 46 47 |
# File 'lib/m1key_gallery_generator/viewable_gallery.rb', line 45 def photos @photos end |
#slug ⇒ Object
Returns the value of attribute slug.
45 46 47 |
# File 'lib/m1key_gallery_generator/viewable_gallery.rb', line 45 def slug @slug end |
#small_print ⇒ Object
Returns the value of attribute small_print.
45 46 47 |
# File 'lib/m1key_gallery_generator/viewable_gallery.rb', line 45 def small_print @small_print end |
#sources ⇒ Object
Returns the value of attribute sources.
45 46 47 |
# File 'lib/m1key_gallery_generator/viewable_gallery.rb', line 45 def sources @sources end |
#title ⇒ Object
Returns the value of attribute title.
45 46 47 |
# File 'lib/m1key_gallery_generator/viewable_gallery.rb', line 45 def title @title end |
#upload_date ⇒ Object
Returns the value of attribute upload_date.
45 46 47 |
# File 'lib/m1key_gallery_generator/viewable_gallery.rb', line 45 def upload_date @upload_date end |
#year ⇒ Object
Returns the value of attribute year.
45 46 47 |
# File 'lib/m1key_gallery_generator/viewable_gallery.rb', line 45 def year @year end |
Instance Method Details
#to_mutable_viewable_photos(viewable_photos) ⇒ Object
60 61 62 63 64 |
# File 'lib/m1key_gallery_generator/viewable_gallery.rb', line 60 def to_mutable_viewable_photos(viewable_photos) viewable_photos.map do |viewable_photo| MutableViewablePhoto.new(viewable_photo) end end |