Class: Suspect::Storage::DirPath
- Inherits:
-
Object
- Object
- Suspect::Storage::DirPath
- Defined in:
- lib/suspect/storage/dir_path.rb
Instance Method Summary collapse
- #expand_path ⇒ Object
-
#initialize(base_path, clock) ⇒ DirPath
constructor
A new instance of DirPath.
- #to_s ⇒ Object
Constructor Details
#initialize(base_path, clock) ⇒ DirPath
4 5 6 7 |
# File 'lib/suspect/storage/dir_path.rb', line 4 def initialize(base_path, clock) @base_path = base_path @clock = clock end |
Instance Method Details
#expand_path ⇒ Object
9 10 11 12 13 14 |
# File 'lib/suspect/storage/dir_path.rb', line 9 def File.join(base_path, format(clock.year), format(clock.month), format(clock.day)) end |
#to_s ⇒ Object
16 17 18 |
# File 'lib/suspect/storage/dir_path.rb', line 16 def to_s end |