# Class: Module

Inherits:
  Object
  - Object
  - Module
  show all

Defined in:
  lib/yard/core_ext/module.rb

## Instance Method Summary collapse

- #class_name ⇒ String

  Returns the class name of a full module namespace path.

## Instance Method Details

### #class_name ⇒ `String`

Returns the class name of a full module namespace path

#### Examples:

    module A::B::C; class_name end # => "C"

Returns:

- (`String`) —

  the last part of a module path

    8
    9
    10

    # File 'lib/yard/core_ext/module.rb', line 8

    def class_name
      name.split("::").last
    end