Class: CopyTunerIncompatibleSearch::SearchCommand::Usage
- Inherits:
-
Object
- Object
- CopyTunerIncompatibleSearch::SearchCommand::Usage
- Defined in:
- lib/copy_tuner_incompatible_search/search_command.rb
Instance Attribute Summary collapse
-
#code ⇒ Object
readonly
Returns the value of attribute code.
-
#file ⇒ Object
readonly
Returns the value of attribute file.
-
#lazy_key ⇒ Object
readonly
Returns the value of attribute lazy_key.
-
#line ⇒ Object
readonly
Returns the value of attribute line.
Instance Method Summary collapse
-
#initialize(grep_result, lazy_key = nil) ⇒ Usage
constructor
A new instance of Usage.
- #initializers? ⇒ Boolean
Constructor Details
#initialize(grep_result, lazy_key = nil) ⇒ Usage
Returns a new instance of Usage.
81 82 83 84 85 86 87 |
# File 'lib/copy_tuner_incompatible_search/search_command.rb', line 81 def initialize(grep_result, lazy_key = nil) file, line, code = grep_result.split(':', 3) @file = file @line = line @code = code.to_s.strip @lazy_key = lazy_key end |
Instance Attribute Details
#code ⇒ Object (readonly)
Returns the value of attribute code.
79 80 81 |
# File 'lib/copy_tuner_incompatible_search/search_command.rb', line 79 def code @code end |
#file ⇒ Object (readonly)
Returns the value of attribute file.
79 80 81 |
# File 'lib/copy_tuner_incompatible_search/search_command.rb', line 79 def file @file end |
#lazy_key ⇒ Object (readonly)
Returns the value of attribute lazy_key.
79 80 81 |
# File 'lib/copy_tuner_incompatible_search/search_command.rb', line 79 def lazy_key @lazy_key end |
#line ⇒ Object (readonly)
Returns the value of attribute line.
79 80 81 |
# File 'lib/copy_tuner_incompatible_search/search_command.rb', line 79 def line @line end |
Instance Method Details
#initializers? ⇒ Boolean
89 90 91 |
# File 'lib/copy_tuner_incompatible_search/search_command.rb', line 89 def initializers? file == 'config/initializers/copy_tuner.rb' end |