hasType

abstract fun hasType(predicate: (KoTypeDeclaration) -> Boolean? = null): Boolean

Whether declaration has a specified type.

Return

true if the declaration has the specified type (or any type if predicate is null), false otherwise.

Parameters

predicate

The predicate function used to determine if a declaration type satisfies a condition.