enclosingClasses

fun Class<*>.enclosingClasses(includeSelf: Boolean = false): Sequence<Class<*>>(source)

Provides a sequence of all the enclosing classes of this Class.

Return

A Sequence of all enclosing classes.

Parameters

includeSelf

Determines whether to include the current class in the returned sequence.