Class: Optimus::Reader::LogfileParser::Column
- Inherits:
-
Object
- Object
- Optimus::Reader::LogfileParser::Column
- Defined in:
- lib/log_file_parser.rb
Instance Attribute Summary collapse
-
#level ⇒ Object
Returns the value of attribute level.
-
#name ⇒ Object
Returns the value of attribute name.
Instance Method Summary collapse
- #==(c) ⇒ Object
- #hash ⇒ Object
-
#initialize(name, level) ⇒ Column
constructor
A new instance of Column.
- #to_s ⇒ Object
Constructor Details
#initialize(name, level) ⇒ Column
Returns a new instance of Column.
278 279 280 281 |
# File 'lib/log_file_parser.rb', line 278 def initialize(name, level) @name = name @level = level end |
Instance Attribute Details
#level ⇒ Object
Returns the value of attribute level.
277 278 279 |
# File 'lib/log_file_parser.rb', line 277 def level @level end |
#name ⇒ Object
Returns the value of attribute name.
277 278 279 |
# File 'lib/log_file_parser.rb', line 277 def name @name end |
Instance Method Details
#==(c) ⇒ Object
283 284 285 |
# File 'lib/log_file_parser.rb', line 283 def ==(c) @name == c.name and @level == c.level end |
#hash ⇒ Object
287 288 289 |
# File 'lib/log_file_parser.rb', line 287 def hash return self.to_s.hash end |
#to_s ⇒ Object
291 292 293 |
# File 'lib/log_file_parser.rb', line 291 def to_s "#{@name}[#{@level}]" end |