Class: Fuzz::DirObject
- Inherits:
-
Object
- Object
- Fuzz::DirObject
- Defined in:
- lib/fuzz/fzzr.rb
Overview
Fzzr
Instance Attribute Summary collapse
-
#ext ⇒ Object
readonly
Returns the value of attribute ext.
-
#fullpath ⇒ Object
readonly
Returns the value of attribute fullpath.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#path ⇒ Object
readonly
Returns the value of attribute path.
Instance Method Summary collapse
- #changed? ⇒ Boolean
-
#initialize(path) ⇒ DirObject
constructor
A new instance of DirObject.
- #iterate(fzzr_id, &block) ⇒ Object
- #to_s ⇒ Object
Constructor Details
#initialize(path) ⇒ DirObject
Returns a new instance of DirObject.
86 87 88 89 90 91 |
# File 'lib/fuzz/fzzr.rb', line 86 def initialize(path) @path = path @fullpath = File.(path) @name = File.basename(path) @ext = File.extname(path).sub(/^\./,'') end |
Instance Attribute Details
#ext ⇒ Object (readonly)
Returns the value of attribute ext.
85 86 87 |
# File 'lib/fuzz/fzzr.rb', line 85 def ext @ext end |
#fullpath ⇒ Object (readonly)
Returns the value of attribute fullpath.
85 86 87 |
# File 'lib/fuzz/fzzr.rb', line 85 def fullpath @fullpath end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
85 86 87 |
# File 'lib/fuzz/fzzr.rb', line 85 def name @name end |
#path ⇒ Object (readonly)
Returns the value of attribute path.
85 86 87 |
# File 'lib/fuzz/fzzr.rb', line 85 def path @path end |
Instance Method Details
#changed? ⇒ Boolean
93 94 95 |
# File 'lib/fuzz/fzzr.rb', line 93 def changed? false end |
#iterate(fzzr_id, &block) ⇒ Object
97 98 99 100 |
# File 'lib/fuzz/fzzr.rb', line 97 def iterate(fzzr_id, &block) # nothing to iterate over true end |
#to_s ⇒ Object
102 103 104 |
# File 'lib/fuzz/fzzr.rb', line 102 def to_s "Dir:#{path}" end |