| Class | YARD::CodeObjects::Base |
| In: |
lib/yard/code_objects/base.rb
|
| Parent: | Object |
| namespace | -> | parent |
| docstring | [RW] | |
| dynamic | [RW] | |
| files | [R] | |
| name | [R] | |
| namespace | [RW] | |
| signature | [RW] | |
| source | [RW] |
Associates a file with a code object, optionally adding the line where it was defined. By convention, ’<STDIN>’ should be used to associate code that comes form standard input.
@param [String] file the filename (’<STDIN>’ for standard input) @param [Fixnum, nil] the line number where the object lies in the file @param [Boolean] whether or not the definition has comments associated. This
will allow {#file} to return the definition where the comments were made instead
of any empty definitions that might have been parsed before (module namespaces for instance).
Returns the filename the object was first parsed at, taking definitions with docstrings first.
@return [String] a filename