Class: Origen::Utility::FileDiff::OutputFile::Line

Inherits:
String show all
Defined in:
lib/origen/utility/file_diff.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from String

#camel_case, #escape_underscores, #excel_col_index, #is_downcase?, #is_numeric?, #is_upcase?, #is_verilog_number?, #pad_leading_zeros, #squeeze_lines, #symbolize, #titleize, #to_bool, #to_dec, #to_lines, #to_numeric, #to_snakecase, #to_snakecase!

Constructor Details

#initialize(type, input_file) ⇒ Line

Returns a new instance of Line



28
29
30
31
32
33
34
# File 'lib/origen/utility/file_diff.rb', line 28

def initialize(type, input_file)
  self.type = type
  return unless input_file
  replace(input_file.current_line)
  self.original_number = input_file.pointer + 1
  input_file.advance_pointer!
end

Instance Attribute Details

#original_numberObject

Returns the value of attribute original_number



27
28
29
# File 'lib/origen/utility/file_diff.rb', line 27

def original_number
  @original_number
end

#typeObject

Returns the value of attribute type



27
28
29
# File 'lib/origen/utility/file_diff.rb', line 27

def type
  @type
end