Class: SyntaxTree::Index::FileComments::StringSource
- Inherits:
-
Object
- Object
- SyntaxTree::Index::FileComments::StringSource
- Defined in:
- lib/syntax_tree/index.rb
Overview
This represents the Ruby source in the form of a string. When it needs to be read the string is returned.
Instance Attribute Summary collapse
-
#source ⇒ Object
readonly
Returns the value of attribute source.
Instance Method Summary collapse
-
#initialize(source) ⇒ StringSource
constructor
A new instance of StringSource.
Constructor Details
#initialize(source) ⇒ StringSource
Returns a new instance of StringSource.
132 133 134 |
# File 'lib/syntax_tree/index.rb', line 132 def initialize(source) @source = source end |
Instance Attribute Details
#source ⇒ Object (readonly)
Returns the value of attribute source.
130 131 132 |
# File 'lib/syntax_tree/index.rb', line 130 def source @source end |