Class: Raz::FileEntry
- Inherits:
-
Object
- Object
- Raz::FileEntry
- Defined in:
- lib/raz/entries.rb
Instance Attribute Summary collapse
-
#absolute_path ⇒ Object
readonly
Returns the value of attribute absolute_path.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#initialize(name, absolute_path) ⇒ FileEntry
constructor
A new instance of FileEntry.
Constructor Details
#initialize(name, absolute_path) ⇒ FileEntry
Returns a new instance of FileEntry.
126 127 128 129 |
# File 'lib/raz/entries.rb', line 126 def initialize(name, absolute_path) @name = name @absolute_path = absolute_path end |
Instance Attribute Details
#absolute_path ⇒ Object (readonly)
Returns the value of attribute absolute_path.
124 125 126 |
# File 'lib/raz/entries.rb', line 124 def absolute_path @absolute_path end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
122 123 124 |
# File 'lib/raz/entries.rb', line 122 def name @name end |
Instance Method Details
#==(other) ⇒ Object
131 132 133 134 135 136 137 |
# File 'lib/raz/entries.rb', line 131 def ==(other) absolute_path == if other.is_a?(FileEntry) other.absolute_path else other.to_s end end |