APIdock / Ruby
/
Browse About
method

included_modules

v1_9_2_180 - Show latest stable - Class: Module
included_modules()
public

Returns the list of modules included in mod.

module Mixin
end

module Outer
  include Mixin
end

Mixin.included_modules   #=> []
Outer.included_modules   #=> [Mixin]
VALUE
rb_mod_included_modules(VALUE mod)
{
    VALUE ary = rb_ary_new();
    VALUE p;

    for (p = RCLASS_SUPER(mod); p; p = RCLASS_SUPER(p)) {
	if (BUILTIN_TYPE(p) == T_ICLASS) {
	    rb_ary_push(ary, RBASIC(p)->klass);
	}
    }
    return ary;
}

Related methods

  • Instance methods
  • <
  • <=
  • <=>
  • ==
  • ===
  • >
  • >=
  • ancestors
  • autoload
  • autoload?
  • class_eval
  • class_exec
  • class_variable_defined?
  • class_variable_get
  • class_variable_set
  • class_variables
  • const_defined?
  • const_get
  • const_missing
  • const_set
  • constants
  • freeze
  • include?
  • included_modules
  • initialize_copy
  • instance_method
  • instance_methods
  • method_defined?
  • module_eval
  • module_exec
  • name
  • private_class_method
  • private_instance_methods
  • private_method_defined?
  • protected_instance_methods
  • protected_method_defined?
  • public_class_method
  • public_instance_method
  • public_instance_methods
  • public_method_defined?
  • remove_class_variable
  • to_s
  • Class methods
  • constants
  • nesting
  • new
  • Private methods
  • privatealias_method
  • privateappend_features
  • privateattr
  • privateattr_accessor
  • privateattr_reader
  • privateattr_writer
  • privatedefine_method
  • privateextend_object
  • privateextended
  • privateinclude
  • privateincluded
  • privatemethod_added
  • privatemethod_removed
  • privatemethod_undefined
  • privatemodule_function
  • privateprivate
  • privateprotected
  • privatepublic
  • privateremove_const
  • privateremove_method
  • privateundef_method
APIdock API Documentation Browser

© 2026 APIdock