Method: YARD::CodeObjects::ExtraFileObject#initialize
- Defined in:
- lib/yard/code_objects/extra_file_object.rb
#initialize(filename, contents = nil) ⇒ ExtraFileObject
Creates a new extra file object.
18 19 20 21 22 23 24 25 26 |
# File 'lib/yard/code_objects/extra_file_object.rb', line 18 def initialize(filename, contents = nil) self.filename = filename self.name = File.basename(filename).gsub(/\.[^.]+$/, '') self.attributes = SymbolHash.new(false) @original_contents = contents @parsed = false @locale = nil ensure_parsed end |