Module: Reek::AST::SexpExtensions::DefsNode Private

Includes:
MethodNodeBase
Defined in:
lib/reek/ast/sexp_extensions.rb

Overview

This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.

Utility methods for :defs nodes.

Instance Method Summary collapse

Methods included from MethodNodeBase

#arg_names, #arguments, #body_nodes, #ends_with_bang?, #name_without_bang, #parameter_names, #parameters

Instance Method Details

#argslistObject

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



280
# File 'lib/reek/ast/sexp_extensions.rb', line 280

def argslist() self[3] end

#bodyObject

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



282
283
284
# File 'lib/reek/ast/sexp_extensions.rb', line 282

def body
  self[4]
end

#depends_on_instance?Boolean

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns:

  • (Boolean)


292
293
294
# File 'lib/reek/ast/sexp_extensions.rb', line 292

def depends_on_instance?
  false
end

#full_name(outer) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



287
288
289
290
# File 'lib/reek/ast/sexp_extensions.rb', line 287

def full_name(outer)
  prefix = outer == '' ? '' : "#{outer}#"
  "#{prefix}#{SexpFormatter.format(receiver)}.#{name}"
end

#nameObject

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



279
# File 'lib/reek/ast/sexp_extensions.rb', line 279

def name() self[2] end

#receiverObject

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



278
# File 'lib/reek/ast/sexp_extensions.rb', line 278

def receiver() self[1] end