Class: RDocRuboCop::FilePath

Inherits:
String
  • Object
show all
Defined in:
lib/rdoc_rubocop/file_path.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(str, source_code) ⇒ FilePath



6
7
8
9
10
# File 'lib/rdoc_rubocop/file_path.rb', line 6

def initialize(str, source_code)
  super(str)
  @source_code = source_code
  @source = @source_code.text
end

Instance Attribute Details

#sourceObject

Returns the value of attribute source.



4
5
6
# File 'lib/rdoc_rubocop/file_path.rb', line 4

def source
  @source
end

#source_codeObject (readonly)

Returns the value of attribute source_code.



3
4
5
# File 'lib/rdoc_rubocop/file_path.rb', line 3

def source_code
  @source_code
end