Class: ReVIEW::Book::ImageIndex::Item
- Defined in:
- lib/review/book/index.rb
Direct Known Subclasses
ReVIEW::Book::IndepImageIndex::Item, NumberlessImageIndex::Item
Instance Attribute Summary collapse
-
#caption ⇒ Object
readonly
Returns the value of attribute caption.
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#index ⇒ Object
writeonly
internal use only.
-
#number ⇒ Object
readonly
Returns the value of attribute number.
Instance Method Summary collapse
- #bound? ⇒ Boolean
-
#initialize(id, number, caption = nil) ⇒ Item
constructor
A new instance of Item.
- #path ⇒ Object
Constructor Details
#initialize(id, number, caption = nil) ⇒ Item
Returns a new instance of Item.
182 183 184 185 186 187 |
# File 'lib/review/book/index.rb', line 182 def initialize(id, number, caption = nil) @id = id @number = number @caption = caption @path = nil end |
Instance Attribute Details
#caption ⇒ Object (readonly)
Returns the value of attribute caption.
191 192 193 |
# File 'lib/review/book/index.rb', line 191 def caption @caption end |
#id ⇒ Object (readonly)
Returns the value of attribute id.
189 190 191 |
# File 'lib/review/book/index.rb', line 189 def id @id end |
#index=(value) ⇒ Object (writeonly)
internal use only
192 193 194 |
# File 'lib/review/book/index.rb', line 192 def index=(value) @index = value end |
#number ⇒ Object (readonly)
Returns the value of attribute number.
190 191 192 |
# File 'lib/review/book/index.rb', line 190 def number @number end |
Instance Method Details
#bound? ⇒ Boolean
194 195 196 |
# File 'lib/review/book/index.rb', line 194 def bound? path end |
#path ⇒ Object
198 199 200 |
# File 'lib/review/book/index.rb', line 198 def path @path ||= @index.find_path(id) end |