CodeQL library for Ruby
codeql/ruby-all 0.8.15-dev (changelog, source)
Search

Class Module

A representation of a run-time module or class value.

Import path

import codeql.ruby.AST

Direct supertypes

Known direct subtypes

Predicates

getADeclaration

Gets a declaration of this module, if any.

getADescendent

Gets a module that transitively subclasses, includes, or prepends this module.

getAPrependedModule

Gets a prepended module.

getASingletonClass

Gets a singleton class that augments this module object.

getASubClass

Gets an immediate sub class of this module, if any.

getAnAncestor

Gets a module that is transitively subclassed, included, or prepended by this module.

getAnImmediateAncestor

Gets the super class or an included or prepended module.

getAnImmediateDescendent

Gets a direct subclass or module including or prepending this one.

getAnImmediateReference

Gets a constant or self access that refers to this module.

getAnIncludedModule

Gets an included module.

getAnInstanceMethod

Gets an instance method available in this module, including methods inherited from ancestors.

getAnOwnInstanceMethod

Gets an instance method declared in this module.

getAnOwnSingletonMethod

Gets a singleton method on this module, either declared as a singleton method or an instance method on a singleton class.

getInstanceMethod

Gets the instance method named name available in this module, including methods inherited from ancestors.

getLocation

Gets the location of this module.

getNestedModule

Gets a module named name declared inside this one (not aliased), provided that such a module is defined or reopened in the current codebase.

getOwnInstanceMethod

Gets an instance method named name declared in this module.

getParentModule

Gets the enclosing module, as it appears in the qualified name of this module.

getQualifiedName

Gets the qualified name of this module, if any.

getSuperClass

Gets the super class of this module, if any.

isBuiltin

Holds if this is a built-in module, e.g. Object.

isClass

Holds if this module is a class.

toString

Gets a textual representation of this module.