Method: Inch::Language::Elixir::CodeObject::Base#depth

Defined in:
lib/inch/language/elixir/code_object/base.rb

#depthFixnum

Note:

top-level counts, that’s why Foo has depth 1!

The depth of the following is 4:

Foo::Bar::Baz#initialize
 ^    ^    ^      ^
 1 << 2 << 3  <<  4

depth answers the question “how many layers of code objects are above this one?”

Returns:

  • (Fixnum)

    the depth of the object in terms of namespace



62
63
64
# File 'lib/inch/language/elixir/code_object/base.rb', line 62

def depth
  self[:depth]
end