Class: CodeMiner::SourceExtract::Partial

Inherits:
Object
  • Object
show all
Defined in:
lib/codeminer/source_extract.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(src, end_line, end_column) ⇒ Partial

Returns a new instance of Partial.



12
13
14
15
16
17
18
# File 'lib/codeminer/source_extract.rb', line 12

def initialize(src, end_line, end_column)
  @src = src
  @end_line = end_line
  @end_column = end_column
  @line = end_line
  @column = end_column
end

Instance Attribute Details

#columnObject (readonly)

Returns the value of attribute column.



10
11
12
# File 'lib/codeminer/source_extract.rb', line 10

def column
  @column
end

#end_columnObject (readonly)

Returns the value of attribute end_column.



10
11
12
# File 'lib/codeminer/source_extract.rb', line 10

def end_column
  @end_column
end

#end_lineObject (readonly)

Returns the value of attribute end_line.



10
11
12
# File 'lib/codeminer/source_extract.rb', line 10

def end_line
  @end_line
end

#lineObject (readonly)

Returns the value of attribute line.



10
11
12
# File 'lib/codeminer/source_extract.rb', line 10

def line
  @line
end

Instance Method Details

#adjust(other) ⇒ Object



20
21
22
# File 'lib/codeminer/source_extract.rb', line 20

def adjust(other)
  SourceExtract.new(@src, other.line, other.column, end_line, end_column)
end

#extractObject



24
25
26
# File 'lib/codeminer/source_extract.rb', line 24

def extract
  ''
end