withClassesAndObjects

fun <T : KoClassAndObjectProvider> List<T>.withClassesAndObjects(includeNested: Boolean = true, includeLocal: Boolean = true): List<T>

List containing declarations with any class or object.

Return

A list containing declarations with any class or object.

Parameters

includeNested

Whether to include nested classes and objects.

includeLocal

Whether to include local classes.


fun <T : KoClassAndObjectProvider> List<T>.withClassesAndObjects(includeNested: Boolean = true, includeLocal: Boolean = true, predicate: (List<KoClassAndObjectDeclaration>) -> Boolean): List<T>

List containing declarations with classes and objects declarations satisfying the predicate.

Return

A list containing declarations with classes and objects declarations satisfying the predicate.

Parameters

includeNested

Whether to include nested classes and objects.

includeLocal

Whether to include local classes.

predicate

A function that defines the condition to be met by the list of classes and objects declarations.