Class: Desktop::Image
- Inherits:
-
Object
- Object
- Desktop::Image
- Defined in:
- lib/desktop/image.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#path ⇒ Object
readonly
Returns the value of attribute path.
Instance Method Summary collapse
- #data ⇒ Object
- #filename ⇒ Object
-
#initialize(path) ⇒ Image
constructor
A new instance of Image.
Constructor Details
#initialize(path) ⇒ Image
Returns a new instance of Image.
5 6 7 |
# File 'lib/desktop/image.rb', line 5 def initialize(path) @path = path end |
Instance Attribute Details
#path ⇒ Object (readonly)
Returns the value of attribute path.
3 4 5 |
# File 'lib/desktop/image.rb', line 3 def path @path end |
Instance Method Details
#data ⇒ Object
13 14 15 |
# File 'lib/desktop/image.rb', line 13 def data raise NotImplementedError end |
#filename ⇒ Object
9 10 11 |
# File 'lib/desktop/image.rb', line 9 def filename File.basename path end |