Class: Mago::RubyFile

Inherits:
Object
  • Object
show all
Defined in:
lib/mago/ruby_file.rb

Overview

Represents a ruby file with magic numbers.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(path) ⇒ RubyFile

Returns a new instance of RubyFile.

Parameters:

  • path (String)

    file path



11
12
13
14
# File 'lib/mago/ruby_file.rb', line 11

def initialize(path)
  @path = path
  @magic_numbers = []
end

Instance Attribute Details

#magic_numbersObject (readonly)

Returns the value of attribute magic_numbers.



8
9
10
# File 'lib/mago/ruby_file.rb', line 8

def magic_numbers
  @magic_numbers
end

#pathObject (readonly)

Returns the value of attribute path.



5
6
7
# File 'lib/mago/ruby_file.rb', line 5

def path
  @path
end